| | |
| | | return; |
| | | } |
| | | |
| | | // 检查是否只剩一条数据,销售台账至少保留一条产品 |
| | | if (productData.value.length <= 1) { |
| | | proxy.$modal.msgWarning("销售台账至少需要保留一条产品数据"); |
| | | return; |
| | | } |
| | | |
| | | if (operationType.value === "add") { |
| | | productData.value = productData.value.filter( |
| | | (item) => !productSelectedRows.value.includes(item) |
| | |
| | | return; |
| | | } |
| | | |
| | | // 审批中时提示用户已有待审批的发货记录 |
| | | const statusStr = row.shippingStatus ? String(row.shippingStatus).trim() : ""; |
| | | if (statusStr === "审批中") { |
| | | proxy.$modal.msgWarning("该产品存在待审批的发货记录,请注意避免重复提交"); |
| | | } |
| | | |
| | | currentDeliveryRow.value = row; |
| | | const batchNoList = await getDeliveryBatchNoList( |
| | | row.productModelId || row.modelId |