| | |
| | | <template #footer> |
| | | <span class="dialog-footer"> |
| | | <el-button type="primary" |
| | | :loading="mergeSubmitLoading" |
| | | @click="handleMergeSubmit">确定下发</el-button> |
| | | <el-button @click="isShowNewModal = false">取消</el-button> |
| | | </span> |
| | |
| | | return params == "销售" ? "销售" : "内部"; |
| | | }, |
| | | }, |
| | | { |
| | | label: "销售合同号", |
| | | prop: "salesContractNo", |
| | | width: "200px", |
| | | dataType: "slot", |
| | | slot: "salesContractNo", |
| | | }, |
| | | |
| | | { |
| | | label: "产品名称", |
| | |
| | | label: "所需数量", |
| | | prop: "qtyRequired", |
| | | width: "150px", |
| | | align: "right", |
| | | dataType: "slot", |
| | | slot: "qtyRequired", |
| | | className: "volume-cell", |
| | |
| | | className: "date-cell", |
| | | formatData: cell => (cell ? dayjs(cell).format("YYYY-MM-DD") : ""), |
| | | }, |
| | | { |
| | | label: "销售合同号", |
| | | prop: "salesContractNo", |
| | | width: "200px", |
| | | dataType: "slot", |
| | | slot: "salesContractNo", |
| | | }, |
| | | |
| | | { |
| | | label: "客户名称", |
| | | prop: "customerName", |
| | |
| | | |
| | | // 合并下发弹窗控制 |
| | | const isShowNewModal = ref(false); |
| | | const mergeSubmitLoading = ref(false); |
| | | // 合并下发表单数据 |
| | | const mergeForm = reactive({ |
| | | productName: "", |
| | |
| | | const payload = { |
| | | ...mergeForm, |
| | | }; |
| | | mergeSubmitLoading.value = true; |
| | | productionPlanCombine(payload) |
| | | .then(res => { |
| | | if (res.code === 200) { |
| | |
| | | .catch(err => { |
| | | console.error("合并下发异常:", err); |
| | | ElMessage.error("系统异常,合并下发失败"); |
| | | }) |
| | | .finally(() => { |
| | | mergeSubmitLoading.value = false; |
| | | }); |
| | | // 可以选择刷新列表或其他操作 |
| | | }; |