Ver código fonte

物流单新建调整

qymljy 1 semana atrás
pai
commit
edd48643c0

+ 3 - 1
src/HDrpManagement/logistics/modules/add.vue

@@ -68,7 +68,7 @@
             <dispatch-table type="add" ref="dislist"></dispatch-table>
           </el-col>
           <el-col :span="24 - setcol">
-            <add-disbill v-if="drawer" ref="addbill" :data="enterpriseInfo" :paytype="form.paytype" @onConfirm="onConfirm"></add-disbill>
+            <add-disbill v-if="drawer" ref="addbill" :data="enterpriseInfo" :paytype="form.paytype" @onConfirm="onConfirm" :addList="selectList"></add-disbill>
           </el-col>
         </el-row>
       </div>
@@ -120,6 +120,7 @@ export default {
         ],
       },
       enterpriseInfo:null,
+      selectList:[],
       pickerOptions: {
         disabledDate(time) {
           return time.getTime() < Date.now() - 24 * 3600 * 1000;
@@ -157,6 +158,7 @@ export default {
       this.$refs['dislist'].tableData = unique([...this.$refs['dislist'].tableData,...data],'billno')
       this.isCorrelate = this.$refs.dislist.tableData.length
       this.form.remarks = this.$refs['dislist'].tableData[0].remarks
+      this.selectList = this.$refs.dislist.tableData
     },
     async onSubmit () {
       this.$store.commit('setLoading',true)

+ 1 - 1
src/HDrpManagement/logistics/modules/edit.vue

@@ -66,7 +66,7 @@ ed<template>
         </div>
         <el-row :gutter="10">
           <el-col :span="setcol">
-            <dispatch-table type="edit" :needQuery="true" ref="dislist" @isCorrelation="isCorrelation" @delSuccess="delSuccess"></dispatch-table>
+            <dispatch-table type="edit" :needQuery="true" ref="dislist" @isCorrelation="isCorrelation" @delSuccess="delSuccess" :status="data.status"></dispatch-table>
           </el-col>
           <el-col :span="24 - setcol">
             <add-disbill ref="addbill" :data="enterpriseInfo" @onConfirm="onConfirm" :addList="selectList"></add-disbill>

+ 1 - 3
src/template/logisyticCanUseDisBill/index.vue

@@ -58,7 +58,6 @@
       },
       methods:{
         async listData () {
-
           this.tableData = []
           this.params.content.sa_logisticsid = this.$route.query.id?this.$route.query.id:0
           this.params.content.sys_enterpriseid = this.data.sys_enterpriseid
@@ -66,7 +65,7 @@
           const res = await this.$api.requested(this.params)
 
           // this.tableData = res.data
-          if (this.addList.length > 0){
+          if (this.addList && this.addList.length > 0){
             let indexof = 0
             let dataNew = []
             res.data.forEach((t,indexs)=>{
@@ -76,7 +75,6 @@
                   float = 1
                 }
               })
-              console.log(float,'float')
               if (float != 1){
                 dataNew[indexof] = res.data[indexs]
                 indexof = indexof + 1