From ccf97392106808a476a0a0ebc57d6ac580d5af6a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AD=A3=E5=9C=A3=E5=8D=8E?= <752718920@qq.com> Date: Fri, 30 Apr 2021 17:49:03 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=99=E5=AE=A2=E6=88=B7=E5=92=8C=E4=BB=93?= =?UTF-8?q?=E5=BA=93=E5=A2=9E=E5=8A=A0=E6=9D=83=E9=99=90=E6=8E=A7=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jshERP-web/src/api/api.js | 2 ++ .../jeecgbiz/modal/JSelectMaterialModal.vue | 6 ++-- .../src/views/bill/mixins/BillModalMixin.js | 13 +++---- jshERP-web/src/views/report/InDetail.vue | 12 ++----- .../src/views/report/InMaterialCount.vue | 12 ++----- .../src/views/report/InOutStockReport.vue | 12 ++----- jshERP-web/src/views/report/OutDetail.vue | 12 ++----- .../src/views/report/OutMaterialCount.vue | 12 ++----- .../src/views/report/StockWarningReport.vue | 12 ++----- jshERP-web/src/views/system/UserList.vue | 34 ++++++++++++++++--- 10 files changed, 60 insertions(+), 67 deletions(-) diff --git a/jshERP-web/src/api/api.js b/jshERP-web/src/api/api.js index 6cb0a72f..28f9117a 100644 --- a/jshERP-web/src/api/api.js +++ b/jshERP-web/src/api/api.js @@ -139,6 +139,7 @@ const checkFunction = (params)=>getAction("/function/checkIsNameExist",params); const addSystemConfig = (params)=>postAction("/systemConfig/add",params); const editSystemConfig = (params)=>putAction("/systemConfig/update",params); const checkSystemConfig = (params)=>getAction("/systemConfig/checkIsNameExist",params); +const getCurrentSystemConfig = (params)=>getAction("/systemConfig/getCurrentInfo",params); //用户|角色|模块关系 const addUserBusiness = (params)=>postAction("/userBusiness/add",params); const editUserBusiness = (params)=>putAction("/userBusiness/update",params); @@ -254,6 +255,7 @@ export { addSystemConfig, editSystemConfig, checkSystemConfig, + getCurrentSystemConfig, addUserBusiness, editUserBusiness, checkUserBusiness, diff --git a/jshERP-web/src/components/jeecgbiz/modal/JSelectMaterialModal.vue b/jshERP-web/src/components/jeecgbiz/modal/JSelectMaterialModal.vue index befeb7ea..eea9d4c6 100644 --- a/jshERP-web/src/components/jeecgbiz/modal/JSelectMaterialModal.vue +++ b/jshERP-web/src/components/jeecgbiz/modal/JSelectMaterialModal.vue @@ -260,9 +260,9 @@ }, getDepotList() { let that = this; - getAction('/depot/findDepotByUserId?UBType=UserDepot&UBKeyId=').then((res) => { - if (res) { - that.depotList = res + getAction('/depot/findDepotByCurrentUser').then((res) => { + if(res.code === 200){ + that.depotList = res.data } }) }, diff --git a/jshERP-web/src/views/bill/mixins/BillModalMixin.js b/jshERP-web/src/views/bill/mixins/BillModalMixin.js index 9b8dfd40..e01fbc86 100644 --- a/jshERP-web/src/views/bill/mixins/BillModalMixin.js +++ b/jshERP-web/src/views/bill/mixins/BillModalMixin.js @@ -111,13 +111,14 @@ export const BillModalMixin = { }, initDepot() { let that = this; - getAction('/depot/findDepotByUserId?UBType=UserDepot&UBKeyId=').then((res) => { - if (res) { - for(let i=0; i { + if(res.code === 200){ + let arr = res.data + for(let i=0; i - {{ depot.name }} + {{ depot.depotName }} @@ -169,15 +169,9 @@ }); }, getDepotData() { - getAction('/depot/getAllList').then((res)=>{ + getAction('/depot/findDepotByCurrentUser').then((res)=>{ if(res.code === 200){ - let arr=res.data; - for(let i=0;i - {{ depot.name }} + {{ depot.depotName }} @@ -155,15 +155,9 @@ }); }, getDepotData() { - getAction('/depot/getAllList').then((res)=>{ + getAction('/depot/findDepotByCurrentUser').then((res)=>{ if(res.code === 200){ - let arr=res.data; - for(let i=0;i - {{ depot.name }} + {{ depot.depotName }} @@ -137,15 +137,9 @@ return param; }, getDepotData() { - getAction('/depot/getAllList').then((res)=>{ + getAction('/depot/findDepotByCurrentUser').then((res)=>{ if(res.code === 200){ - let arr=res.data; - for(let i=0;i - {{ depot.name }} + {{ depot.depotName }} @@ -169,15 +169,9 @@ }); }, getDepotData() { - getAction('/depot/getAllList').then((res)=>{ + getAction('/depot/findDepotByCurrentUser').then((res)=>{ if(res.code === 200){ - let arr=res.data; - for(let i=0;i - {{ depot.name }} + {{ depot.depotName }} @@ -155,15 +155,9 @@ }); }, getDepotData() { - getAction('/depot/getAllList').then((res)=>{ + getAction('/depot/findDepotByCurrentUser').then((res)=>{ if(res.code === 200){ - let arr=res.data; - for(let i=0;i - {{ depot.name }} + {{ depot.depotName }} @@ -114,15 +114,9 @@ return param; }, getDepotData() { - getAction('/depot/getAllList').then((res)=>{ + getAction('/depot/findDepotByCurrentUser').then((res)=>{ if(res.code === 200){ - let arr=res.data; - for(let i=0;i - 分配仓库 - - 分配客户 - + 分配仓库 + + 分配客户 + 编辑 @@ -81,6 +81,7 @@ import UserDepotModal from './modules/UserDepotModal' import UserCustomerModal from './modules/UserCustomerModal' import {postAction} from '@/api/manage'; + import {getCurrentSystemConfig} from '@/api/api' import {JeecgListMixin} from '@/mixins/JeecgListMixin' import JInput from '@/components/jeecg/JInput' export default { @@ -95,6 +96,8 @@ data() { return { queryParam: {}, + depotFlag: '0', + customerFlag: '0', columns: [ { title: '#', @@ -129,7 +132,30 @@ }, } }, + created () { + this.getSystemConfig() + }, methods: { + getSystemConfig() { + getCurrentSystemConfig().then((res) => { + if(res.code === 200){ + let systemConfig = res.data + this.depotFlag = systemConfig.depotFlag + this.customerFlag = systemConfig.customerFlag + } else { + this.$message.warning(res.data); + } + }) + }, + searchQuery() { + this.loadData(1); + this.getSystemConfig(); + }, + searchReset() { + this.queryParam = {} + this.loadData(1); + this.getSystemConfig(); + }, handleReset(id) { let that = this; postAction(that.url.resetPwd, {id: id}).then((res) => {