|
@@ -4,8 +4,8 @@
|
|
|
<template #btn>
|
|
|
<div style="width:100%;display:flex">
|
|
|
<div style="width:calc(100% - 105px)">
|
|
|
- <el-form-item label="订单号" prop="code" class="margin-b-0">
|
|
|
- <el-input disabled v-model="formData.data.code" placeholder="请选择"></el-input>
|
|
|
+ <el-form-item label="订单号" prop="purchaseCode" class="margin-b-0">
|
|
|
+ <el-input disabled v-model="formData.data.purchaseCode" placeholder="请选择"></el-input>
|
|
|
</el-form-item>
|
|
|
</div>
|
|
|
<el-button type="primary" style="width:88px;margin-left:15px" @click="openMaterial = true" plain>选择订单</el-button>
|
|
@@ -118,7 +118,7 @@ const formConfig = computed(() => {
|
|
|
{
|
|
|
type: "slot",
|
|
|
slotName: "btn",
|
|
|
- // prop: "code",
|
|
|
+ // prop: "purchaseCode",
|
|
|
label: "",
|
|
|
itemWidth: 50,
|
|
|
disabled: true,
|
|
@@ -176,7 +176,9 @@ const formConfig = computed(() => {
|
|
|
});
|
|
|
|
|
|
const rules = ref({
|
|
|
- code: [{ required: true, message: "请选择采购订单", trigger: "blur" }],
|
|
|
+ purchaseCode: [
|
|
|
+ { required: true, message: "请选择采购订单", trigger: "blur" },
|
|
|
+ ],
|
|
|
// quantity: [{ required: true, message: "请输入退货数量", trigger: "blur" }],
|
|
|
remark: [{ required: true, message: "请输入退货原因", trigger: "blur" }],
|
|
|
companyId: [{ required: true, message: "请选择业务公司", trigger: "change" }],
|
|
@@ -218,7 +220,7 @@ const totalAmount = () => {
|
|
|
const handleSelect = (row) => {
|
|
|
formData.data = {
|
|
|
companyId: proxy.useUserStore().user.companyId,
|
|
|
- code: row.code,
|
|
|
+ purchaseCode: row.purchaseCode,
|
|
|
supplierName: row.supplyName,
|
|
|
purchaseAmount: row.amount,
|
|
|
payAmount: row.sumPayMoney,
|
|
@@ -294,6 +296,7 @@ const handleSubmit = async () => {
|
|
|
const getAllData = (businessId) => {
|
|
|
if (businessId) {
|
|
|
proxy.post("/purchaseBack/detail", { id: businessId }).then((res) => {
|
|
|
+ res.payAmount = res.payAmount || 0;
|
|
|
formData.data = res;
|
|
|
getAllFileData();
|
|
|
totalAmount();
|