Browse Source

Merge branch 'master' of git.echepei.com:zhujiawei/Warehouse_management_ui

caojunjie 4 years ago
parent
commit
246773b7ed

+ 10 - 2
src/views/warehouseBusiness/inStock/index.vue

@@ -371,6 +371,7 @@
       :close-on-click-modal="false"
       @close='addCloseDialog'
       :show-close="closeButton"
+      :before-close="handleClose"
       width="80%"
       append-to-body
     >
@@ -3305,12 +3306,17 @@ export default {
     this.getDicts("data_customer_category").then(response => {
       this.fCompanyOptIons = response.data;
     });
-
+    this.getDicts("data_customer_category").then(response => {
+      this.fleetOptions = response.data;
+    });
   },
   activated() {
     this.adoPt()
   },
   methods: {
+    handleClose(){
+      this.cancel()
+    },
     handleSelect(key, keyPath) {
       this.addAgreements(key)
     },
@@ -4260,8 +4266,10 @@ export default {
       this.formBrowseStatus = false;
       const fId = row.fId || this.ids;
       this.dataList = [];
+      console.log(fId)
       this.goodsRemoteMethod()
       getWarehousebills(fId).then((response) => {
+        console.log(response)
         if (response.data.warehousebills) {
           this.form = response.data.warehousebills;
           this.before = this.form.createBy
@@ -4762,7 +4770,7 @@ export default {
           this.form.fNetweight = this.fNetweight
           this.form.fPlanvolumn = this.fPlanvolumn
           this.form.fGrossweight = this.fGrossweight
-          // this.form.fQty = this.fQty
+          this.form.fQty = this.fQty
           // if (!this.form.fId) {
           //   this.form.fId = this.fid
           // }

+ 34 - 8
src/views/warehouseBusiness/outStock/index.vue

@@ -355,6 +355,7 @@
       @close='addCloseDialog'
       width="80%"
       append-to-body
+
     >
       <el-form ref="form" :model="form" :rules="rules" label-width="120px">
         <el-row>
@@ -617,7 +618,7 @@
                 placeholder="请输入劳务公司"
               >
                 <el-option
-                  v-for="(dict, index) in flabourOptions"
+                  v-for="(dict, index) in fCompanyOptIons"
                   :key="index.fId"
                   :label="dict.fName"
                   :value="dict.fId"
@@ -2727,7 +2728,8 @@ export default {
   },
   data() {
     return {
-      flabourOptions:[],
+      // 劳务公司
+      fCompanyOptIons: [],
       fleetOptions:[],
       activeIndex: '1',
       activeIndex2: '1',
@@ -3011,8 +3013,11 @@ export default {
     this.getDicts("st_out_type").then((response) => {
       this.businessTypeOption = response.data;
     });
-    this.getDicts("data_stltype_type").then(response => {
-      this.fStltypeidOptions = response.data;
+    this.getDicts("data_customer_category").then(response => {
+      this.fCompanyOptIons = response.data;
+    });
+    this.getDicts("data_customer_category").then(response => {
+      this.fleetOptions = response.data;
     });
   },
   activated() {
@@ -3103,7 +3108,7 @@ export default {
           if (response.data.corps) {
             this.fMblnoOptions = response.data.corps;
             this.KHblnoOptions = response.data.corps;
-            this.fSbuOptions = response.data.corps;
+            this.fCompanyOptIons = response.data.corps;
           }
           if (response.data.feesList) {
             this.fWbuOptions = response.data.feesList;
@@ -3722,6 +3727,15 @@ export default {
     },
     /** 查询仓库主(出入库)列表 */
     getList() {
+      let queryParams = { pageNum: 1, pageSize: 10, fTypeid: 6}
+      listCorps(queryParams).then((response) => {
+        this.fCompanyOptIons = response.rows;
+      });
+      let params = { pageNum: 1, pageSize: 10, fTypeid: 2}
+      listCorps(params).then((response) => {
+        console.log(response)
+        this.fleetOptions = response.rows;
+      });
       this.loading = true;
       listWarehousebills(this.queryParams).then((response) => {
         this.warehousebillsList = response.rows;
@@ -3900,8 +3914,13 @@ export default {
       this.contrOl = status
       this.detailsHidden = false;
       this.formBrowseStatus = false;
-      const fId = row.fId || this.ids;
+      let fId = row.fId || this.ids;
       this.dataList = [];
+      this.goodsRemoteMethod()
+      console.log(fId)
+      if (fId.length === 1){
+        fId = fId[0].fId
+      }
       getWarehousebills(fId).then((response) => {
         if (response.data.warehousebills) {
           this.form = response.data.warehousebills;
@@ -3934,7 +3953,7 @@ export default {
           this.fMblnoOptions = response.data.corps;
           this.KHblnoOptions = response.data.corps;
           this.fleetOptions = response.data.corps;
-          this.fSbuOptions = response.data.corps;
+          this.fCompanyOptIons = response.rows;
         }
         if (response.data.feesList) {
           this.fWbuOptions = response.data.feesList;
@@ -4680,7 +4699,7 @@ export default {
       }
       let queryParams = { pageNum: 1, pageSize: 10, fName: name, fTypeid: 6 };
       listCorps(queryParams).then((response) => {
-        this.flabourOptions = response.rows;
+        this.fCompanyOptIons = response.rows;
       });
     },
     /* 远程模糊查询车队 */
@@ -4743,6 +4762,13 @@ export default {
         this.warehouseOptions = response.rows;
       });
     },
+    /* 弹窗获取所有商品信息 */
+    goodsRemoteMethod() {
+      let queryParams = { pageNum: 1, pageSize: 10, fStatus: 0, delFlag: 0 };
+      listGoods(queryParams).then((response) => {
+        this.goodsOptions = response.rows;
+      });
+    },
     /* 获取所有仓库信息 */
     warehousesssMethod() {
       let queryParams = { pageNum: 1, pageSize: 10, fStatus: 0, delFlag: 0 };

+ 18 - 14
src/views/warehouseBusiness/stockTransfer/index.vue

@@ -638,13 +638,13 @@
               <el-select
                 style="width: 80%"
                 v-model="form.fLabour"
-                @keyup.enter.native="handleQuery"
                 :remote-method="flabourRemoteMethod"
+                filterable
+                remote
                 :disabled="contrOl"
-                placeholder="请输入劳务公司"
-              >
+                placeholder="请输入劳务公司">
                 <el-option
-                  v-for="(dict, index) in flabourOptions"
+                  v-for="(dict, index) in fCompanyOptIons"
                   :key="index.fId"
                   :label="dict.fName"
                   :value="dict.fId"
@@ -663,11 +663,11 @@
               <el-select
                 style="width: 80%"
                 v-model="form.fFleet"
-                @keyup.enter.native="handleQuery"
+                filterable
+                remote
                 :remote-method="fleetRemoteMethod"
                 :disabled="contrOl"
-                placeholder="请输入车队"
-              >
+                placeholder="请输入车队">
                 <el-option
                   v-for="(dict, index) in fleetOptions"
                   :key="index.fId"
@@ -952,7 +952,8 @@
                 >
                 </el-input>
               </template>
-            </el-table-column>            <el-table-column
+            </el-table-column>
+            <el-table-column
               prop="fPlanqty"
               header-align="center"
               align="center"
@@ -2378,7 +2379,7 @@ export default {
   },
   data() {
     return {
-      flabourOptions:[],
+      fCompanyOptIons:[],
       fleetOptions:[],
       activeIndex: '1',
       activeIndex2: '1',
@@ -2658,8 +2659,11 @@ export default {
     this.getDicts("st_trans_type").then((response) => {
       this.businessTypeOption = response.data;
     });
-    this.getDicts("data_stltype_type").then(response => {
-      this.fStltypeidOptions = response.data;
+    this.getDicts("data_customer_category").then(response => {
+      this.fCompanyOptIons = response.data;
+    });
+    this.getDicts("data_customer_category").then(response => {
+      this.fleetOptions = response.data;
     });
     this.register()
   },
@@ -2763,7 +2767,7 @@ export default {
           if (response.data.corps) {
             this.fMblnoOptions = response.data.corps;
             this.KHblnoOptions = response.data.corps;
-            this.fSbuOptions = response.data.corps;
+            this.fCompanyOptIons = response.data.corps;
           }
           if (response.data.feesList) {
             this.fWbuOptions = response.data.feesList;
@@ -3675,8 +3679,8 @@ export default {
           this.flabourOptions = response.data.corps;
           this.fMblnoOptions = response.data.corps;
           this.KHblnoOptions = response.data.corps;
+          this.fCompanyOptIons = response.data.corps;
           this.fleetOptions = response.data.corps;
-          this.fSbuOptions = response.data.corps;
         }
         if (response.data.feesList) {
           this.fWbuOptions = response.data.feesList;
@@ -4378,7 +4382,7 @@ export default {
       }
       let queryParams = { pageNum: 1, pageSize: 10, fName: name, fTypeid: 6};
       listCorps(queryParams).then((response) => {
-        this.flabourOptions = response.rows;
+        this.fCompanyOptIons = response.rows;
       });
     },
     /* 远程模糊查询车队 */