|
@@ -58,9 +58,9 @@
|
|
|
>
|
|
|
<template #details>
|
|
|
<div style="width: 100%">
|
|
|
- <!-- <el-button type="primary" plain @click="openProduct = true">
|
|
|
+ <el-button type="primary" plain @click="openProduct = true">
|
|
|
添加商品
|
|
|
- </el-button> -->
|
|
|
+ </el-button>
|
|
|
<el-table
|
|
|
:data="formData.data.afterSalesDetailList"
|
|
|
style="margin-top: 10px"
|
|
@@ -266,9 +266,9 @@ const rules = ref({
|
|
|
customerId: [
|
|
|
{ required: true, message: "请选择客户名称", trigger: "change" },
|
|
|
],
|
|
|
- contractIds: [
|
|
|
- { required: true, message: "请选择销售合同", trigger: "change" },
|
|
|
- ],
|
|
|
+ // contractIds: [
|
|
|
+ // { required: true, message: "请选择销售合同", trigger: "change" },
|
|
|
+ // ],
|
|
|
type: [{ required: true, message: "请选择售后类型", trigger: "change" }],
|
|
|
remark: [{ required: true, message: "请输入售后说明", trigger: "blur" }],
|
|
|
quantity: [{ required: true, message: "请输入售后数量", trigger: "blur" }],
|
|
@@ -523,7 +523,9 @@ const config = computed(() => {
|
|
|
});
|
|
|
|
|
|
const formData = reactive({
|
|
|
- data: {},
|
|
|
+ data: {
|
|
|
+ afterSalesDetailList: [],
|
|
|
+ },
|
|
|
followData: {},
|
|
|
});
|
|
|
const formOption = reactive({
|
|
@@ -589,12 +591,13 @@ const formConfig = computed(() => {
|
|
|
width: "50%",
|
|
|
},
|
|
|
},
|
|
|
- {
|
|
|
- type: "title",
|
|
|
- title: "产品明细",
|
|
|
- },
|
|
|
+ // {
|
|
|
+ // type: "title",
|
|
|
+ // title: "产品明细",
|
|
|
+ // },
|
|
|
{
|
|
|
type: "slot",
|
|
|
+ label: "产品明细",
|
|
|
slotName: "details",
|
|
|
},
|
|
|
];
|
|
@@ -810,6 +813,7 @@ const clickAdd = (type) => {
|
|
|
contractList.value = [];
|
|
|
formData.data = {
|
|
|
contractIds: [],
|
|
|
+ afterSalesDetailList: [],
|
|
|
};
|
|
|
dialogVisible.value = true;
|
|
|
};
|
|
@@ -839,7 +843,7 @@ const pushGoods = (goods) => {
|
|
|
) {
|
|
|
afterFiltering = goods.filter((item) => {
|
|
|
let data = formData.data.afterSalesDetailList.filter(
|
|
|
- (itemProduct) => itemProduct.bussinessId === item.id
|
|
|
+ (itemProduct) => itemProduct.productId === item.id
|
|
|
);
|
|
|
if (data && data.length > 0) {
|
|
|
return false;
|