瀏覽代碼

Merge remote-tracking branch 'origin/dev' into dev

qinbai 3 年之前
父節點
當前提交
077fbd8d1a

+ 24 - 24
src/views/basicData/customerInformation/detailsPageEdit.vue

@@ -613,30 +613,30 @@ export default {
               type: "county"
             }
           },
-          {
-            label: "总返利",
-            prop: "profitReturn",
-            disabled: true,
-            span: 8
-          },
-          {
-            label: "已用返利",
-            prop: "usedProfit",
-            disabled: true,
-            span: 8
-          },
-          {
-            label: "可用返利",
-            prop: "surplusProfit",
-            disabled: false,
-            span: 8
-          },
-          {
-            label: "可用返利",
-            prop: "monthProfit",
-            disabled: true,
-            span: 8
-          },
+          // {
+          //   label: "总返利",
+          //   prop: "profitReturn",
+          //   disabled: true,
+          //   span: 8
+          // },
+          // {
+          //   label: "已用返利",
+          //   prop: "usedProfit",
+          //   disabled: true,
+          //   span: 8
+          // },
+          // {
+          //   label: "可用返利",
+          //   prop: "surplusProfit",
+          //   disabled: false,
+          //   span: 8
+          // },
+          // {
+          //   label: "可用返利",
+          //   prop: "monthProfit",
+          //   disabled: true,
+          //   span: 8
+          // },
           {
             label: "备注",
             prop: "remarks",

+ 72 - 1
src/views/businessManagement/purchaseOrder/detailsPageEdit.vue

@@ -24,7 +24,7 @@
           </el-button>
           <el-dropdown-menu slot="dropdown">
             <el-dropdown-item :disabled="!form.id || form.status > 0" @click.native="pleaseCheck">请核数据</el-dropdown-item>
-            <el-dropdown-item v-if="false">审核进度</el-dropdown-item>
+            <el-dropdown-item v-if="form.status > 0" @click.native="checkScheduleDialog = true,checkId=form.id">审核进度</el-dropdown-item>
             <el-dropdown-item v-if="false">撤销请核</el-dropdown-item>
           </el-dropdown-menu>
         </el-dropdown>
@@ -72,6 +72,14 @@
           :loading="saveLoading"
         >保 存
         </el-button>
+        <div v-if="checkDisabled" style="float: right;margin-left: 8px">
+          <el-button type="primary"
+                     size="small"
+                     class="el-button--small-yh"
+                     @click.stop="openCheckDialog">
+            审批
+          </el-button>
+        </div>
       </div>
     </div>
     <div class="customer-main">
@@ -513,6 +521,43 @@
       reportName="发货通知单"
       @onClose="onClose()"
     ></report-dialog>
+    <el-dialog
+      append-to-body
+      title="审批"
+      class="el-dialogDeep"
+      :visible.sync="checkDialog"
+      width="50%"
+      :close-on-click-modal="false"
+      :destroy-on-close="true"
+      :close-on-press-escape="false"
+      v-dialog-drag
+    >
+      <check
+        :checkData="checkData"
+        :checkDetail="false"
+        :idList="[]"
+        @choceCheckFun="choceCheckFun"
+      >
+      </check>
+    </el-dialog>
+    <el-dialog
+      append-to-body
+      title="审批进度"
+      class="el-dialogDeep"
+      :visible.sync="checkScheduleDialog"
+      width="40%"
+      :close-on-click-modal="false"
+      :destroy-on-close="true"
+      :close-on-press-escape="false"
+      v-dialog-drag
+    >
+      <check-schedule
+        :checkId="checkId"
+        :batchNo="batchNo"
+        @choceScheduleFun="choceScheduleFun"
+      >
+      </check-schedule>
+    </el-dialog>
   </div>
 </template>
 
@@ -550,6 +595,8 @@ import {
 } from "@/util/validate";
 import financialAccount from "../../../components/finance/financialAccount";
 import reportDialog from "@/components/report-dialog/main";
+import check from "@/components/check/check";
+import checkSchedule from "@/components/check/checkSchedule";
 
 export default {
   name: "detailsPage",
@@ -567,6 +614,8 @@ export default {
     feeInfo,
     financialAccount,
     reportDialog,
+    check,
+    checkSchedule,
   },
   data() {
     return {
@@ -834,6 +883,12 @@ export default {
       switchDialog: false,
       // 请核状态禁用
       browse: false,
+      checkDisabled: false,
+      checkData: {},
+      checkDialog: false,
+      checkScheduleDialog: false,
+      checkId: '',
+      batchNo:'',
     }
   },
   mounted() {
@@ -862,6 +917,10 @@ export default {
     this.getWorkDicts("packageRemarks").then(res => {
       this.packageOptions = res.data.data;
     });
+    if (this.detailData.check) {
+      this.checkDisabled = true
+      this.batchNo = this.detailData.check.batchNo
+    }
     if (this.detailData.id) {
       this.queryData(this.detailData.id)
     } else if(this.detailData.copyId) {
@@ -1707,6 +1766,18 @@ export default {
         return true;  //没有动过数据
       }
     },
+    //打开审核
+    openCheckDialog(){
+      this.checkData  = this.detailData.check
+      this.checkDialog = true;
+    },
+    //关闭审核
+    choceCheckFun(){
+      this.checkDialog = false;
+    },
+    choceScheduleFun(){
+      this.checkScheduleDialog = false
+    },
   }
 }
 </script>

+ 12 - 0
src/views/businessManagement/purchaseOrder/index.vue

@@ -222,6 +222,18 @@ export default {
       }
     })
   },
+  activated() {
+    if (this.$route.query.check) {
+      this.isShow = true
+      // this.beforeOpenPage({id: this.$route.query.check.billId})
+      this.detailData = {
+        id: this.$route.query.check.billId,
+        check: this.$route.query.check,
+      };
+      this.isShow = false;
+      this.$store.commit("DOMCG_IN_DETAIL");
+    }
+  },
   methods: {
     //删除列表后面的删除按钮触发触发(row, index, done)
     rowDel(row, index, done) {

+ 85 - 14
src/views/businessManagement/salesOrder/detailsPageEdit.vue

@@ -24,7 +24,7 @@
           </el-button>
           <el-dropdown-menu slot="dropdown">
             <el-dropdown-item :disabled="browse" @click.native="pleaseCheck">请核数据</el-dropdown-item>
-            <el-dropdown-item v-if="false">审核进度</el-dropdown-item>
+            <el-dropdown-item v-if="form.status > 0" @click.native="checkScheduleDialog = true,checkId=form.id">审核进度</el-dropdown-item>
             <el-dropdown-item v-if="false">撤销请核</el-dropdown-item>
           </el-dropdown-menu>
         </el-dropdown>
@@ -60,7 +60,7 @@
           </el-button>
           <el-dropdown-menu slot="dropdown">
             <el-dropdown-item
-              :disabled="detailData.seeDisabled"
+              :disabled="detailData.seeDisabled || form.status == 3"
               @click.native="saveSell">生成采购
             </el-dropdown-item>
             <el-dropdown-item
@@ -78,6 +78,14 @@
           @click="editCustomer(false)"
         >保 存
         </el-button>
+        <div v-if="checkDisabled" style="float: right;margin-left: 8px">
+          <el-button type="primary"
+                     size="small"
+                     class="el-button--small-yh"
+                     @click.stop="openCheckDialog">
+            审批
+          </el-button>
+        </div>
       </div>
     </div>
     <div class="customer-main">
@@ -286,8 +294,8 @@
                 <el-option
                   v-for="(item, index) in salesPriceOtion"
                   :key="index"
-                  :label="item.salesPrice"
-                  :value="item.salesPrice"></el-option>
+                  :label="item.salePrice"
+                  :value="item.salePrice"></el-option>
               </el-select>
               <span v-else>{{ row.price }}</span>
             </template>
@@ -735,6 +743,43 @@
       >
       </bill-application>
     </el-dialog>
+    <el-dialog
+      append-to-body
+      title="审批"
+      class="el-dialogDeep"
+      :visible.sync="checkDialog"
+      width="50%"
+      :close-on-click-modal="false"
+      :destroy-on-close="true"
+      :close-on-press-escape="false"
+      v-dialog-drag
+    >
+      <check
+        :checkData="checkData"
+        :checkDetail="false"
+        :idList="[]"
+        @choceCheckFun="choceCheckFun"
+      >
+      </check>
+    </el-dialog>
+    <el-dialog
+      append-to-body
+      title="审批进度"
+      class="el-dialogDeep"
+      :visible.sync="checkScheduleDialog"
+      width="40%"
+      :close-on-click-modal="false"
+      :destroy-on-close="true"
+      :close-on-press-escape="false"
+      v-dialog-drag
+    >
+      <check-schedule
+        :checkId="checkId"
+        :batchNo="batchNo"
+        @choceScheduleFun="choceScheduleFun"
+      >
+      </check-schedule>
+    </el-dialog>
   </div>
 </template>
 
@@ -793,6 +838,8 @@ import {
 } from "@/util/validate";
 import financialAccount from "../../../components/finance/financialAccount";
 import { gainUser } from "@/api/basicData/customerInquiry";
+import check from "@/components/check/check";
+import checkSchedule from "@/components/check/checkSchedule";
 
 export default {
   name: "detailsPage",
@@ -807,7 +854,9 @@ export default {
     reportDialog,
     feeInfo,
     billApplication,
-    financialAccount
+    financialAccount,
+    check,
+    checkSchedule,
   },
   data() {
     return {
@@ -1522,6 +1571,12 @@ export default {
       browse: false,
       roleName: '',
       userList: [],
+      checkDisabled: false,
+      checkData: {},
+      checkDialog: false,
+      checkScheduleDialog: false,
+      checkId: '',
+      batchNo:'',
     }
   },
   mounted() {
@@ -1563,9 +1618,12 @@ export default {
     if (this.detailData.id) {
       this.queryData(this.detailData.id)
     }
+    if (this.detailData.check) {
+      this.checkDisabled = true
+      this.batchNo = this.detailData.check.batchNo
+    }
     gainUser().then(res => {
       this.userList = res.data.data;
-      console.log(this.userList)
     });
     if (this.detailData.seeDisabled) {
       // this.bankOfDeposit.column.forEach(item => {
@@ -1877,7 +1935,7 @@ export default {
       res.data.forEach(item => {
         getMarketPrice({code: item.code, isFreight: this.form.isFreight, isLabel: this.form.isLabel}).then(response => {
           if (response.data.data.length > 0) {
-            this.$set(item, 'price', response.data.data[0].salesPrice)
+            this.$set(item, 'price', response.data.data[0].salePrice)
           } else {
             this.$set(item, 'price', '0')
           }
@@ -2041,6 +2099,7 @@ export default {
         tradeType: 'GN',
         optionType: 'GN',
         chargeMember: this.form.chargeMember,
+        amount: this.form.orderAmount
       }
       if(bool){ //申请货款
         this.billData.srcId = -1
@@ -2216,7 +2275,7 @@ export default {
       for (let item in this.goodsListSave) {
         getMarketPrice({code: this.goodsListSave[item].code, isFreight: this.form.isFreight, isLabel: this.form.isLabel}).then(res => {
           if (res.data.data.length > 0) {
-            this.$set(this.goodsListSave[item], 'price', res.data.data[0].salesPrice)
+            this.$set(this.goodsListSave[item], 'price', res.data.data[0].salePrice)
           } else {
             this.$set(this.goodsListSave[item], 'price', '0')
           }
@@ -2280,7 +2339,7 @@ export default {
       for (let item=0;item<this.tableData.length;item++) {
         getMarketPrice({code: this.tableData[item].code, isFreight: this.form.isFreight, isLabel: this.form.isLabel}).then(res => {
           if (res.data.data.length > 0) {
-            this.$set(this.tableData[item], 'price', res.data.data[0].salesPrice)
+            this.$set(this.tableData[item], 'price', res.data.data[0].salePrice)
           } else {
             this.$set(this.tableData[item], 'price', '0')
           }
@@ -2408,7 +2467,7 @@ export default {
     selectionChangePolicyTwo(list) {
       this.policyDataTwo = list
       // this.policyDataTwo.forEach(item => {
-      //   this.$set(item, 'price', item.salesPrice)
+      //   this.$set(item, 'price', item.salePrice)
       // })
       if (this.policyDataTwo.length > 0) {
         this.optionPolicy.selection = false
@@ -2430,7 +2489,7 @@ export default {
           if (!list[item].specialOffer) {
             getMarketPrice({code: list[item].code, isFreight: this.form.isFreight, isLabel: this.form.isLabel}).then(response => {
               if (response.data.data.length > 0) {
-                this.$set(list[item], 'price', response.data.data[0].salesPrice)
+                this.$set(list[item], 'price', response.data.data[0].salePrice)
               } else {
                 this.$set(list[item], 'price', '0')
               }
@@ -2439,16 +2498,16 @@ export default {
             this.$set(list[item], 'price', list[item].specialOffer)
           }
         } else {
-          if (!list[item].salesPrice) {
+          if (!list[item].salePrice) {
             getMarketPrice({code: list[item].code, isFreight: this.form.isFreight, isLabel: this.form.isLabel}).then(response => {
               if (response.data.data.length > 0) {
-                this.$set(list[item], 'price', response.data.data[0].salesPrice)
+                this.$set(list[item], 'price', response.data.data[0].salePrice)
               } else {
                 this.$set(list[item], 'price', '0')
               }
             })
           } else {
-            this.$set(list[item], 'price', list[item].salesPrice)
+            this.$set(list[item], 'price', list[item].salePrice)
           }
           this.$set(buyFree[item], 'price', '0')
           this.$set(buyFree[item], 'orderQuantity',  list[item].salesVolume)
@@ -3184,6 +3243,18 @@ export default {
         return true;  //没有动过数据
       }
     },
+    //打开审核
+    openCheckDialog(){
+      this.checkData  = this.detailData.check
+      this.checkDialog = true;
+    },
+    //关闭审核
+    choceCheckFun(){
+      this.checkDialog = false;
+    },
+    choceScheduleFun(){
+      this.checkScheduleDialog = false
+    },
   },
 }
 </script>

+ 10 - 0
src/views/businessManagement/salesOrder/index.vue

@@ -191,6 +191,16 @@ export default {
       this.isShow = true
       this.beforeOpenPage({id: this.$route.query.id})
     }
+    if (this.$route.query.check) {
+      this.isShow = true
+      // this.beforeOpenPage({id: this.$route.query.check.billId})
+      this.detailData = {
+        id: this.$route.query.check.billId,
+        check: this.$route.query.check,
+      };
+      this.isShow = false;
+      this.$store.commit("DOMXS_IN_DETAIL");
+    }
   },
   methods: {
     tableRowClassName({row, column, rowIndex, columnIndex}) {