caojunjie 1 سال پیش
والد
کامیت
18c26ce808

+ 3 - 0
src/components/report-dialog/main.vue

@@ -134,6 +134,9 @@ export default {
       if (this.query.name == '出库工单(L)') {
           this.$set(this.query,'name','轮胎商城-出库工单')
       }
+      if (this.query.name == '调拨(L)') {
+          this.$set(this.query,'name','轮胎商城-调拨单')
+      }
 
       getList(
         this.page.currentPage,

+ 6 - 0
src/page/index/tags.vue

@@ -319,6 +319,12 @@ export default {
         if(tag.label == "采购入库"){
           this.$store.commit("DOMIO_OUT_DETAIL");
         }
+        if(tag.label == "采购入库(L)"){
+          this.$store.commit("DOMIO_OUT_DETAIL");
+        }
+        if(tag.label == "调拨(L)"){
+              this.$store.commit("DOMIO_OUT_ALLOCATW");
+        }
         if (tag.label == "代理订单(N)") {
           this.$store.commit("DOMXS_OUT_DETAIL");
         }

+ 1 - 0
src/store/getters.js

@@ -42,6 +42,7 @@ const getters = {
   xiaoShoZhengce:state => state.ifdetail.xiaoshozhengce,// 销售政策 审批数据里加的
   inventoryAccount:state => state.ifdetail.inventoryAccount,
   inboundAndOutbound:state => state.ifdetail.inboundAndOutbound,
+  Allocateandtransfer:state => state.ifdetail.Allocateandtransfer, // 调拨L
   domStockDetail: state => state.ifdetail.domStockDetail,
   domPurStatus: state => state.ifdetail.domPurStatus,
   purchaseStatus: state => state.ifdetail.purchaseStatus,

+ 9 - 0
src/store/modules/ifdetail.js

@@ -41,6 +41,7 @@ const ifdetail = {
     // 销售政策
     xiaoshozhengce:false,
     approvalDetails:false, // 海运出口 审批详情
+    Allocateandtransfer:false, // 调拨L
   },
   actions: {},
   mutations: {
@@ -254,6 +255,14 @@ const ifdetail = {
     DOMIO_OUT_DETAIL(state) {
       state.inboundAndOutbound = false;
     },
+    //打开调拨L明细
+    DOMIO_IN_ALLOCATW(state) {
+      state.Allocateandtransfer = true;
+    },
+    //关闭调拨L明细
+    DOMIO_OUT_ALLOCATW(state) {
+      state.Allocateandtransfer = false;
+    },
     DOMKC_IN_DETAIL(state) {
       state.domStockDetail = true;
     },

+ 2 - 0
src/views/tirePartsMall/basicData/listingManagement/commodity.json

@@ -19,6 +19,8 @@
     "border": true,
     "index": true,
     "selection": true,
+  "rowKey": "id",
+
     "dialogClickModal": false,
     "column": [
         {

+ 18 - 5
src/views/tirePartsMall/basicData/listingManagement/index.vue

@@ -74,7 +74,8 @@
         <el-col :span="19">
           <!-- <basic-container> -->
             <avue-crud :option="optionTwo" :table-loading="loading" :data="goodsListShow" ref="cruds"
-              @refresh-change="refreshChangeCost" @selection-change="selectionChangeCost" @search-change="goodsSearchCost"
+                       :reserve-selection="true"
+                       @refresh-change="refreshChangeCost" @selection-change="selectionChangeCost" @search-change="goodsSearchCost"
               :page.sync="pages" @on-load="onLoad"  @saveColumn="saveGoodsColumn"
               @resetColumn="resetGoodsColumn">
               <template slot="menuLeft">
@@ -85,10 +86,10 @@
               </template>
               <template slot="priceOne" slot-scope="{row}">
                 <el-input v-model="row.priceOne" size="small" :controls="false" :precision="0"
-                  style="width: 100%" />
+                  style="width: 100%" @change="selectChangefun($event,row)" @focus="selectFocusfun(row)"  />
               </template>
               <template slot="priceTwo" slot-scope="{ row }">
-                <el-input v-model="row.priceTwo" size="small"></el-input>
+                <el-input v-model="row.priceTwo" size="small" @change="selectChangefun($event,row)"></el-input>
                 <!-- <span v-else>{{ row.refreshChange | IntegerFormat }}</span> -->
               </template>
                 <!--花纹-->
@@ -111,11 +112,11 @@
                     <!--</el-select>-->
                 </template>
               <template slot="priceThree" slot-scope="{ row }">
-                <el-input v-model="row.priceThree" size="small"></el-input>
+                <el-input v-model="row.priceThree" size="small" @change="selectChangefun($event,row)"></el-input>
                 <!-- <span v-else>{{ row.refreshChange | IntegerFormat }}</span> -->
               </template>
               <template slot="priceFour" slot-scope="{ row }">
-                <el-input v-model="row.priceFour" size="small"></el-input>
+                <el-input v-model="row.priceFour" size="small" @change="selectChangefun($event,row)"></el-input>
                 <!-- <span v-else>{{ row.refreshChange | IntegerFormat }}</span> -->
               </template>
               <template slot="sharedCompany" slot-scope="{ row, index }">
@@ -499,6 +500,18 @@ export default {
     }
   },
   methods: {
+      selectFocusfun(row){
+          console.log(row,503)
+          console.log(this.$refs.cruds,504)
+      },
+      selectChangefun(value,row) {
+          console.log(value,506)
+          if (value && Number(value) > 0) {
+              this.$refs.cruds.toggleRowSelection(row,true);
+          }else {
+              this.$refs.cruds.toggleRowSelection(row,false);
+          }
+      },
       //打开附件
       annexOpen(row, index) {
           this.dataId = index

+ 18 - 0
src/views/tirePartsMall/inventory/detail.vue

@@ -168,6 +168,24 @@ export default {
                     orderId: row.id
                 },
             });
+        } else if (row.bizTypeName == '调出') {
+            if (this.$store.getters.Allocateandtransfer) {
+                this.$alert("调拨明细已存在,请保存关闭明细账再进行操作", "温馨提示", {
+                    confirmButtonText: "确定",
+                    type: "warning",
+                    callback: action => {
+                        console.log(action);
+                    }
+                });
+            }else {
+                this.$router.$avueRouter.closeTag("/tirePartsMall/salesManagement/outboundWorkOrderL/index");
+                this.$router.push({
+                    path: "/tirePartsMall/salesManagement/outboundWorkOrderL/index",
+                    query: {
+                        id: row.id
+                    },
+                });
+            }
         } else {
           this.$router.$avueRouter.closeTag("/tirePartsMall/purchasingManagement/warehouseEntryOrder/index");
           this.$router.push({

+ 7 - 1
src/views/tirePartsMall/inventory/index.vue

@@ -146,8 +146,14 @@ export default {
             width: 100
           }, {
             label: '分类',
-            prop: "goodsTypeName",
+            prop: "goodsTypeId",
             overHidden: true,
+                props: {
+                    label: 'title',
+                    value: 'value',
+                    children:'children'
+                },
+                dicUrl: '/api/blade-sales-part/goodsType/tree?corpType=SP',
             width: 100
           }, {
             label: '仓库',

+ 17 - 3
src/views/tirePartsMall/salesManagement/outboundWorkOrderL/detailsPage.vue

@@ -365,13 +365,13 @@ export default {
         this.editButton = false
         this.isSave = false
     }
-    this.$store.commit("DOMIO_IN_DETAIL");
+    this.$store.commit("DOMIO_IN_ALLOCATW");
   },
   activated(){
     if (this.detailData.id) {
       this.refresh()
     }
-    this.$store.commit("DOMIO_IN_DETAIL");
+    this.$store.commit("DOMIO_IN_ALLOCATW");
   },
   methods: {
     // 撤销调拨
@@ -484,9 +484,21 @@ export default {
             background: 'rgba(255,255,255,0.7)'
           });
           console.log(this.form)
-          this.form.shipItemsList.forEach(item => {
+            let i = 0
+          this.form.shipItemsList.forEach((item,index) => {
+              if (item.whether == 1) {
+                  if (!item.dot) {
+                      this.$message.warning(`序号${index + 1}请填写批次号`);
+                      i++
+                      return
+                  }
+              }
             item.goodsName = item.$goodsId
           })
+            if (i != 0) {
+                loading.close();
+                return
+            }
           // this.goodsName;
           transferAllocateSubmit({
             ...this.form,
@@ -494,6 +506,7 @@ export default {
             filesList:this.filesList
           }).then(res => {
             this.$message.success("保存成功");
+            this.editButton = true
             this.refresh(res.data.data.id)
             loading.close();
           }).finally(() => {
@@ -606,6 +619,7 @@ export default {
             return
         }
         this.$refs.dialogAssemblyRef.dialogVisible = true
+        this.$refs.dialogAssemblyRef.getAllWorkDicts()
         // this.dialogVisible = true
       },
     //编辑

+ 0 - 1
src/views/tirePartsMall/salesManagement/outboundWorkOrderL/dialogAssembly.vue

@@ -125,7 +125,6 @@ import {getCorpTypes} from "@/api/tirePartsMall/basicData/commodityInformation";
             }
         },
         created() {
-            this.getAllWorkDicts()
         },
         methods:{
             closeGoods() {

+ 1 - 1
src/views/tirePartsMall/salesManagement/outboundWorkOrderL/index.vue

@@ -21,7 +21,7 @@
           <crop-select v-model="search.corpId" corpType="KH" :refresh="false"></crop-select>
         </template>
         <template slot-scope="{type,size,row,$index}" slot="menuLeft">
-          <el-button icon="el-icon-plus" type="primary" :size="size" @click="detailsOpen = true;">新</el-button>
+          <el-button icon="el-icon-plus" type="primary" :size="size" @click="detailsOpen = true;">新建订单</el-button>
           <!--<el-button type="warning" icon="el-icon-download" size="small" @click="outExport">导出</el-button>-->
         </template>
         <template slot-scope="{ row, index }" slot="billno">