浏览代码

修改bug

QuKatie 3 年之前
父节点
当前提交
dd296397ba

+ 2 - 1
src/api/finance/applyForInvoice/chargeInvoice.js

@@ -154,10 +154,11 @@ export function revocation(data) {
   })
 }
 // 提货 EDI
-export function pickUpEDI() {
+export function pickUpEDI(data) {
   return request({
     url: '/khwarehouse/warehousebills/pickUpEDI',
     method: 'post',
+    data: data
   })
 }
 // 导出计算明细从表

+ 8 - 0
src/api/kaihe/domesticTrade/myOrder.js

@@ -147,4 +147,12 @@ export function detention(data) {
     data: data
   })
 }
+//扣货
+export function receipt(data) {
+  return request({
+    url: '/khwarehouse/warehousebills/receipt',
+    method: 'post',
+    data: data
+  })
+}
 

+ 2 - 2
src/views/Warehousing/inStock/AddOrUpdate.vue

@@ -2028,9 +2028,9 @@
             <tr>
               <td>收费</td>
               <td colspan="3">
-                <span v-for="(item, index) in Collectionoptionss" :key="index">
+                <span v-for="(item, index) in warehouseDrList" :key="index">
                   {{ item.fFeeid | fFeetFormat(fDNameOptions) }}:{{ item.fAmount }} 元<b
-                  v-if="index + 1 != Collectionoptionss.length"
+                  v-if="index + 1 != warehouseDrList.length"
                 >,</b>
                 </span>
               </td>

+ 72 - 17
src/views/kaihe/domesticTrade/myOrder/index.vue

@@ -351,9 +351,22 @@
           v-hasPermi="['warehouse:warehousebills:zhc']"
           >转航次</el-button
         >
-        <el-button type="warning" size="mini" @click="pickUpEDI">
+        <el-button
+          type="warning"
+          size="mini"
+          @click="pickUpEDI"
+          :disabled="selection.length != 1"
+        >
           提货EDI
         </el-button>
+        <el-button
+          type="info"
+          size="mini"
+          @click="device"
+          :disabled="selection.length == 0"
+        >
+          设备单
+        </el-button>
       </div>
       <div class="tabSetting">
         <right-toolbar
@@ -485,6 +498,12 @@
           <span v-else-if="item.label == 'fArrivalStatus'">{{
             scope.row.fArrivalStatus | transshipName
           }}</span>
+          <span v-else-if="item.label == 'pickUpTime'">{{
+            scope.row.pickUpTime | dateFormat
+          }}</span>
+          <span v-else-if="item.label == 'facilityTime'">{{
+            scope.row.facilityTime | dateFormat
+          }}</span>
           <span v-else>{{ scope.row[item.label] }}</span>
         </template>
       </el-table-column>
@@ -694,7 +713,9 @@ import {
   confirmAllocation,
   exportItem,
   detention,
+  receipt,
 } from "@/api/kaihe/domesticTrade/myOrder";
+import { dateFormat } from "@/utils/date";
 import Cookies from "js-cookie";
 import { addSet, resetModule, select } from "@/api/system/set";
 import Vue from "vue";
@@ -989,20 +1010,34 @@ export default {
           checked: 0,
           width: 120,
         },
-        // {
-        //   surface: "30",
-        //   label: "fShipThreeName",
-        //   name: "三程船名",
-        //   checked: 0,
-        //   width: 120,
-        // },
-        // {
-        //   surface: "31",
-        //   label: "fVoyThreeName",
-        //   name: "三程航次",
-        //   checked: 0,
-        //   width: 120,
-        // },
+        {
+          surface: "30",
+          label: "pickUpPerson",
+          name: "提货单发送人",
+          checked: 0,
+          width: 120,
+        },
+        {
+          surface: "31",
+          label: "pickUpTime",
+          name: "提货单发送时间",
+          checked: 0,
+          width: 120,
+        },
+        {
+          surface: "32",
+          label: "facilityPerson",
+          name: "设备单发送人",
+          checked: 0,
+          width: 120,
+        },
+        {
+          surface: "33",
+          label: "facilityTime",
+          name: "设备单发送时间",
+          checked: 0,
+          width: 120,
+        },
         {
           surface: "32",
           label: "remark",
@@ -1102,6 +1137,11 @@ export default {
         return "-";
       }
     },
+    dateFormat(date) {
+      if (date) {
+        return dateFormat(new Date(date), "yyyy-MM-dd");
+      }
+    },
   },
   methods: {
     voyageRemthods() {
@@ -1187,8 +1227,13 @@ export default {
       this.transvoyageVisible = Bool;
     },
     pickUpEDI() {
-      pickUpEDI().then((res) => {
-        console.log(res);
+      let id;
+      this.selection.forEach((e) => {
+        id = e.fId;
+      });
+      pickUpEDI({ fId: id }).then((res) => {
+        this.$message.success("提货EDI成功");
+        this.getList();
       });
     },
     transshipClosed() {
@@ -1442,6 +1487,16 @@ export default {
         });
       }
     },
+    device() {
+      let ids = [];
+      this.selection.forEach((e) => {
+        ids.push(e.fId);
+      });
+      receipt({ orderList: ids }).then((res) => {
+        this.$message.success("提交成功");
+        this.getList();
+      });
+    },
     /** 取消配船按钮操作 */
     cancelShip() {
       let data = [];