Bladeren bron

Merge branch 'master' of http://139.196.39.194:9021/chenc/sen-yu-new-web

huxy 1 jaar geleden
bovenliggende
commit
3857877e8b

+ 89 - 75
src/views/cost-allocation-total/costDetailDrawer.vue

@@ -121,7 +121,7 @@
             </a-col>
             <a-col :md="6" :sm="8">
               <a-form-model-item label="不含税运杂费(¥)" prop="rmbExpense" >
-                {{detailsPlanNum.rmbExpense }}
+                {{detailsPlanNum.rmbNorTaxExpense }}
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="8">
@@ -217,6 +217,11 @@
                 {{ detailsPlanNum.queryTime  }}
               </a-form-model-item>
             </a-col>
+            <a-col :md="6" :sm="8">
+              <a-form-model-item label="订单汇率" prop="queryTime">
+                {{ detailsPlanNum.exchangeRate  }}
+              </a-form-model-item>
+            </a-col>
             <a-col :md="6" :sm="8" class="noprint">
               <a-form-model-item label="" prop="" >
               <h4 style="color:red;" v-if="color1<0">
@@ -488,7 +493,6 @@ export default {
   methods: {
     // 【计划单号】 搜索
     onSearch() {
-      this.$nextTick(() => {
         // TODO:接口完善后,type 应改为 add(暂时为了回显数据)
         this.loading = true
         seachPlanNum({ plannum: this.planNo, type: 'query' }).then(res => {
@@ -514,13 +518,15 @@ export default {
             //   }
             //调整表头格式
             this.adjustingHeader()
-            this.accidentListData = res.result.syCostAllocationAccidentList //事故单
-            this.accidentCalculation(this.accidentListData)
+            // this.accidentListData = res.result.syCostAllocationAccidentList //事故单
+            // this.accidentCalculation(this.accidentListData)
             // var accidentNum = 0
             // this.accidentListData.map(item =>{
             //   item.id = accidentNum + 1
             //   accidentNum += 1
             // })
+            this.accidentListData = res.result.syCostAllocationAccidentList //事故单
+            this.accidentCalculation(this.accidentListData)   //计算事故单美元金额和事故单人民币金额
             this.costPayData = res.result.syCostAllocationCostpayList //支出费用
             var num = 0
             this.costPayData.map(item =>{
@@ -529,46 +535,54 @@ export default {
             })
             // tabs 名称集合
             this.$refs.unitTabs.tabNameList = res.result.processUnit.split(',')
-
             //所有tabs数据
             this.$refs.unitTabs.tabsAllData = res.result.processUnitList
 
             // 页面打开加载的数据
             var oneData = this.$refs.unitTabs.tabsAllData[0]
             this.$refs.unitTabs.fabData = oneData.syCostAllocationFabricList
+            var all = 0,//面料sheet-转入成本总计
+                allYu = 0//面料sheet-余下数量成本总计
             this.$refs.unitTabs.fabData.map(item=>{
               if(item.remainingQuantitycost!=='' && item.remainingQuantitycost){
                 item.remainingQuantitycost = item.remainingQuantitycost.toFixed(2)
+                allYu +=Number(item.remainingQuantitycost)
+              }
+              if(item.transferCost&&item.transferCost!==''){
+                all+=Number(item.transferCost)
               }
             })
-            this.$refs.unitTabs.ingData = oneData.syCostAllocationIngredientList
-            this.$refs.unitTabs.shipData = oneData.syCostAllocationShipdetail
-            this.$refs.unitTabs.Refresh()
-            this.addAmountIng(oneData.syCostAllocationIngredientList)
-            this.addAmountCostPay(this.costPayData)
-            this.addAccident(this.accidentListData)
-            this.calculation(oneData.syCostAllocationShipdetail)
+            this.fabricCost = this.detailsPlanNum.fabriccostIncludestax
+            this.detailsPlanNum.fabriccostIncludestax = (all+Number(this.detailsPlanNum.fabriccostIncludestax)-allYu).toFixed(2) // 表头面料成本(¥)
+            this.detailsPlanNum.fabriccostIncludestaxUsd = (Number(this.detailsPlanNum.fabriccostIncludestax)/1.13/this.detailsPlanNum.exchangeRate).toFixed(2)//表头面料成本($)
+            this.detailsPlanNum.fabriccostNotincludestax = (Number(this.detailsPlanNum.fabriccostIncludestax)/(1+(Number(this.detailsPlanNum.taxrate)/100))).toFixed(2)//表头-面料不含税成本(¥)
+            this.$refs.unitTabs.ingData = oneData.syCostAllocationIngredientList //辅料sheet数据源
+            this.$refs.unitTabs.shipData = oneData.syCostAllocationShipdetail //发运明细sheet数据源
+            this.detailsPlanNum.outdata = oneData.syCostAllocationShipdetail.length!==0?oneData.syCostAllocationShipdetail[0].outdata:'' //表头-出运日期
+            this.addAmountIng(oneData.syCostAllocationIngredientList) //辅料sheet合计行
+            this.addAmountCostPay(this.costPayData) //费用支出合计行
+            this.addAccident(this.accidentListData)//事故单合计行
+            this.calculation(oneData.syCostAllocationShipdetail) //出运明细合计行
             //合计中面料相关金额
             var s=0
             oneData.syCostAllocationFabricList.map(item=>{
               s+=Number(item.transferCost)
             })
-            //  this.$refs.unitTabs.sumInfo.fabricAmount = s.toFixed(3) //合计中的面料总额
              this.$refs.unitTabs.sumInfo.fabricAmount = (this.detailsPlanNum.fabriccostIncludestax!==''&&this.detailsPlanNum.fabriccostIncludestax)?(Number(this.detailsPlanNum.fabriccostIncludestax)).toFixed(2):'' //合计中的面料总额
-             this.$refs.unitTabs.sumInfo.fabricExcludTax =(Number(this.$refs.unitTabs.sumInfo.fabricAmount)/(1+(Number(this.detailsPlanNum.taxrate)/100))).toFixed(2)//合计中的不含税面料总额
-             this.detailsPlanNum.fabriccostNotincludestax =  this.$refs.unitTabs.sumInfo.fabricExcludTax
-             // this.detailsPlanNum.fabriccostIncludestax = s.toFixed(3) //表头中面料含税总额
-            // this.detailsPlanNum.fabriccostNotincludestax = (s/1.13).toFixed(3) //表头中面料不含税总额
+             this.$refs.unitTabs.sumInfo.fabricExcludTax =(this.detailsPlanNum.fabriccostNotincludestax!==''&&this.detailsPlanNum.fabriccostNotincludestax)?(Number(this.detailsPlanNum.fabriccostNotincludestax)).toFixed(2):''//合计中的不含税面料总额
             //合计中辅料相关金额
             var s = 0,
-            v =0
+            v =0,
+            t=0
             oneData.syCostAllocationIngredientList.map(item=>{
-              s+=Number(item.priceExcludingtax),
+              s+=item.priceExcludingtax?Number(item.priceExcludingtax):0,
               v+=item.rmbAmount?Number(item.rmbAmount):0
+              t+=item.transferCost?Number(item.transferCost):0
             })
-            this.$refs.unitTabs.sumInfo.ingAmount =(v/2).toFixed(2)//辅料金额合计
-            this.$refs.unitTabs.sumInfo.ingExcludAmount = ((v/2).toFixed(2)/(1+(Number(this.detailsPlanNum.taxrate)/100))).toFixed(2)//辅料不含税金额合计
-            this.detailsPlanNum.excipiencostNotincludestax =  this.$refs.unitTabs.sumInfo.ingExcludAmount
+            this.$refs.unitTabs.sumInfo.ingAmount =((v/2)+(t/2)).toFixed(2)//辅料金额合计
+            this.$refs.unitTabs.sumInfo.ingExcludAmount = (((s/2)+(t/2)/(1+(Number(this.detailsPlanNum.taxrate)/100)))).toFixed(2)//合计sheet辅料不含税金额合计
+            this.detailsPlanNum.excipiencostNotincludestax =  ( this.$refs.unitTabs.sumInfo.ingExcludAmount==''|| !this.$refs.unitTabs.sumInfo.ingExcludAmount)?0:Number(this.$refs.unitTabs.sumInfo.ingExcludAmount).toFixed(2)//表头辅料料不含税成本   
+            this.detailsPlanNum.excipiencostIncludestax =   (  this.$refs.unitTabs.sumInfo.ingAmount ==''|| ! this.$refs.unitTabs.sumInfo.ingAmount )?0:Number( this.$refs.unitTabs.sumInfo.ingAmount ).toFixed(2)//表头辅料成本(¥)
             //合计中出运明细相关金额
             var s =0,
             v = 0,
@@ -581,11 +595,10 @@ export default {
               v+=Number(item.shipQuantity)
               d+=Number(item.processCost)
               b+=Number(item.rmbAmount)
-              if(item.exchangeRate=='6.888' && item.outdata!=='合计'){
-                 e+=Number(item.processCost)
-              }else if(item.outdata!=='合计'){
-                e+=(Number(item.processCost)/1.13)
+              if(item.outdata!=='合计'){
+                e+=Number(item.processCostUsd)
               }
+              
             })
             this.$refs.unitTabs.sumInfo.exportPriceUSD = (s/2).toFixed(2)//出运美元外销总价
             this.detailsPlanNum.usdTotalexportprice = this.$refs.unitTabs.sumInfo.exportPriceUSD //表头-外销总价($)
@@ -593,9 +606,18 @@ export default {
             this.$refs.unitTabs.sumInfo.shipProcesFees =(d/2).toFixed(2)//出运加工费
             this.$refs.unitTabs.sumInfo.exportedAmountRMB =(b/2).toFixed(2)//出运人民币外销金额 f
             this.detailsPlanNum.rmbExportamount = this.$refs.unitTabs.sumInfo.exportedAmountRMB //表头-外销总价(¥)
-            this.$refs.unitTabs.sumInfo.excludingTaxProcessing =e.toFixed(2)//
+             //调整表头格式
+             this.adjustingHeader()
+           if(Number(oneData.syCostAllocationShipdetail[0].procesUnitPriceusd)>0){
+            this.$refs.unitTabs.sumInfo.excludingTaxProcessing =this.$refs.unitTabs.sumInfo.shipProcesFees//出运不含税加工费-合计信息
+             }else{
+              this.$refs.unitTabs.sumInfo.excludingTaxProcessing =( this.$refs.unitTabs.sumInfo.shipProcesFees/(1+(Number(this.detailsPlanNum.taxrate)/100))).toFixed(2)//出运不含税加工费
+             }    
+             this.detailsPlanNum.rmbProcesscost = this.$refs.unitTabs.sumInfo.excludingTaxProcessing //表头-加工费人民币
+             f= Number(this.$refs.unitTabs.sumInfo.excludingTaxProcessing)/Number(this.detailsPlanNum.exchangeRate)
+             this.detailsPlanNum.usdProcesscost =e==0?(Number(this.detailsPlanNum.rmbProcesscost)/Number(this.detailsPlanNum.exchangeRate)).toFixed(2):e.toFixed(2)//表头-加工费美元
             f=Number(this.$refs.unitTabs.sumInfo.ingAmount)+Number(this.$refs.unitTabs.sumInfo.shipProcesFees)
-            this.$refs.unitTabs.sumInfo.amountTotal = (Number(this.$refs.unitTabs.sumInfo.fabricExcludTax)+Number(this.$refs.unitTabs.sumInfo.ingExcludAmount)+Number( this.$refs.unitTabs.sumInfo.shipProcesFees)).toFixed(2)//合计金额
+            this.$refs.unitTabs.sumInfo.amountTotal = (Number(this.$refs.unitTabs.sumInfo.fabricAmount)+Number(this.$refs.unitTabs.sumInfo.ingAmount)+Number( this.$refs.unitTabs.sumInfo.shipProcesFees)).toFixed(2)//合计金额
             this.pagination = {
               total: res.result.total,
               current: res.result.current,
@@ -607,32 +629,24 @@ export default {
             this.$message.error(res.message);
           }
         })
-      })
     },
     //调整表头格式
     adjustingHeader(){
-      this.detailsPlanNum.outdata = ( this.detailsPlanNum.outdata==''||!this.detailsPlanNum.outdata)?'':moment( this.detailsPlanNum.outdata).format('YYYY-MM-DD')
-      this.detailsPlanNum.planQuantity=( this.detailsPlanNum.planQuantity==''|| !this.detailsPlanNum.planQuantity)?'':Number( this.detailsPlanNum.planQuantity).toFixed(0)//计划数量
-      this.detailsPlanNum.usdTotalexportprice=( this.detailsPlanNum.usdTotalexportprice==''|| !this.detailsPlanNum.usdTotalexportprice)?'':Number( this.detailsPlanNum.usdTotalexportprice).toFixed(2)//美元外销总价
-      this.detailsPlanNum.rmbExpense=( this.detailsPlanNum.rmbExpense==''|| !this.detailsPlanNum.rmbExpense)?'':Number( this.detailsPlanNum.rmbExpense).toFixed(2)//人民币费用支出
-      this.detailsPlanNum.actualShipquantity=( this.detailsPlanNum.actualShipquantity==''|| !this.detailsPlanNum.actualShipquantity)?'':Number( this.detailsPlanNum.actualShipquantity).toFixed(0)//实际出库数量
-      this.detailsPlanNum.rmbExportamount=( this.detailsPlanNum.rmbExportamount==''|| !this.detailsPlanNum.rmbExportamount)?'':Number( this.detailsPlanNum.rmbExportamount).toFixed(2)//人民币外销金额
-      this.detailsPlanNum.usdExpense=( this.detailsPlanNum.usdExpense==''|| !this.detailsPlanNum.usdExpense)?'':Number( this.detailsPlanNum.usdExpense).toFixed(2)//美元费用支出
-      // this.detailsPlanNum.rmbProcesscost=( this.detailsPlanNum.rmbProcesscost==''|| !this.detailsPlanNum.rmbProcesscost)?'':Number( this.detailsPlanNum.rmbProcesscost).toFixed(2)//加工费(人民币)
-      this.detailsPlanNum.accidentUsdamount=( this.detailsPlanNum.accidentUsdamount==''|| !this.detailsPlanNum.accidentUsdamount)?'':Number( this.detailsPlanNum.accidentUsdamount).toFixed(2)//事故单美元金额
-      this.detailsPlanNum.fabriccostIncludestax=( this.detailsPlanNum.fabriccostIncludestax==''|| !this.detailsPlanNum.fabriccostIncludestax)?'':Number( this.detailsPlanNum.fabriccostIncludestax).toFixed(2)//面料含税成本
-      this.detailsPlanNum.excipiencostIncludestax=( this.detailsPlanNum.excipiencostIncludestax==''|| !this.detailsPlanNum.excipiencostIncludestax)?'':Number( this.detailsPlanNum.excipiencostIncludestax).toFixed(2)//辅料含税成本
-      this.detailsPlanNum.salesordersLocaltotal=( this.detailsPlanNum.salesordersLocaltotal==''|| !this.detailsPlanNum.salesordersLocaltotal)?'':Number( this.detailsPlanNum.salesordersLocaltotal).toFixed(2)//销售本币金额
-      this.detailsPlanNum.accidentcnyAmount=( this.detailsPlanNum.accidentcnyAmount==''|| !this.detailsPlanNum.accidentcnyAmount)?'':Number( this.detailsPlanNum.accidentcnyAmount).toFixed(2)//事故单人民币金额   
-      this.detailsPlanNum.fabriccostNotincludestax=( this.detailsPlanNum.fabriccostNotincludestax==''|| !this.detailsPlanNum.fabriccostNotincludestax)?'':Number( this.detailsPlanNum.fabriccostNotincludestax).toFixed(2)//面料不含税成本   
-      this.detailsPlanNum.excipiencostNotincludestax=( this.detailsPlanNum.excipiencostNotincludestax==''|| !this.detailsPlanNum.excipiencostNotincludestax)?'':Number( this.detailsPlanNum.excipiencostNotincludestax).toFixed(2)//辅料料不含税成本   
-      this.detailsPlanNum.salesrrdersOriginaltotal=( this.detailsPlanNum.salesrrdersOriginaltotal==''|| !this.detailsPlanNum.salesrrdersOriginaltotal)?'':Number( this.detailsPlanNum.salesrrdersOriginaltotal).toFixed(2)//销售订单原币金额   
+      this.detailsPlanNum.planQuantity=( this.detailsPlanNum.planQuantity==''|| !this.detailsPlanNum.planQuantity)?0:Number( this.detailsPlanNum.planQuantity).toFixed(0)//计划数量
+      this.detailsPlanNum.usdTotalexportprice=( this.detailsPlanNum.usdTotalexportprice==''|| !this.detailsPlanNum.usdTotalexportprice)?0:Number( this.detailsPlanNum.usdTotalexportprice).toFixed(2)//美元外销总价
+      this.detailsPlanNum.actualShipquantity=( this.detailsPlanNum.actualShipquantity==''|| !this.detailsPlanNum.actualShipquantity)?0:Number( this.detailsPlanNum.actualShipquantity).toFixed(0)//实际出库数量
+      this.detailsPlanNum.rmbExportamount=( this.detailsPlanNum.rmbExportamount==''|| !this.detailsPlanNum.rmbExportamount)?0:Number( this.detailsPlanNum.rmbExportamount).toFixed(2)//人民币外销金额
+      this.detailsPlanNum.usdExpense=( this.detailsPlanNum.usdExpense==''|| !this.detailsPlanNum.usdExpense)?0:Number( this.detailsPlanNum.usdExpense).toFixed(2)//美元费用支出
+      this.detailsPlanNum.usdProcesscost=( this.detailsPlanNum.usdProcesscost==''|| !this.detailsPlanNum.usdProcesscost)?'':Number( this.detailsPlanNum.usdProcesscost).toFixed(2)//加工费(人民币)
+      this.detailsPlanNum.accidentUsdamount=( this.detailsPlanNum.accidentUsdamount==''|| !this.detailsPlanNum.accidentUsdamount)?0:Number( this.detailsPlanNum.accidentUsdamount).toFixed(2)//事故单美元金额
+      this.detailsPlanNum.salesordersLocaltotal=( this.detailsPlanNum.salesordersLocaltotal==''|| !this.detailsPlanNum.salesordersLocaltotal)?0:Number( this.detailsPlanNum.salesordersLocaltotal).toFixed(2)//销售本币金额
+      this.detailsPlanNum.accidentcnyAmount=( this.detailsPlanNum.accidentcnyAmount==''|| !this.detailsPlanNum.accidentcnyAmount)?0:Number( this.detailsPlanNum.accidentcnyAmount).toFixed(2)//事故单人民币金额   
+      this.detailsPlanNum.salesrrdersOriginaltotal=( this.detailsPlanNum.salesrrdersOriginaltotal==''|| !this.detailsPlanNum.salesrrdersOriginaltotal)?0:Number( this.detailsPlanNum.salesrrdersOriginaltotal).toFixed(2)//销售订单原币金额  
+      this.detailsPlanNum.excipiencostIncludestaxUsd=( this.detailsPlanNum.excipiencostIncludestaxUsd==''|| !this.detailsPlanNum.excipiencostIncludestaxUsd)?0: this.detailsPlanNum.excipiencostIncludestaxUsd//辅料成本($)
+      this.detailsPlanNum.shuiemoney=( this.detailsPlanNum.shuiemoney==''|| !this.detailsPlanNum.shuiemoney)?0: this.detailsPlanNum.shuiemoney//运费税额
       this.color1 = Number(this.detailsPlanNum.rmbExportamount)-Number(this.detailsPlanNum.fabriccostNotincludestax)-Number(this.detailsPlanNum.excipiencostNotincludestax)-Number(this.detailsPlanNum.rmbProcesscost)-Number(this.detailsPlanNum.rmbExpense)
       this.color2 = this.color1/Number(this.detailsPlanNum.usdTotalexportprice)
       this.color2 = this.color2>0?this.color2:-this.color2
-      if(this.detailsPlanNum.pkOrg=='103'){
-        this.detailsPlanNum.rmbProcesscost = (Number(this.detailsPlanNum.rmbProcesscost)/(1+(Number(this.detailsPlanNum.taxrate)/100))).toFixed(2)
-      }
     },
 
 
@@ -760,42 +774,25 @@ export default {
     },
     //计算出运明细合计行
     calculation(val){
-      // var  average = 0
-      //  val.map(item=>{
-      //   if(item.outdata !=='合计'){
-      //     average += (Number(item.exportUnitPrice)*Number(item.shipQuantity)*Number(item.exchangeRate))
-      //   }
-      //  })
-      //  this.detailsPlanNum.shortvalue = average.toFixed(2)
-       var shipQuantityAll =0,
-        // exportUnitPriceALll = 0,
+      var shipQuantityAll =0,
         exportPriceAll =0,
         rmbAmountAll = 0,
-        // procesUnitPricermbAll = 0,
-        // procesUnitPriceusdAll = 0,
         processCostAll = 0
         val.map(item=>{
           if(item.outdata !=='合计'){
           shipQuantityAll+=Number(item.shipQuantity)
-          // exportUnitPriceALll+=Number(item.exportUnitPrice)
           exportPriceAll+=Number(item.exportPrice)
           rmbAmountAll+=Number(item.rmbAmount)
-          // procesUnitPricermbAll+=Number(item.procesUnitPricermb)
-          // procesUnitPriceusdAll+=Number(item.procesUnitPriceusd)
           processCostAll+=Number(item.processCost)
           }
         })
         var allObj ={
           outdata:'合计',
           shipQuantity:shipQuantityAll.toFixed(3),
-          // exportUnitPrice:exportUnitPriceALll.toFixed(3),
           exportPrice:exportPriceAll.toFixed(3),
           rmbAmount:rmbAmountAll.toFixed(3),
-          // procesUnitPricermb:procesUnitPricermbAll.toFixed(3),
-          // procesUnitPriceusd:procesUnitPriceusdAll.toFixed(3),
           processCost:processCostAll.toFixed(3)
         }
-        this.detailsPlanNum.salesordersLocaltotal = rmbAmountAll.toFixed(2)
         //发运明细-合计行
         if(this.$refs.unitTabs.shipData.length!==0 ){
           if(this.$refs.unitTabs.shipData[this.$refs.unitTabs.shipData.length-1].outdata=='合计'){
@@ -820,12 +817,13 @@ export default {
       rmbAmountAll = 0,
       usdAmountAll = 0,
       priceExcludingtaxAll = 0
-        val.map(item=>{
+      this.$refs.unitTabs.ingData.map(item=>{
           if(item.goodsName!=='合计'){
-          transferCostAll+=Number(item.transferCost)
-          rmbAmountAll+=item.rmbAmount?Number(item.rmbAmount):0
-          usdAmountAll+=item.usdAmount?Number(item.usdAmount):0
-          priceExcludingtaxAll+=item.priceExcludingtax?Number(item.priceExcludingtax):0
+            item.usdAmount = ((item.priceExcludingtax?Number(item.priceExcludingtax):0)/this.detailsPlanNum.exchangeRate)
+            if(item.rmbAmount !== item.usdAmount){  usdAmountAll+=item.usdAmount?Number(item.usdAmount):0   }
+            transferCostAll+=item.transferCostAll?Number(item.transferCost):0
+            rmbAmountAll+=item.rmbAmount?Number(item.rmbAmount):0
+            priceExcludingtaxAll+=item.priceExcludingtax?Number(item.priceExcludingtax):0
           }
         })
       var allObj ={
@@ -835,13 +833,17 @@ export default {
           usdAmount:usdAmountAll,
           priceExcludingtax:priceExcludingtaxAll,
           ingredientsTransferQuantity:'',
-          ingredientsRemainingQuantity:'',
-          remarks:'heji'
+          ingredientsRemainingQuantity:''
         }  
         if(this.$refs.unitTabs.ingData.length!==0 ){
           if(this.$refs.unitTabs.ingData[this.$refs.unitTabs.ingData.length-1].goodsName=='合计'){this.$refs.unitTabs.ingData.pop()}
             this.$refs.unitTabs.ingData.push(allObj)
           }
+          if(rmbAmountAll == usdAmountAll){
+            this.detailsPlanNum.excipiencostIncludestaxUsd = 0
+          }else{
+            this.detailsPlanNum.excipiencostIncludestaxUsd = usdAmountAll.toFixed(2)
+          }
     },
     //事故单合计行
     addAccident(val){
@@ -870,7 +872,7 @@ export default {
       shuiemoneyAll = 0
      val.map(item=>{
       if(item.setNo!=='合计'){
-      disbursedLocalmoneyALL+=Number(item.disbursedLocalmoney) 
+      disbursedLocalmoneyALL+=item.disbursedLocalmoney?Number(item.disbursedLocalmoney):0
       disbursedOriginalmoneyALL+=Number(item.disbursedOriginalmoney) 
       shuiemoneyAll+=Number(item.shuiemoney) 
       }
@@ -886,6 +888,10 @@ export default {
       if(this.costPayData[this.costPayData.length-1].setNo=='合计'){this.costPayData.pop()}
        this.costPayData.push(obj)
       }
+      this.detailsPlanNum.shuiemoney = shuiemoneyAll.toFixed(3)
+      this.detailsPlanNum.rmbNorTaxExpense = Number(obj.disbursedLocalmoney).toFixed(2)
+      this.detailsPlanNum.rmbExpense = Number(obj.iNatMoney).toFixed(2)
+      this.detailsPlanNum.usdExpense = (Number(this.detailsPlanNum.rmbNorTaxExpense)/Number(this.detailsPlanNum.exchangeRate)).toFixed(2)
     },
     daYin(){
          this.showSelect = 1
@@ -978,7 +984,15 @@ export default {
     },
     number(data1,data2){
       this.detailsPlanNum.fabriccostNotincludestax =  data1
-      this.detailsPlanNum.excipiencostNotincludestax =  data2
+    },
+    FabInQua(data,allYu){
+      this.detailsPlanNum.fabriccostIncludestax=(Number(data)+Number(this.fabricCost)-Number(allYu)).toFixed(2)//面料含税成本
+      this.detailsPlanNum.fabriccostIncludestaxUsd = (Number(this.detailsPlanNum.fabriccostIncludestax)/1.13/this.detailsPlanNum.exchangeRate).toFixed(2)//表头面料成本($)
+      this.detailsPlanNum.fabriccostNotincludestax = (Number(this.detailsPlanNum.fabriccostIncludestax)/(1+(Number(this.detailsPlanNum.taxrate)/100))).toFixed(2)
+      this.$refs.unitTabs.sumInfo.fabricAmount=this.detailsPlanNum.fabriccostIncludestax
+      this.$refs.unitTabs.sumInfo.fabricExcludTax =(this.detailsPlanNum.fabriccostNotincludestax!==''&&this.detailsPlanNum.fabriccostNotincludestax)?(Number(this.detailsPlanNum.fabriccostNotincludestax)).toFixed(2):''//合计中的不含税面料总额
+      this.$refs.unitTabs.sumInfo.amountTotal = (Number(this.$refs.unitTabs.sumInfo.fabricAmount)+Number(this.$refs.unitTabs.sumInfo.ingAmount)+Number( this.$refs.unitTabs.sumInfo.shipProcesFees)).toFixed(2)//合计金额
+     
     },
 
     // father 方法

+ 6 - 2
src/views/cost-allocation-total/fabricLossesSummary.vue

@@ -71,8 +71,8 @@
             </a-col>
             <a-col :md="6" :sm="8">
             <a-form-item label="状态">
-                <a-select v-model="queryParam.status">
-                    <a-select-option value="">请选择</a-select-option>
+                <a-select   mode="multiple"  @change="handleChange">
+                    <!-- <a-select-option value="">请选择</a-select-option> -->
                     <a-select-option value="保存">保存</a-select-option>
                     <a-select-option value="提交">提交</a-select-option>
                     <a-select-option value="已指派">已指派</a-select-option>
@@ -332,12 +332,16 @@ export default {
       //     }
       //   })
     },
+    handleChange(value){
+      this.queryParam.status = value.toString()
+    },
     details(record){
       this.$refs.detailFabricLossTable.detailModVis = true
       this.$refs.detailFabricLossTable.status = record.status
       this.$refs.detailFabricLossTable.onSearch(record.ccode,'0')
     },
     searchQuery() {
+      this.queryParam.pageNo = '1'
       this.getCostList()
     },
     searchReset() {

+ 33 - 6
src/views/cost-allocation-total/inancialReconciliation.vue

@@ -41,8 +41,8 @@
             </a-col> -->
               <a-col :md="6" :sm="8">
               <a-form-item label="面损表单据状态">
-                <a-select v-model="queryParam.fstatus">
-                    <a-select-option value="">请选择</a-select-option>
+                <a-select   mode="multiple"  @change="handleChange">
+                    <!-- <a-select-option value="">请选择</a-select-option> -->
                     <a-select-option value="保存">保存</a-select-option>
                     <a-select-option value="提交">提交</a-select-option>
                     <a-select-option value="返单">返单</a-select-option>
@@ -55,8 +55,8 @@
             </a-col>
               <a-col :md="6" :sm="8">
               <a-form-item label="分配表单据状态">
-                <a-select v-model="queryParam.cstatus">
-                    <a-select-option value="">请选择</a-select-option>
+                <a-select   mode="multiple"  @change="handleChangeCstatus">
+                    <!-- <a-select-option value="">请选择</a-select-option> -->
                     <a-select-option value="保存">保存</a-select-option>
                     <a-select-option value="提交">提交</a-select-option>
                     <a-select-option value="返单">返单</a-select-option>
@@ -153,6 +153,11 @@
             <!-- <a-input placeholder="请输入" v-model="record.ffinalApproveDate" v-if="record.enter=='1'"></a-input> -->
             <span v-if="record.enter=='0'">{{text}}</span>
         </span>
+        <span slot="readyEndDate" slot-scope="text, record">
+          <a-date-picker style="width: 100%" v-model="record.readyEndDate"   :format="dateFormat" v-if="record.enter=='1'" @change="changeReadyEndData()"> </a-date-picker>
+            <span v-if="record.enter=='0'">{{text}}</span>
+        </span>
+        
         <span slot="option" slot-scope="text, record">
             <a :disabled="record.enter=='0'" @click="sava(record)"> 保存</a>
             <a-divider type="vertical" />
@@ -246,6 +251,7 @@ export default {
             return new Date(a.fsubmitDate) > new Date(b.fsubmitDate) ? 1 : -1;
           },
         },
+       
         {
           title: '返单日期',
           width: 120,
@@ -298,7 +304,7 @@ export default {
             return new Date(a.ffinalApproveDate) > new Date(b.ffinalApproveDate) ? 1 : -1;
           },
         },
-        { title: '面损表单据状态', width: 90, dataIndex: 'fstatus', className: 'replacecolor',
+        { title: '面损表单据状态', width: 120, dataIndex: 'fstatus', className: 'replacecolor',
         sorter:(a,b)=> {
                   let temp1="";
                   let temp2="";
@@ -328,6 +334,16 @@ export default {
             return new Date(a.csubmitDate) > new Date(b.csubmitDate) ? 1 : -1;
           },
         },
+        {
+          title: '刷成衣结束日期',
+          width: 170,
+          dataIndex: 'readyEndDate',
+          scopedSlots: { customRender: 'readyEndDate' },
+          className: 'replacecolor',
+          sorter: (a, b) => {
+            return new Date(a.readyEndDate) > new Date(b.readyEndDate) ? 1 : -1;
+          },
+        },
         {
           title: '返单日期',
           width: 120,
@@ -428,6 +444,7 @@ export default {
             this.costAllocationData.map(item=>{
               item.enter = '0'
               item.ffinalApproveDate = item.ffinalApproveDate!==''&&item.ffinalApproveDate ? moment(item.ffinalApproveDate).format('YYYY-MM-DD'):''
+              item.readyEndDate = item.readyEndDate!==''&&item.readyEndDate ? moment(item.readyEndDate).format('YYYY-MM-DD'):''
             })
             this.pagination = {
               total: res.result.total,
@@ -452,6 +469,15 @@ export default {
     searchQuery() {
       this.getCostList()
     },
+    changeReadyEndData(){
+      this.$forceUpdate()
+    },
+    handleChange(value){
+      this.queryParam.fstatus = value.toString()
+    },
+    handleChangeCstatus(value){
+      this.queryParam.cstatus = value.toString()
+    },
     changeCreateTime(){
        this.queryParam.dverifyDateE=( this.dverifyDate.length==2)?this.dverifyDate[1].format('YYYY-MM-DD'):''
        this.queryParam.dverifyDateB=(  this.dverifyDate.length==2)?this.dverifyDate[0].format('YYYY-MM-DD'):''
@@ -488,7 +514,8 @@ export default {
         planNum : record.planNo,
         planMan:record.planMan,
         remarks:record.remarks,
-        id:record.id
+        id:record.id,
+        readyEndDate: record.readyEndDate!==''&&record.readyEndDate ? moment(record.readyEndDate).format('YYYY-MM-DD HH:mm:ss'):''
       }
       var newObj ={
           ccode:record.planNo,

+ 5 - 2
src/views/cost-allocation-total/list.vue

@@ -86,8 +86,8 @@
             </a-col>
             <a-col :md="6" :sm="8">
             <a-form-item label="单据状态">
-                <a-select v-model="queryParam.status">
-                    <a-select-option value="">请选择</a-select-option>
+                <a-select  mode="multiple"  @change="handleChange">
+                    <!-- <a-select-option value="">请选择</a-select-option> -->
                     <a-select-option value="保存">保存</a-select-option>
                     <a-select-option value="提交">提交</a-select-option>
                     <a-select-option value="已指派">已指派</a-select-option>
@@ -351,6 +351,9 @@ export default {
       this.queryParam = {}
       this.getCostList()
     },
+    handleChange(value){
+      this.queryParam.status = value.toString()
+    },
     handleApply(record){
       var data = {
         type:"成本表",

+ 4 - 4
src/views/pre-book/advancePackingListModal.vue

@@ -369,8 +369,8 @@ export default {
        var distributionPointTest = [],
        customerTest = []
        this.selectedRows.map(item=>{
-         distributionPointTest.push(item.distributionPoint)
-         customerTest.push(item.customerAbbreviation)
+         distributionPointTest.push((item.distributionPoint).toLowerCase())
+         customerTest.push((item.customerAbbreviation).toLowerCase())
       })
       if([...new Set(distributionPointTest)].length !== 1){this.error.push('分销点')}
       if([...new Set(customerTest)].length !== 1){this.error.push('客户')}
@@ -379,8 +379,8 @@ export default {
      //已有参考列表
     fatherDataSet(fathers,sons){
       var father = fathers[0]
-      if(father.distributionPoint !== sons.distributionPoint){this.errorFather.push('分销点')}
-      if(father.clientAbbreviation !== sons.customerAbbreviation){this.errorFather.push('客户简称')}
+      if((father.distributionPoint).toLowerCase() !== (sons.distributionPoint).toLowerCase()){this.errorFather.push('分销点')}
+      if((father.clientAbbreviation).toLowerCase() !== (sons.customerAbbreviation).toLowerCase()){this.errorFather.push('客户简称')}
     },
 
 

+ 19 - 13
src/views/reportForms/cost-allocation-table.vue

@@ -204,6 +204,11 @@
                 {{ detailsPlanNum.queryTime  }}
               </a-form-model-item>
             </a-col>
+            <a-col :md="6" :sm="8">
+              <a-form-model-item label="订单汇率" prop="queryTime">
+                {{ detailsPlanNum.exchangeRate  }}
+              </a-form-model-item>
+            </a-col>
             <a-col :md="6" :sm="8" class="noprint">
               <a-form-model-item label="" prop="" >
               <h4 style="color:red;" v-if="color1<0">
@@ -229,7 +234,7 @@
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="8" class="noprint">
-              <a-upload  productName="file" :showUploadList="true" :file-list="fileList" :headers="tokenHeader" :multiple="false"   :action="importExcelUrl"  @change="handleImportExcel"  :data="{code:this.detailsPlanNum.planNum,name:this.fileName}"  :beforeUpload="uploadFlie" :remove="removeFile">
+              <a-upload  productName="file" :showUploadList="false" :file-list="fileList" :headers="tokenHeader" :multiple="false"   :action="importExcelUrl"  @change="handleImportExcel"  :data="{code:this.detailsPlanNum.planNum,name:this.fileName}"  :beforeUpload="uploadFlie" :remove="removeFile">
                 <a-button type="primary" >附件上传</a-button>
               </a-upload>
             </a-col>
@@ -533,7 +538,7 @@ export default {
             })
             this.fabricCost = this.detailsPlanNum.fabriccostIncludestax
             this.detailsPlanNum.fabriccostIncludestax = (all+Number(this.detailsPlanNum.fabriccostIncludestax)-allYu).toFixed(2) // 表头面料成本(¥)
-            this.detailsPlanNum.fabriccostIncludestaxUsd = (Number(this.detailsPlanNum.fabriccostIncludestax)/this.detailsPlanNum.exchangeRate).toFixed(2)//表头面料成本($)
+            this.detailsPlanNum.fabriccostIncludestaxUsd = (Number(this.detailsPlanNum.fabriccostIncludestax)/1.13/this.detailsPlanNum.exchangeRate).toFixed(2)//表头面料成本($)
             this.detailsPlanNum.fabriccostNotincludestax = (Number(this.detailsPlanNum.fabriccostIncludestax)/(1+(Number(this.detailsPlanNum.taxrate)/100))).toFixed(2)//表头-面料不含税成本(¥)
             this.$refs.unitTabs.ingData = oneData.syCostAllocationIngredientList //辅料sheet数据源
             this.$refs.unitTabs.shipData = oneData.syCostAllocationShipdetail //发运明细sheet数据源
@@ -575,7 +580,7 @@ export default {
               d+=Number(item.processCost)
               b+=Number(item.rmbAmount)
               if(item.outdata!=='合计'){
-                e+=Number(item.procesUnitPriceusd)
+                e+=Number(item.processCostUsd)
               }
               
             })
@@ -594,7 +599,7 @@ export default {
              }    
              this.detailsPlanNum.rmbProcesscost = this.$refs.unitTabs.sumInfo.excludingTaxProcessing //表头-加工费人民币
              f= Number(this.$refs.unitTabs.sumInfo.excludingTaxProcessing)/Number(this.detailsPlanNum.exchangeRate)
-             this.detailsPlanNum.usdProcesscost =e.toFixed(2)//表头-加工费美元
+             this.detailsPlanNum.usdProcesscost =e==0?(Number(this.detailsPlanNum.rmbProcesscost)/Number(this.detailsPlanNum.exchangeRate)).toFixed(2):e.toFixed(2)//表头-加工费美元
             f=Number(this.$refs.unitTabs.sumInfo.ingAmount)+Number(this.$refs.unitTabs.sumInfo.shipProcesFees)
             this.$refs.unitTabs.sumInfo.amountTotal = (Number(this.$refs.unitTabs.sumInfo.fabricAmount)+Number(this.$refs.unitTabs.sumInfo.ingAmount)+Number( this.$refs.unitTabs.sumInfo.shipProcesFees)).toFixed(2)//合计金额
             this.pagination = {
@@ -617,14 +622,14 @@ export default {
                   }
                 })
                 if(item.transferCost&&item.transferCost!==''){
-                    all+=item.transferCost
+                    all+=Number(item.transferCost)
                   }
                   if(item.remainingQuantitycost&&item.remainingQuantitycost!==''){
-                    allYu+=item.remainingQuantitycost
+                    allYu+=Number(item.remainingQuantitycost)
                   }
               })
               this.detailsPlanNum.fabriccostIncludestax = (all+Number(this.fabricCost)-allYu).toFixed(2) // 表头面料成本(¥)
-              this.detailsPlanNum.fabriccostIncludestaxUsd = (Number(this.detailsPlanNum.fabriccostIncludestax)/this.detailsPlanNum.exchangeRate).toFixed(2)//表头面料成本($)
+              this.detailsPlanNum.fabriccostIncludestaxUsd = (Number(this.detailsPlanNum.fabriccostIncludestax)/1.13/this.detailsPlanNum.exchangeRate).toFixed(2)//表头面料成本($)
               this.detailsPlanNum.fabriccostNotincludestax = (Number(this.detailsPlanNum.fabriccostIncludestax)/(1+(Number(this.detailsPlanNum.taxrate)/100))).toFixed(2)//表头-面料不含税成本(¥)
               this.$refs.unitTabs.sumInfo.fabricAmount=this.detailsPlanNum.fabriccostIncludestax
                this.$refs.unitTabs.sumInfo.fabricExcludTax =(this.detailsPlanNum.fabriccostNotincludestax!==''&&this.detailsPlanNum.fabriccostNotincludestax)?(Number(this.detailsPlanNum.fabriccostNotincludestax)).toFixed(2):''//合计中的不含税面料总额
@@ -753,8 +758,9 @@ export default {
       rmbAmountAll = 0,
       usdAmountAll = 0,
       priceExcludingtaxAll = 0
-        val.map(item=>{
+      this.$refs.unitTabs.ingData.map(item=>{
           if(item.goodsName!=='合计'){
+            item.usdAmount = ((item.priceExcludingtax?Number(item.priceExcludingtax):0)/this.detailsPlanNum.exchangeRate)
             if(item.rmbAmount !== item.usdAmount){  usdAmountAll+=item.usdAmount?Number(item.usdAmount):0   }
             transferCostAll+=item.transferCostAll?Number(item.transferCost):0
             rmbAmountAll+=item.rmbAmount?Number(item.rmbAmount):0
@@ -813,7 +819,7 @@ export default {
       shuiemoneyAll = 0
      val.map(item=>{
       if(item.setNo!=='合计'){
-      disbursedLocalmoneyALL+=Number(item.disbursedLocalmoney) 
+      disbursedLocalmoneyALL+=item.disbursedLocalmoney?Number(item.disbursedLocalmoney):0
       disbursedOriginalmoneyALL+=Number(item.disbursedOriginalmoney) 
       shuiemoneyAll+=Number(item.shuiemoney) 
       }
@@ -830,9 +836,9 @@ export default {
        this.costPayData.push(obj)
       }
       this.detailsPlanNum.shuiemoney = shuiemoneyAll.toFixed(3)
-      this.detailsPlanNum.rmbNorTaxExpense = obj.disbursedLocalmoney.toFixed(2)
-      this.detailsPlanNum.rmbExpense = obj.iNatMoney.toFixed(2)
-      this.detailsPlanNum.usdExpense = (this.detailsPlanNum.rmbExpense/Number(this.detailsPlanNum.exchangeRate)).toFixed(2)
+      this.detailsPlanNum.rmbNorTaxExpense = Number(obj.disbursedLocalmoney).toFixed(2)
+      this.detailsPlanNum.rmbExpense = Number(obj.iNatMoney).toFixed(2)
+      this.detailsPlanNum.usdExpense = (Number(this.detailsPlanNum.rmbNorTaxExpense)/Number(this.detailsPlanNum.exchangeRate)).toFixed(2)
     },
      // 附件
      openEnclosure(){
@@ -978,7 +984,7 @@ export default {
     },
     FabInQua(data,allYu){
       this.detailsPlanNum.fabriccostIncludestax=(Number(data)+Number(this.fabricCost)-Number(allYu)).toFixed(2)//面料含税成本
-      this.detailsPlanNum.fabriccostIncludestaxUsd = (Number(this.detailsPlanNum.fabriccostIncludestax)/this.detailsPlanNum.exchangeRate).toFixed(2)//表头面料成本($)
+      this.detailsPlanNum.fabriccostIncludestaxUsd = (Number(this.detailsPlanNum.fabriccostIncludestax)/1.13/this.detailsPlanNum.exchangeRate).toFixed(2)//表头面料成本($)
       this.detailsPlanNum.fabriccostNotincludestax = (Number(this.detailsPlanNum.fabriccostIncludestax)/(1+(Number(this.detailsPlanNum.taxrate)/100))).toFixed(2)
       this.$refs.unitTabs.sumInfo.fabricAmount=this.detailsPlanNum.fabriccostIncludestax
       this.$refs.unitTabs.sumInfo.fabricExcludTax =(this.detailsPlanNum.fabriccostNotincludestax!==''&&this.detailsPlanNum.fabriccostNotincludestax)?(Number(this.detailsPlanNum.fabriccostNotincludestax)).toFixed(2):''//合计中的不含税面料总额

+ 1 - 4
src/views/reportForms/cost-allocation-table/tabs.vue

@@ -513,23 +513,20 @@ export default {
           width: '6%',
           dataIndex: 'index',
           key: 'index',
-          fixed: 'left',
           customRender: (text, record, index) => `${index + 1}`,
           className: 'replacecolor'
         },
-        { title: '发票号码', width: '15%', dataIndex: 'invoiceNum', fixed: 'left', className: 'replacecolor' },
+        { title: '发票号码', width: '15%', dataIndex: 'invoiceNum', className: 'replacecolor' },
         {
           title: '出运日期',
           dataIndex: 'outdata',
           width: '8%',
-          fixed: 'left',
           className: 'replacecolor'
         },
         {
           title: '小po',
           width: '7%',
           dataIndex: 'smallPo',
-          fixed: 'left',
           className: 'replacecolor'
         },
         {

+ 14 - 14
src/views/shipment-details/addShipDetDrawer.vue

@@ -791,20 +791,20 @@ export default {
 
      JudgeVluabled(){
           this.judge = 0
-          for (var i=0; i<this.syShippingDetailsItemList.length;i++){
-             var tableRow = this.syShippingDetailsItemList[i];
-             for (var j=i+1;j<this.syShippingDetailsItemList.length; j++){
-              var nextData = this.syShippingDetailsItemList[j];
-              if (tableRow.smallPo == nextData.smallPo && tableRow.orderNumber == nextData.orderNumber  && 
-              tableRow.preDeliveryDate == nextData.preDeliveryDate  && tableRow.preCompletionDate == nextData.preCompletionDate && 
-              tableRow.itemNumber == nextData.itemNumber && tableRow.inventoryCode == nextData.inventoryCode&& 
-              tableRow.colour == nextData.colour&& tableRow.size == nextData.size){
-                this.$message.error('第'+(i+1)+'行和第'+(j+1)+'行数据相同,无法保存');
-                this.judge += 1
-                return;
-              }
-             } 
-           }
+          // for (var i=0; i<this.syShippingDetailsItemList.length;i++){
+          //    var tableRow = this.syShippingDetailsItemList[i];
+          //    for (var j=i+1;j<this.syShippingDetailsItemList.length; j++){
+          //     var nextData = this.syShippingDetailsItemList[j];
+          //     if (tableRow.smallPo == nextData.smallPo && tableRow.orderNumber == nextData.orderNumber  && 
+          //     tableRow.preDeliveryDate == nextData.preDeliveryDate  && tableRow.preCompletionDate == nextData.preCompletionDate && 
+          //     tableRow.itemNumber == nextData.itemNumber && tableRow.inventoryCode == nextData.inventoryCode&& 
+          //     tableRow.colour == nextData.colour&& tableRow.size == nextData.size){
+          //       this.$message.error('第'+(i+1)+'行和第'+(j+1)+'行数据相同,无法保存');
+          //       this.judge += 1
+          //       return;
+          //     }
+          //    } 
+          //  }
            for (var i=0; i<this.syShippingDetailsItemList.length;i++){
              var tableRow = this.syShippingDetailsItemList[i];
             //是否未填

+ 14 - 14
src/views/shipment-details/editShipDetDrawer.vue

@@ -746,20 +746,20 @@ export default {
     },
      JudgeVluabled(){
           this.judge = 0
-          for (var i=0; i<this.syShippingDetailsItemList.length;i++){
-             var tableRow = this.syShippingDetailsItemList[i];
-             for (var j=i+1;j<this.syShippingDetailsItemList.length; j++){
-              var nextData = this.syShippingDetailsItemList[j];
-              if (tableRow.smallPo == nextData.smallPo && tableRow.orderNumber == nextData.orderNumber  && 
-              tableRow.preDeliveryDate == nextData.preDeliveryDate  && tableRow.preCompletionDate == nextData.preCompletionDate && 
-              tableRow.itemNumber == nextData.itemNumber && tableRow.inventoryCode == nextData.inventoryCode&& 
-              tableRow.colour == nextData.colour&& tableRow.size == nextData.size){
-                this.$message.error('第'+(i+1)+'行和第'+(j+1)+'行数据相同,无法保存');
-                this.judge += 1
-                return;
-              }
-             } 
-           }
+          // for (var i=0; i<this.syShippingDetailsItemList.length;i++){
+          //    var tableRow = this.syShippingDetailsItemList[i];
+          //    for (var j=i+1;j<this.syShippingDetailsItemList.length; j++){
+          //     var nextData = this.syShippingDetailsItemList[j];
+          //     if (tableRow.smallPo == nextData.smallPo && tableRow.orderNumber == nextData.orderNumber  && 
+          //     tableRow.preDeliveryDate == nextData.preDeliveryDate  && tableRow.preCompletionDate == nextData.preCompletionDate && 
+          //     tableRow.itemNumber == nextData.itemNumber && tableRow.inventoryCode == nextData.inventoryCode&& 
+          //     tableRow.colour == nextData.colour&& tableRow.size == nextData.size){
+          //       this.$message.error('第'+(i+1)+'行和第'+(j+1)+'行数据相同,无法保存');
+          //       this.judge += 1
+          //       return;
+          //     }
+          //    } 
+          //  }
            for (var i=0; i<this.syShippingDetailsItemList.length;i++){
              var tableRow = this.syShippingDetailsItemList[i];
             //是否未填

+ 2 - 2
src/views/shipment-details/shipmentList.vue

@@ -595,7 +595,7 @@ export default {
                               return (
                                 <span>否</span>
                               ) 
-                            }else{
+                            }else if(text=='1'){
                               return (
                                 <span>是</span>
                               );
@@ -799,7 +799,7 @@ export default {
             this.$refs.declareElementsModal.declareElements.hsCode  = record.hsCode
             this.$refs.declareElementsModal.flourOrGarment = this.queryParam.flourOrGarment
             this.$refs.declareElementsModal.orderNumber = record.orderNumber
-            this.$refs.declareElementsModal.declareElements.declarationUnit = record.declarationUnit
+            this.$refs.declareElementsModal.declareElements.declarationUnit = record.declarationUnit?record.declarationUnit:res.result.declarationUnit
             this.$refs.declareElementsModal.record = record
             if(!res.result.hsCode  || res.result.hsCode == ''){
              this.$refs.declareElementsModal.query = '0'