Browse Source

成分分配表保存

jbb 2 years ago
parent
commit
b846f4a667

+ 2 - 2
src/api/document/cost-allocation-total.js

@@ -43,6 +43,6 @@ const cancelItemCheck = params => getAction('/cost/syCostAllocation/dApproveByPl
 const seachPlanNum = params => getAction('/cost/syCostAllocation/queryByPlanNum', params)
 
 //保存 到单证汇总列表
-// const addHalfInfo = params => postAction('/cost/syCostAllocation/queryByPlanNum', params)
+const addHalfInfo = params => postAction('/cost/syCostAllocation//add', params)
 
-export { costList, costByPlanNum, itemCheck, cancelItemCheck, seachPlanNum }
+export { costList, costByPlanNum, itemCheck, cancelItemCheck, seachPlanNum,addHalfInfo }

+ 7 - 7
src/views/reportForms/cost-allocation-table.vue

@@ -381,14 +381,14 @@ export default {
         halfInfo.billstatus = '1'
         console.log(halfInfo.planNum, halfInfo.remarks, halfInfo.billstatus)
 
-        // addHalfInfo(halfInfo).then(res => {
-        //   if (res.success) {
-        //     console.log('保存的部分信息', halfInfo)
-        //     this.$message.success('保存成功')
+        addHalfInfo(halfInfo).then(res => {
+          if (res.success) {
+            console.log('保存的部分信息', halfInfo)
+            this.$message.success('保存成功')
 
-        //     halfInfo = {}
-        //   }
-        // })
+            halfInfo = {}
+          }
+        })
       } else {
         this.$message.error('订单号不能为空')
       }