diff --git a/src/views/basic/BussinessType.vue b/src/views/basic/BussinessType.vue index 02f93cf..b0e8fcc 100644 --- a/src/views/basic/BussinessType.vue +++ b/src/views/basic/BussinessType.vue @@ -77,6 +77,7 @@ <el-button type="text" size="small" + :disabled="!configParms.typeScan" @click.native.stop="handleModifyClick(scope.row)" >编辑 </el-button @@ -84,6 +85,7 @@ <el-button type="text" size="small" + :disabled="!configParms.typeScan" @click.native.stop="deleteDialog(scope.row)" >删除 </el-button diff --git a/src/views/basic/BussinessTypeLocl.vue b/src/views/basic/BussinessTypeLocl.vue index c90e3ad..cb86d60 100644 --- a/src/views/basic/BussinessTypeLocl.vue +++ b/src/views/basic/BussinessTypeLocl.vue @@ -57,6 +57,7 @@ <el-button type="text" size="small" + :disabled="!configParms.typeBus" @click.native.stop="handleModifyClick(scope.row)" >编辑 </el-button @@ -64,6 +65,7 @@ <el-button type="text" size="small" + :disabled="!configParms.typeBus" @click.native.stop="deleteDialog(scope.row)" >删除 </el-button diff --git a/src/views/basic/BussinessTypeThird.vue b/src/views/basic/BussinessTypeThird.vue index 97bcf14..aa1b3b1 100644 --- a/src/views/basic/BussinessTypeThird.vue +++ b/src/views/basic/BussinessTypeThird.vue @@ -51,6 +51,7 @@ <el-button type="text" size="small" + :disabled="!configParms.typeBus" @click.native.stop="handleModifyClick(scope.row)" >编辑 </el-button @@ -58,6 +59,7 @@ <el-button type="text" size="small" + :disabled="!configParms.typeBus" @click.native.stop="handleDeleteClick(scope.row)" >删除 </el-button diff --git a/src/views/basic/CorpMaintain.vue b/src/views/basic/CorpMaintain.vue index 0deb45c..50da971 100644 --- a/src/views/basic/CorpMaintain.vue +++ b/src/views/basic/CorpMaintain.vue @@ -29,6 +29,7 @@ </el-button > <el-button type="primary" @click.native="handleForm(null, null)" + :disabled="!configParms.basicCorp" >新增 </el-button > @@ -85,6 +86,7 @@ <el-button type="text" size="small" + :disabled="!configParms.basicCorp" @click.native="handleForm(scope.$index, scope.row)" >编辑 </el-button @@ -100,6 +102,7 @@ <el-button type="text" size="small" + :disabled="!configParms.basicCorp" @click.native.stop="deleteDialog(scope.row)" >删除 </el-button @@ -315,6 +318,7 @@ import { import selectUnit from "./CorpRelevance"; import selectSingleUnit from "./CorpSingleRelevance"; import {getBasicThirdSys} from "../../api/basic/basicThirdSys"; +import {findConfig} from "@/api/thrsys/spsSyncStatus"; var pinyin = require("pinyin"); @@ -393,6 +397,7 @@ export default { thirdSys: [], thirdSysFk: null, defaultSys: null, + configParms: {}, }; }, @@ -689,8 +694,18 @@ export default { }) .catch(() => { }); - } - , + }, + getSyncConfig() { + findConfig() + .then((response) => { + if (response.code == 20000) { + this.configParms = response.data; + } + }) + .catch(() => { + }); + }, + } , mounted() { @@ -702,6 +717,7 @@ export default { , created() { this.getList(); + this.getSyncConfig(); this.getBasicThirdSys(); } , diff --git a/src/views/basic/invWarehouse.vue b/src/views/basic/invWarehouse.vue index 732ff5a..a7fa25c 100644 --- a/src/views/basic/invWarehouse.vue +++ b/src/views/basic/invWarehouse.vue @@ -29,6 +29,7 @@ <el-button type="primary" icon="el-icon-refresh" @click="onReset"></el-button> <el-button type="primary" icon="search" @click="getList">查询</el-button> <el-button type="primary" @click.native="handleForm(null, null,'addTop')" + :disabled="!configParms.basicInv" >添加仓库 </el-button > @@ -42,9 +43,9 @@ :on-success="handleChange" :file-list="fileList" > - <el-button size="mini" type="primary">导入</el-button> + <el-button size="mini" type="primary" :disabled="!configParms.basicInv">导入</el-button> </el-upload> - <el-button type="primary" icon="search" @click="exportInvwarehouse">导出</el-button> + <el-button type="primary" icon="search" @click="exportInvwarehouse" :disabled="!configParms.basicInv">导出</el-button> <!-- <el-button type="primary" icon="search" @click="uploadInvwarehouse">同步至UDI管理系统</el-button>--> @@ -115,6 +116,7 @@ <el-button type="text" size="small" + :disabled="!configParms.basicInv" @click.native.stop="handleForm(node, scope.row, 'edit')" >编辑 </el-button @@ -122,7 +124,7 @@ <el-button type="text" size="small" - :disabled="scope.row.code==1000 ||scope.row.code==1001" + :disabled="scope.row.code==1000 ||scope.row.code==1001 || !configParms.basicInv" @click.native.stop="handleDel(node,scope.row)" >删除 </el-button @@ -136,7 +138,7 @@ <el-card style="width: 49%; float: left; margin-right: 0px;"> <div slot="header" class="clearfix" style="margin-bottom: 20px;"> <el-button style="float: right;" type="primary" @click="addUser()" - :disabled="currentRow.status == 0">添加用户 + :disabled="currentRow.status == 0 || !configParms.basicInv">添加用户 </el-button> </div> <el-table @@ -188,7 +190,7 @@ <el-card style="width: 49%; float: right; margin-left: 0px;"> <div slot="header" class="clearfix" style="margin-bottom: 20px;"> <el-button style="float: right;" @click="addBussinessType()" type="primary" - :disabled="currentRow.status == 0">添加单据类型 + :disabled="currentRow.status == 0 || !configParms.basicInv">添加单据类型 </el-button> </div> <el-table @@ -594,6 +596,7 @@ import {getJoinBussinessType} from "../../api/basic/bussinessType"; import {formatDate} from "@/utils/date"; import axios from "axios"; import store from "@/store"; +import {findConfig} from "@/api/thrsys/spsSyncStatus"; const formJson = { id: null, @@ -687,7 +690,8 @@ export default { page: 1, limit: 10 , thirdSysFk: "thirdId", - } + }, + configParms: {} }; }, methods: { @@ -1267,6 +1271,16 @@ export default { hideThrWarehouseTable() { this.thrWareHouseVisible = false; }, + getSyncConfig() { + findConfig() + .then((response) => { + if (response.code == 20000) { + this.configParms = response.data; + } + }) + .catch(() => { + }); + }, }, filters: { statusFilterType(status) { @@ -1290,6 +1304,7 @@ export default { // 加载表格数据 this.init(); this.getList(); + this.getSyncConfig(); }, }; </script> diff --git a/src/views/thrsys/ThrInvWarehouse.vue b/src/views/thrsys/ThrInvWarehouse.vue index dcd67ef..948f3f2 100644 --- a/src/views/thrsys/ThrInvWarehouse.vue +++ b/src/views/thrsys/ThrInvWarehouse.vue @@ -33,6 +33,7 @@ <el-button type="primary" icon="el-icon-refresh" @click="onReset"></el-button> <el-button type="primary" icon="search" @click="getList">查询</el-button> <el-button type="primary" @click.native="handleForm(null, null,'addTop')" + :disabled="!configParms.basicThirdInv" >添加仓库 </el-button> </el-button-group> @@ -74,7 +75,7 @@ <el-button type="text" size="small" - + :disabled="!configParms.basicThirdInv" @click.native.stop="handleForm(node, scope.row, 'edit')" >编辑 </el-button @@ -82,6 +83,7 @@ <el-button type="text" size="small" + :disabled="!configParms.basicThirdInv" @click.native.stop="handleDel(node,scope.row)" >删除 </el-button @@ -234,6 +236,7 @@ import { deleteThrWarehouse, } from "../../api/thrsys/thrInvWarehouse"; import {getBasicThirdSys} from "../../api/basic/basicThirdSys"; +import {findConfig} from "@/api/thrsys/spsSyncStatus"; const formJson = { id: null, @@ -298,6 +301,7 @@ export default { pidData: {}, deleteLoading: false, thirdSys: [], + configParms: {}, }; }, methods: { @@ -574,7 +578,17 @@ export default { }, thirdSysFkChange(thirdSysFk) { console.log(thirdSysFk); - } + }, + getSyncConfig() { + findConfig() + .then((response) => { + if (response.code == 20000) { + this.configParms = response.data; + } + }) + .catch(() => { + }); + }, }, filters: { statusFilterType(status) { @@ -597,6 +611,7 @@ export default { created() { // 加载表格数据 this.getBasicThirdSys(); + this.getSyncConfig(); this.getList(); }, }; diff --git a/src/views/thrsys/ThrProducts.vue b/src/views/thrsys/ThrProducts.vue index 98c0795..8940b1a 100644 --- a/src/views/thrsys/ThrProducts.vue +++ b/src/views/thrsys/ThrProducts.vue @@ -49,7 +49,7 @@ <el-button-group style="display:flex;"> <el-button type="primary" icon="el-icon-refresh" @click="onReset"></el-button> <el-button type="primary" icon="search" @click="getList">查询</el-button> - <el-button type="primary" @click="addProductVisible=true">新增</el-button> + <el-button type="primary" @click="addProductVisible=true" :disabled="!configParms.basicThirdProducts">新增</el-button> <!--<el-button type="primary" icon="search" @click="clearAll">清空全部</el-button>--> <!--<el-upload--> <!--v-if="!this.thirdSysDetail.enabled"--> @@ -84,7 +84,7 @@ >详情 </el-button> <el-button type="text" size="small" @click.native.stop="deleteDialog(scope.row)" - v-if="thirdSysDetail.fromType!=0" + v-if="thirdSysDetail.fromType!=0" :disabled="!configParms.basicThirdProducts" >删除 </el-button> </template> @@ -135,6 +135,7 @@ import {getBasicThirdSys, filterDetailByKey} from "../../api/basic/basicThirdSys import {selectIp} from "../../api/param/systemParamConfig"; import thrProductsDetail from "./ThrProductsDetail"; import ThrProductsAdd from "@/views/thrsys/ThrProductsAdd"; +import {findConfig} from "@/api/thrsys/spsSyncStatus"; export default { data() { @@ -179,7 +180,8 @@ export default { tyshxydm: null, qxlb: null, cpms: null - } + }, + configParms: {}, }; }, @@ -374,7 +376,17 @@ export default { this.getList(); } Object.keys(this.newProductData).forEach(key => this.newProductData[key] = null); - } + }, + getSyncConfig() { + findConfig() + .then((response) => { + if (response.code == 20000) { + this.configParms = response.data; + } + }) + .catch(() => { + }); + }, }, components: { thrProductsDetail, ThrProductsAdd @@ -383,6 +395,7 @@ export default { }, created() { this.getBasicThirdSys(); + this.getSyncConfig(); }, }; </script> diff --git a/src/views/userManage/admin/authAdmin.vue b/src/views/userManage/admin/authAdmin.vue index d5346b9..9f5f932 100644 --- a/src/views/userManage/admin/authAdmin.vue +++ b/src/views/userManage/admin/authAdmin.vue @@ -70,13 +70,14 @@ <el-button type="text" size="small" + :disabled="!configParms.sysUser" @click.native="handleForm(scope.$index, scope.row)" >编辑 </el-button> <el-button type="text" size="small" - :disabled="scope.row.id === 1" + :disabled="scope.row.id === 1 || !configParms.sysUser" @click.native="handleDel(scope.$index, scope.row)" >删除 </el-button>