Forráskód Böngészése

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

huxy 2 éve
szülő
commit
494be97cfe

+ 4 - 1
src/api/document/inancialReconciliation.js

@@ -8,5 +8,8 @@ const checkList = params => getAction('/orderData/syCostLossReview/list', params
 // 保存
 const savaList = params => postAction('/syPlanStatistics/syPlanStatistics/add', params)
 
+// 保存
+const savaList1 = params => postAction('/report/FabricLoss/setFinalDate', params)
+
 
-export { checkList,savaList}
+export { checkList,savaList,savaList1}

+ 26 - 10
src/views/cost-allocation-total/inancialReconciliation.vue

@@ -116,7 +116,7 @@
         <span slot="ffinalApproveDate" slot-scope="text, record">
           <a-date-picker style="width: 100%" v-model="record.ffinalApproveDate"   :format="dateFormat" v-if="record.enter=='1'"> </a-date-picker>
             <!-- <a-input placeholder="请输入" v-model="record.ffinalApproveDate" v-if="record.enter=='1'"></a-input> -->
-            <span v-if="record.enter=='0'">{{ text!==''&&text?moment(text).format('YYYY-MM-DD'):'' }}</span>
+            <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>
@@ -140,7 +140,7 @@ import moment from 'moment'
 
 import costDetailDrawer from '@views/cost-allocation-total/costDetailDrawer.vue'
 
-import { checkList,savaList } from '@api/document/inancialReconciliation.js'
+import { checkList,savaList,savaList1 } from '@api/document/inancialReconciliation.js'
 
 export default {
   name: 'inancialReconciliation', // 成本分配汇总 单证
@@ -211,16 +211,17 @@ export default {
         },
         {
           title: '核纱结束日期',
-          width: 120,
+          width: 150,
           dataIndex: 'ffinalApproveDate',
-          customRender: text => {
-            if(text!==''&&text){
-              return moment(text).format('YYYY-MM-DD')
-            }else{
-              return ''
-            }
+          scopedSlots: { customRender: 'ffinalApproveDate' },
+          // customRender: text => {
+          //   if(text!==''&&text){
+          //     return moment(text).format('YYYY-MM-DD')
+          //   }else{
+          //     return ''
+          //   }
             
-          },
+          // },
           className: 'replacecolor'
         },
         { title: '面损表单据状态', width: 90, dataIndex: 'fstatus', className: 'replacecolor' },
@@ -314,6 +315,7 @@ export default {
             this.costAllocationData = res.result.records
             this.costAllocationData.map(item=>{
               item.enter = '0'
+              item.ffinalApproveDate = item.ffinalApproveDate!==''&&item.ffinalApproveDate ? moment(item.ffinalApproveDate).format('YYYY-MM-DD'):''
             })
             this.pagination = {
               total: res.result.total,
@@ -343,6 +345,7 @@ export default {
     searchReset() {
       this.queryParam.pageNo = ''
       this.queryParam = {}
+      this.defaultData()
       this.getCostList()
     },
     rowClick(record)  {
@@ -369,6 +372,10 @@ export default {
         remarks:record.remarks,
         id:record.id
       }
+      var newObj ={
+          ccode:record.planNo,
+          final_date: record.ffinalApproveDate!==''&&record.ffinalApproveDate ? moment(record.ffinalApproveDate).format('YYYY-MM-DD HH:mm:ss'):''
+        }
       savaList(obj).then(res => {
           this.loading = false
           if (res.success) {
@@ -378,6 +385,15 @@ export default {
             this.$message.error(res.message);
           }
         })
+        savaList1(newObj).then(res => {
+          this.loading = false
+          if (res.success) {
+            this.$message.success('保存成功')
+            this.getCostList()
+          }else{
+            this.$message.error(res.message);
+          }
+        })
     },
 
     handleTableChange(pagination, filters, sorter) {

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

@@ -409,17 +409,24 @@ export default {
             v = 0,
             d = 0,
             b = 0,
-            f=0
+            f=0,
+            e=0
             oneData.syCostAllocationShipdetail.map(item=>{
               s+=Number(item.exportPrice)
               v+=Number(item.shipQuantity)
               d+=Number(item.processCost)
               b+=Number(item.exportPrice)
+              if(item.exchangeRate=='6.888' && item.outdata!=='合计'){
+                 e+=Number(item.processCost)
+              }else if(item.outdata!=='合计'){
+                e+=(Number(item.processCost)/1.13).toFixed(2)
+              }
             })
             this.$refs.unitTabs.sumInfo.exportPriceUSD = (s/2).toFixed(2)//出运美元外销总价
             this.$refs.unitTabs.sumInfo.shipQua =(v/2).toFixed(0)//出货数量合计
             this.$refs.unitTabs.sumInfo.shipProcesFees =(d/2).toFixed(2)//出运加工费
             this.$refs.unitTabs.sumInfo.exportedAmountRMB =(b/2).toFixed(2)//出运人民币外销金额 f
+            this.$refs.unitTabs.sumInfo.excludingTaxProcessing =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)//合计金额
             this.pagination = {

+ 6 - 0
src/views/reportForms/cost-allocation-table/tabs.vue

@@ -154,6 +154,12 @@
                       <span v-show='showSelect==1'>{{sumInfo.ingExcludAmount}}</span>
                     </a-form-item>
                   </a-col>
+                  <a-col :md="6" :sm="8">
+                    <a-form-item label="出运不含税加工费金额" >
+                      <a-input v-model="sumInfo.excludingTaxProcessing" v-show='showSelect==0'></a-input>
+                      <span v-show='showSelect==1'>{{sumInfo.excludingTaxProcessing}}</span>
+                    </a-form-item>
+                  </a-col>
                 </a-form>
               </div>
             </a-row>

+ 1 - 1
src/views/reportForms/supplier-capacity.vue

@@ -207,7 +207,7 @@ export default {
           scopedSlots: { customRender: 'capacityQuota' },
         },
         {
-          title: '工时(/月)',
+          title: '工时(/月)',
           dataIndex: 'workingHours',
           width: 100,
           className: 'replacecolor',

+ 28 - 25
src/views/reportForms/supply-capacity-table.vue

@@ -148,45 +148,38 @@ export default {
           width: 60,
           align: 'left',
           dataIndex: 'account',
+          ellipsis: true,
           className: 'replacecolor'
         },
         {
           title: '订单号',
-          width: 150,
+          width: 95,
           align: 'left',
           dataIndex: 'csrccode',
           className: 'replacecolor',
-          ellipsis: true,
-        },
-
-        {
-          title: '计划单号',
-          width: 80,
-          dataIndex: 'cplanLotNumber',
-          className: 'replacecolor',
-          ellipsis: true,
         },
         {
           title: '款号',
           width:80,
           dataIndex: 'itemNumber',
-          className: 'replacecolor'
+          className: 'replacecolor',
         },
-        { title: '部门', width: 80, dataIndex: 'cdepCode', className: 'replacecolor' },
-        { title: '业务员', width: 80, dataIndex: 'cpersonCode', className: 'replacecolor' },
-        { title: '供应商', width: 250, dataIndex: 'cvenCode', className: 'replacecolor'},
+        { title: '部门', width: 70, dataIndex: 'cdepCode', className: 'replacecolor',ellipsis: true, },
+        { title: '业务员', width: 60, dataIndex: 'cpersonCode', className: 'replacecolor',ellipsis: true, },
+        { title: '供应商', width: 80, dataIndex: 'cvenCode', className: 'replacecolor',ellipsis: true,},
 
-        { title: '供应商类型', width: 80, dataIndex: 'cvenCodeType', className: 'replacecolor' },
-        { title: '订单类型', width: 80, dataIndex: 'iorderType', className: 'replacecolor' },
+        { title: '供应商类型', width: 65, dataIndex: 'cvenCodeType', className: 'replacecolor',ellipsis: true, },
+        { title: '订单类型', width: 70, dataIndex: 'iorderType', className: 'replacecolor',ellipsis: true, },
        
         {
           title: '预发货日期',
-          width: 95,
+          width: 65,
           dataIndex: 'darriveDate',
           // customRender: text => {
           //   return moment(text).format('YYYY-MM')
           // },
-          className: 'replacecolor'
+          className: 'replacecolor',
+          ellipsis: true,
         },
         // {
         //   title: '计划到货日期',
@@ -199,21 +192,31 @@ export default {
         // },
         //   className: 'replacecolor'
         // },
-        { title: '工时(分)', width: 80, dataIndex: 'coefficient', className: 'replacecolor' },
         {
           title: '件数',
-          width: 70,
+          width: 50,
           dataIndex: 'total',
-          className: 'replacecolor'
+          className: 'replacecolor',
+          ellipsis: true,
+        },
+        { title: '工时(分)', width: 55, dataIndex: 'coefficient', className: 'replacecolor',ellipsis: true, },
+       
+        {
+          title: '计划单号',
+          width: 80,
+          dataIndex: 'cplanLotNumber',
+          className: 'replacecolor',
+          ellipsis: true,
         },
         {
           title: '数量',
-          width: 70,
+          width: 50,
           dataIndex: 'iquantity',
-          className: 'replacecolor'
+          className: 'replacecolor',
+          ellipsis: true,
         },
-        { title: '累计入库数量', width: 85, dataIndex: 'ireceivedQTY', className: 'replacecolor' },
-        { title: '单位', width: 70, dataIndex: 'unit', className: 'replacecolor' },
+        { title: '累计入库数量', width: 85, dataIndex: 'ireceivedQTY', className: 'replacecolor',ellipsis: true, },
+        { title: '单位', width: 70, dataIndex: 'unit', className: 'replacecolor',ellipsis: true, },
       ],
       supplyCapacityData: [],
       loading: false, // 表格加载