From 27ac12ea99fc5b39e8fa59598fcd1687443069d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=83=91=E6=98=8E=E6=A2=81?= <2429105222@qq.com> Date: Mon, 24 Apr 2023 11:29:14 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=9A=E5=8A=A1=E8=AE=A2=E5=8D=95=E5=8D=95?= =?UTF-8?q?=E6=8D=AE=E4=BB=A3=E7=A0=81=E4=BF=AE=E6=94=B9=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/purchase/purOrder/purOrder.vue | 80 +++++++++++++++--------- 1 file changed, 50 insertions(+), 30 deletions(-) diff --git a/src/views/purchase/purOrder/purOrder.vue b/src/views/purchase/purOrder/purOrder.vue index dcfc4a3c..dc3098b3 100644 --- a/src/views/purchase/purOrder/purOrder.vue +++ b/src/views/purchase/purOrder/purOrder.vue @@ -3,14 +3,15 @@ - - + + - + + - + - - - - + - + - + + + + + + + + + + + + - - + @@ -81,15 +89,15 @@ {{ emergencyMap[scope.row.emergency] }} - - - + + + @@ -113,15 +121,15 @@ - + + - - - - - - + + + + + @@ -149,6 +157,7 @@ import purPlanEdit from "./purOrderEditDialog"; import {inserThrOrderWeb, listOrderDetail, delOrderDetailAll, listOrder} from "@/api/purchase/purOrder"; import {getInvListByUser} from '@/api/system/invWarehouse' import {getDeptListByUser} from '@/api/auth/authDept' +import {filterSubAll} from "@/api/system/invSubWarehouse"; export default { data() { @@ -166,8 +175,11 @@ export default { corpName: null, type: 1, editStatus: 1, + emergency:'', + targetDeptCode:'', }, formName: null, + invCodebe:null, formMap: { add: "新增采购订单", update: "编辑采购订单", @@ -178,10 +190,10 @@ export default { 3: "已审核", 4: "已拒绝" }, - emergencyMap: { - 1: "普通", - 2: "紧急", - 3: "不紧急", + emergencyMap:{ + 1: "正常", + 2: "较急", + 3: "特急", }, invList: {}, deptList: {}, @@ -247,6 +259,7 @@ export default { corpName: null, type: 1, editStatus: 1, + targetDeptCode: this.invCodebe, }; this.actDateRange = []; this.getList(); @@ -296,6 +309,7 @@ export default { if (response.code == 20000) { this.list = response.data.list || []; this.total = response.data.total || 0; + this.detailList=[] } else { this.$message.error(response.message); } @@ -387,14 +401,22 @@ export default { this.detailList = []; }, getInvList() { - getInvListByUser().then((res) => { + var query={ + parentId:this.filterQuery.targetDeptCode + } + filterSubAll(query).then((res) => { this.invList = res.data || []; - this.getBusType(); }) }, getDeptList() { getDeptListByUser().then((res) => { this.deptList = res.data || []; + if(this.deptList.length>0){ + this.filterQuery.targetDeptCode=this.deptList[0].code + this.invCodebe=this.filterQuery.targetDeptCode + } + this.getList(); + this. getInvList(); }); }, @@ -430,8 +452,6 @@ export default { } , created() { - this.getList(); - this.getInvList(); this.getDeptList(); } ,