Преглед на файлове

发运明细 订单接口更改

liangy преди 2 години
родител
ревизия
0928ce9103
променени са 2 файла, в които са добавени 15 реда и са изтрити 43 реда
  1. 1 1
      src/api/document/shipmentList.js
  2. 14 42
      src/views/shipment-details/referOrderDataModal.vue

+ 1 - 1
src/api/document/shipmentList.js

@@ -45,7 +45,7 @@ const addItemNumEle = params => postAction('/shippingDetails/syShippingDetails/u
 
 // 参照订单数据  确定
 
-const confimOrderData = params => getAction('/shippingDetails/syShippingDetails/displayDetails', params)
+const confimOrderData = params => postAction('/shippingDetails/syShippingDetails/displayDetails', params)
 
 export {
   shipmentList,

+ 14 - 42
src/views/shipment-details/referOrderDataModal.vue

@@ -111,15 +111,6 @@ export default {
           width: 80,
           className: 'replacecolor'
         },
-        //         {
-        //   title: '创建时间',
-        //   dataIndex: 'createTime',
-        //   align: 'center',
-        //   sorter: true,
-        //   customRender: text => {
-        //     return moment(text).format('YYYY-MM-DD')
-        //   }
-        // },
         {
           title: '订单日期',
           dataIndex: 'orderDate',
@@ -182,13 +173,6 @@ export default {
           width: 120,
           className: 'replacecolor'
         },
-
-        // {
-        //         title: '含税单价',
-        //         dataIndex: 'unitPriceIncludingTax',
-        //         width: 100,
-        //         className: 'replacecolor'
-        //       },
         {
           title: '含税单价',
           dataIndex: 'unitPriceIncludingTax',
@@ -217,7 +201,8 @@ export default {
         {
           title: '客户简称',
           dataIndex: 'customerAbbreviation',
-          width: 120,
+          width: 220,
+          align: 'left',
           className: 'replacecolor'
         },
         {
@@ -273,7 +258,8 @@ export default {
         {
           title: '第三方',
           dataIndex: 'thirdParty',
-          width: 120,
+          width: 220,
+          align: 'left',
           className: 'replacecolor'
         },
         {
@@ -294,7 +280,6 @@ export default {
           width: 100,
           className: 'replacecolor'
         },
-
         {
           title: '付款条件',
           dataIndex: 'termOfPayment',
@@ -315,7 +300,6 @@ export default {
           customRender: t => ellipsis(t),
           className: 'replacecolor'
         },
-
         {
           title: '价格备注',
           dataIndex: 'priceRemarks',
@@ -334,21 +318,14 @@ export default {
           title: '订单主表ID',
           dataIndex: 'syOrderDataId',
           width: 120,
-          //  colSpan:0,     //隐藏表头
-          //     customRender: (value, row, index) => {
-          //         let obj = {
-          //             children: value,
-          //             attrs: {},
-          //         };
-          //         obj.attrs.colSpan = 0;
-          //         return obj;
-          //     },
+          fixed: 'right',
           className: 'replacecolor1'
         },
         {
           title: '订单子表ID',
           dataIndex: 'syOrderDataItemId',
-          width: 220,
+          width: 320,
+          fixed: 'right',
           className: 'replacecolor'
         }
       ],
@@ -364,11 +341,8 @@ export default {
         // pageSize: '-1' // 每页显示条数
       },
       // 分页
-      pagination: {
-        // total: 0,
-        // current: 0,
-        // pageSize: 0
-      }
+      pagination: {},
+      confimList: []
     }
   },
   // 接收父组件 方法
@@ -383,10 +357,7 @@ export default {
       this.$nextTick(() => {
         queryOrderData(this.queryParam).then(res => {
           if (res.success) {
-            console.log('00')
             this.orderListData = res.result.records
-            console.log('数据', this.orderListData)
-            console.log('out', this.orderListData.syOrderDataItemId)
             this.pagination = {
               total: res.result.total,
               current: res.result.current,
@@ -403,12 +374,13 @@ export default {
         this.$message.error('请勾选订单数据')
       } else {
         console.log('勾选', this.selectedRows)
-        var confimList = []
+
         this.selectedRows.forEach(item => {
-          confimList.push(item.syOrderDataItemId)
+          this.confimList.push(item.syOrderDataItemId)
         })
-        console.log('confimList', confimList)
-        confimOrderData({ itemId: confimList }).then(res => {
+        // itemId:"1232,1231,123,123,123,13,123" 这种
+        console.log('勾选的id数组', this.confimList)
+        confimOrderData({ "itemId": this.confimList }).then(res => {
           if (res.success) {
             console.log('结果', res.result)
             // this.orderListData = res.result.records