From b1dbfd44f6bafaa4d24e0c1c3a0f7ae548e77f60 Mon Sep 17 00:00:00 2001 From: 王震 <10952869+daywangzhen@user.noreply.gitee.com> Date: 星期三, 27 十二月 2023 17:41:06 +0800 Subject: [PATCH] Merge branch 'master' of http://114.132.189.42:9002/r/mes-ocea-before --- src/views/equipment/equipment/index.vue | 79 ++++--- src/views/quality/processconfiguration/index.vue | 39 +- vue.config.js | 2 src/views/plan/manufacturingorder/auto-operationtask.vue | 33 ++- src/views/plan/manufacturingorder/productorder-form.vue | 4 src/views/admin/user/index.vue | 2 src/views/equipment/metering/index.vue | 66 +++-- src/views/technology/document/teststandard.vue | 1 src/views/basic/param/param-form.vue | 5 src/views/quality/Packaging_ledger/index.vue | 73 ++++-- src/views/common/ztt-table.vue | 4 src/views/plan/operationtask/operationtask-form.vue | 20 + src/views/product/workbench/productrecord-tab.vue | 8 src/views/quality/packageinspect/index.vue | 23 + src/views/plan/masterproductionschedule/index.vue | 26 -- src/views/plan/manufacturingorder/index.vue | 21 + src/views/basic/part/index.vue | 2 src/views/technology/document/document-form.vue | 4 src/views/quality/teststandard/index.vue | 164 +++++++------- src/page/index/top/index.vue | 3 src/views/basic/staff/index.vue | 2 src/views/technology/structure/index.vue | 49 ---- src/views/common/part.vue | 2 23 files changed, 318 insertions(+), 314 deletions(-) diff --git a/src/page/index/top/index.vue b/src/page/index/top/index.vue index 81d23d2..fadf7a5 100644 --- a/src/page/index/top/index.vue +++ b/src/page/index/top/index.vue @@ -25,7 +25,7 @@ </div> </el-tooltip> --> <el-tooltip - v-if="showLock" + v-if="showLock && permissions.product_work_bench" effect="dark" content="宸ヤ綔鍙�" placement="bottom"> @@ -139,6 +139,7 @@ showColor: state => state.common.showColor }), ...mapGetters([ + 'permissions', 'userInfo', 'isFullScreen', 'tagWel', diff --git a/src/views/admin/user/index.vue b/src/views/admin/user/index.vue index 80f0b7f..d50b400 100644 --- a/src/views/admin/user/index.vue +++ b/src/views/admin/user/index.vue @@ -222,7 +222,7 @@ // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl isShow: true, url: '/mes/user/upload', - Download: true, + download: true, fileName: '鐢ㄦ埛妯℃澘' }, importDialogVisible: false, diff --git a/src/views/basic/param/param-form.vue b/src/views/basic/param/param-form.vue index fa7f914..2f1fe1d 100644 --- a/src/views/basic/param/param-form.vue +++ b/src/views/basic/param/param-form.vue @@ -13,7 +13,7 @@ class="l-mes" > <el-form-item label="鍙傛暟缂栧彿" prop="code"> - <el-input v-model="dataForm.code" placeholder="鍙傛暟缂栧彿"></el-input> + <el-input v-model="dataForm.code" placeholder="鍙傛暟缂栧彿" disabled></el-input> </el-form-item> <el-form-item label="鍙傛暟椤�" prop="parameterItem"> <el-input @@ -99,9 +99,6 @@ dict: '' }, dataRule: { - code: [ - { required: true, message: '鍙傛暟缂栧彿涓嶈兘涓虹┖', trigger: 'blur' } - ], parameterItem: [ { required: true, message: '鍙傛暟椤逛笉鑳戒负绌�', trigger: 'blur' } ], diff --git a/src/views/basic/part/index.vue b/src/views/basic/part/index.vue index 17fc30c..82fb10b 100644 --- a/src/views/basic/part/index.vue +++ b/src/views/basic/part/index.vue @@ -85,6 +85,8 @@ uploadInfo: { // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl isShow: true, + download: true, + fileName: '宸茬敵璇风墿鏂欑紪鐮佹ā鏉�', url: '/mes/part/upload' }, prelang: 'operation', diff --git a/src/views/basic/staff/index.vue b/src/views/basic/staff/index.vue index 9d052a8..9442faf 100644 --- a/src/views/basic/staff/index.vue +++ b/src/views/basic/staff/index.vue @@ -43,7 +43,7 @@ // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl isShow: true, url: '/mes/staff/upload', - Download: true, + download: true, fileName: '鍛樺伐妯℃澘' }, prelang: 'operation', diff --git a/src/views/common/part.vue b/src/views/common/part.vue index dd03a4d..f860d17 100644 --- a/src/views/common/part.vue +++ b/src/views/common/part.vue @@ -1,7 +1,7 @@ <template> <el-dialog v-diadrag - width="70%" + width="75%" title="闆朵欢" top="5vh" :visible.sync="innerVisible" diff --git a/src/views/common/ztt-table.vue b/src/views/common/ztt-table.vue index 04f5297..e963067 100644 --- a/src/views/common/ztt-table.vue +++ b/src/views/common/ztt-table.vue @@ -508,9 +508,9 @@ <div class="el-upload__tip" slot="tip" > 鍙兘涓婁紶xlsx/xls鏂囦欢锛屼笖涓嶈秴杩�10M<el-button type="text" - style="font-size:12px;" + style="font-size:14px;text-decoration: underline;" @click="downDataTemplate(uploadInfo.fileName)" - v-if="uploadInfo.Download" + v-if="uploadInfo.download" >涓嬭浇妯℃澘</el-button > </div> diff --git a/src/views/equipment/equipment/index.vue b/src/views/equipment/equipment/index.vue index 083640d..462fdcc 100644 --- a/src/views/equipment/equipment/index.vue +++ b/src/views/equipment/equipment/index.vue @@ -225,40 +225,8 @@ searchInfoType: 'text' } ], - toolbar: [ - { - text: '鏂板', - type: 'primary', - fun: this.addOrUpdateHandle - }, - { - text: '鏍囩鎵撳嵃', - type: 'primary', - fun: this.labelPrint - }, - { - text: '鍚屾', - type: 'primary', - loading: false, - fun: this.pullEquipFun - } - ], - operator: [ - { - text: '淇敼', - icon: 'el-icon-edit', - type: 'text', - size: 'small', - fun: this.addOrUpdateHandle - }, - { - text: '鍒犻櫎', - icon: 'el-icon-delete', - type: 'text', - size: 'small', - fun: this.deleteHandle - } - ], + toolbar: [], + operator: null, operatorConfig: { fixed: 'right', label: '鎿嶄綔', @@ -279,6 +247,49 @@ ...mapGetters(['permissions']) }, created() { + this.uploadInfo.isShow = this.permissions.equipment_equipment_upload + if(this.permissions.equipment_equipment_add){ + this.table.toolbar.push({ + text: '鏂板', + type: 'primary', + fun: this.addOrUpdateHandle + }) + } + if(this.permissions.equipment_equipment_labelprint){ + this.table.toolbar.push({ + text: '鏍囩鎵撳嵃', + type: 'primary', + fun: this.labelPrint + }) + } + if(this.permissions.equipment_equipment_sync){ + this.table.toolbar.push({ + text: '鍚屾', + type: 'primary', + loading: false, + fun: this.pullEquipFun + }) + } + let arr = [] + if(this.permissions.equipment_equipment_edit){ + arr.push({ + text: '淇敼', + icon: 'el-icon-edit', + type: 'text', + size: 'small', + fun: this.addOrUpdateHandle + }) + } + if(this.permissions.equipment_equipment_del){ + arr.push({ + text: '鍒犻櫎', + icon: 'el-icon-delete', + type: 'text', + size: 'small', + fun: this.deleteHandle + }) + } + this.table.operator = arr.length>0 ? arr : null remote('work_shop').then((response) => { if (response.data.code === 0) { this.workshopList = response.data.data diff --git a/src/views/equipment/metering/index.vue b/src/views/equipment/metering/index.vue index 1fdc251..05b49e8 100644 --- a/src/views/equipment/metering/index.vue +++ b/src/views/equipment/metering/index.vue @@ -68,8 +68,8 @@ multipleSelection: [], uploadInfo: { // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl - Download:false, - isShow: true, + download:false, + isShow: true, url: '/mes/equipmentDevice/upload' }, prelang: 'workstation', @@ -261,16 +261,6 @@ }, ], toolbar: [ - { - text: '鏂板', - type: 'primary', - fun: this.addOrUpdateHandle - }, - { - text: '鏍囩鎵撳嵃', - type: 'primary', - fun: this.labelPrint - }, // { // text: '鍚屾', // type: 'primary', @@ -278,22 +268,7 @@ // fun: this.pullEquipFun // } ], - operator: [ - { - text: '淇敼', - icon: 'el-icon-edit', - type: 'text', - size: 'small', - fun: this.addOrUpdateHandle - }, - { - text: '鍒犻櫎', - icon: 'el-icon-delete', - type: 'text', - size: 'small', - fun: this.deleteHandle - } - ], + operator: null, operatorConfig: { fixed: 'right', label: '鎿嶄綔', @@ -315,6 +290,41 @@ ...mapGetters(['permissions']) }, created() { + this.uploadInfo.isShow = this.permissions.equipment_metering_upload + if(this.permissions.equipment_metering_add){ + this.table.toolbar.push({ + text: '鏂板', + type: 'primary', + fun: this.addOrUpdateHandle + }) + } + if(this.permissions.equipment_metering_labelprint){ + this.table.toolbar.push({ + text: '鏍囩鎵撳嵃', + type: 'primary', + fun: this.labelPrint + }) + } + let arr = [] + if(this.permissions.equipment_metering_edit){ + arr.push({ + text: '淇敼', + icon: 'el-icon-edit', + type: 'text', + size: 'small', + fun: this.addOrUpdateHandle + }) + } + if(this.permissions.equipment_metering_del){ + arr.push({ + text: '鍒犻櫎', + icon: 'el-icon-delete', + type: 'text', + size: 'small', + fun: this.deleteHandle + }) + } + this.table.operator = arr.length>0 ? arr : null remote('work_shop').then((response) => { if (response.data.code === 0) { this.workshopList = response.data.data diff --git a/src/views/plan/manufacturingorder/auto-operationtask.vue b/src/views/plan/manufacturingorder/auto-operationtask.vue index 79dfcbd..ad4cf17 100644 --- a/src/views/plan/manufacturingorder/auto-operationtask.vue +++ b/src/views/plan/manufacturingorder/auto-operationtask.vue @@ -25,7 +25,7 @@ prop="operationName" label="宸ュ簭" align="center" - width="80px" + min-width="80px" show-overflow-tooltip > </el-table-column> @@ -33,8 +33,7 @@ prop="workCenter" label="宸ヤ綔涓績" align="center" - width="200px" - show-overflow-tooltip + min-width="220px" > <template slot-scope="scope"> <el-select @@ -54,11 +53,12 @@ </el-select> </template> </el-table-column> - <el-table-column prop="workstationId" label="宸ヤ綔绔�" align="center"> + <el-table-column prop="workstationId" min-width="150" label="宸ヤ綔绔�" align="center"> <template slot-scope="scope"> <el-select v-model="scope.row.workstationId" filterable + :visible-change="initWorkStation" placeholder="璇烽�夋嫨宸ヤ綔绔�" style="width:100%" clearable @@ -97,6 +97,7 @@ prop="partNo" label="闆朵欢鍙�" align="center" + min-width="150" show-overflow-tooltip > </el-table-column> @@ -104,10 +105,11 @@ prop="partName" label="闆朵欢鍚嶇О" align="center" + min-width="150" show-overflow-tooltip > </el-table-column> - <el-table-column prop="plannedQuantity" label="璁″垝鏁伴噺" align="center"> + <el-table-column prop="plannedQuantity" min-width="100" label="璁″垝鏁伴噺" align="center"> <template slot-scope="scope"> <el-input v-model="scope.row.plannedQuantity" @@ -134,7 +136,7 @@ <el-input v-model="scope.row.discNum"></el-input> </template> </el-table-column> --> - <el-table-column prop="remark" label="澶囨敞" align="center"> + <el-table-column prop="remark" min-width="150" label="澶囨敞" align="center"> <template slot-scope="scope"> <el-input v-model="scope.row.remark"></el-input> </template> @@ -143,7 +145,7 @@ prop="plannedStartDate" label="璁″垝寮�濮嬫椂闂�" align="center" - width="200px" + min-width="200px" > <template slot-scope="scope"> <el-date-picker @@ -160,7 +162,7 @@ prop="plannedFinishDate" label="璁″垝瀹屾垚鏃堕棿" align="center" - width="200px" + min-width="200px" > <template slot-scope="scope"> <el-date-picker @@ -177,7 +179,7 @@ prop="manufactureAttr" label="鍒堕�犲睘鎬�" align="center" - width="100px" + min-width="150px" show-overflow-tooltip > <template slot-scope="scope"> @@ -197,7 +199,7 @@ </el-select> </template> </el-table-column> - <el-table-column label="鎿嶄綔" width="100" align="center"> + <el-table-column label="鎿嶄綔" fixed="right" width="100" align="center"> <template slot-scope="scope"> <el-button @click="copyTask(scope.row)" type="text" size="small" >澶嶅埗</el-button @@ -274,6 +276,15 @@ this.getManufactureAttrs('manufacture_attr_type') }, methods: { + initWorkStation(opName,arr){ + let workId = null + arr.forEach(ele=>{ + if(ele.name.indexOf(opName)>-1){ + workId = ele.id + } + }) + return workId + }, getManufactureAttrs(type) { remote(type).then((response) => { const code = response.data.code @@ -544,7 +555,7 @@ this.operationData.push({ operationName: item.operationName, workCenter: item.workCenter, - workstationId: item.workstationId, + workstationId: item.workstationId ? item.workstationId : this.initWorkStation(item.operationName,item.workstations), locationId: item.locationId, partNo: item.partNo, partName: item.partName, diff --git a/src/views/plan/manufacturingorder/index.vue b/src/views/plan/manufacturingorder/index.vue index af81923..b9bfe77 100644 --- a/src/views/plan/manufacturingorder/index.vue +++ b/src/views/plan/manufacturingorder/index.vue @@ -451,6 +451,16 @@ // 鏍囬 column: [ { + minWidth: '120', + prop: 'moNo', + label: '杞﹂棿璁㈠崟鍙�', + sort: true, + isTrue: true, + isSearch: true, + searchInfoType: 'text', + render: { fun: this.addOrUpdateHandle } + }, + { minWidth: '140', prop: 'state', label: '鐘舵��', @@ -591,16 +601,7 @@ return this.bomTypeDbOptions } }, - { - minWidth: '120', - prop: 'moNo', - label: '杞﹂棿璁㈠崟鍙�', - sort: true, - isTrue: true, - isSearch: true, - searchInfoType: 'text', - render: { fun: this.addOrUpdateHandle } - }, + { minWidth: '120', prop: 'manufactureAttr', diff --git a/src/views/plan/manufacturingorder/productorder-form.vue b/src/views/plan/manufacturingorder/productorder-form.vue index 2bf8212..9117086 100644 --- a/src/views/plan/manufacturingorder/productorder-form.vue +++ b/src/views/plan/manufacturingorder/productorder-form.vue @@ -478,7 +478,7 @@ </el-table> </el-card> </el-tab-pane> - <el-tab-pane + <!-- <el-tab-pane label="妫�娴嬫爣鍑�" key="tb1" id="tb1" @@ -491,7 +491,7 @@ :moRoutingOperationId="moRoutingOperationId" @refreshTestStandardInfo="refreshTestStandardInfo" ></testStandardTable> - </el-tab-pane> + </el-tab-pane> --> <!-- <el-tab-pane label="鎶芥瑙勫垯" key="tb2" diff --git a/src/views/plan/masterproductionschedule/index.vue b/src/views/plan/masterproductionschedule/index.vue index 5aca1b1..dcfb387 100644 --- a/src/views/plan/masterproductionschedule/index.vue +++ b/src/views/plan/masterproductionschedule/index.vue @@ -595,7 +595,7 @@ operatorConfig: { fixed: 'right', label: '鎿嶄綔', - width: 140, + width: 100, minWidth: 100 } }, @@ -644,14 +644,6 @@ type: 'text', size: 'small', fun: this.searchMasterPlanSourceHandle - }) - } - if(this.permissions.plan_masterproductionschedule_del){ - optionList.push({ - text: '浣滃簾', - type: 'text', - size: 'small', - fun: this.deleteMainPlan }) } if(optionList.length>0){ @@ -726,22 +718,6 @@ } } return '' - }, - // 鍒犻櫎 - deleteMainPlan(row) { - this.$confirm('鏄惁纭浣滃簾ID涓�' + row.id, '鎻愮ず', { - confirmButtonText: '纭畾', - cancelButtonText: '鍙栨秷', - closeOnClickModal: false, - type: 'warning' - }) - .then(function() { - return delObj(row.id) - }) - .then((data) => { - this.$message.success('鍒犻櫎鎴愬姛') - this.getData() - }) }, // 鏌ョ湅鐢熶骇璁″垝鏉ユ簮 searchMasterPlanSourceHandle(row) { diff --git a/src/views/plan/operationtask/operationtask-form.vue b/src/views/plan/operationtask/operationtask-form.vue index 35c8694..e57cdc9 100644 --- a/src/views/plan/operationtask/operationtask-form.vue +++ b/src/views/plan/operationtask/operationtask-form.vue @@ -671,7 +671,7 @@ } }) }, - changeWorkCenter() { + changeWorkCenter(opName) { this.workstations = [] this.dataForm.workstationId = null this.locationOptions = [] @@ -681,17 +681,26 @@ this.$refs.ganttIndex.init(this.workCenter) }) - this.changeWorkCenterAction() + this.changeWorkCenterAction(opName) }, - changeWorkCenterAction() { + changeWorkCenterAction(opName) { if (this.dataForm.workCenter) { const queryParamStation = Object.assign({ workCenter: this.dataForm.workCenter }) - + getAllWorkstationList(queryParamStation).then((response) => { const resData = response.data.data if (resData && resData.length > 0) { + let obj = null + resData.forEach((ele)=>{ + if(ele.name.indexOf(opName)>-1){ + obj = ele + } + }) + if(obj){ + this.dataForm.workstationId = obj.id + } this.workstations = resData } }) @@ -945,11 +954,10 @@ this.dataForm.operationName = routingOperation.operationName this.dataForm.workCenter = routingOperation.workCenter - this.changeWorkCenter() + this.changeWorkCenter(routingOperation.operationName) this.dataForm.routingOperationId = routingOperation.technologyRoutingOperationId }, - // 鏍规嵁宸ヤ綔绔欏垏鎹㈠簱浣� selectLocationByWorkstation() { this.locationOptions = [] diff --git a/src/views/product/workbench/productrecord-tab.vue b/src/views/product/workbench/productrecord-tab.vue index 9c72652..275b8aa 100644 --- a/src/views/product/workbench/productrecord-tab.vue +++ b/src/views/product/workbench/productrecord-tab.vue @@ -120,12 +120,12 @@ :show-overflow-tooltip="true" > <template slot="header" slot-scope="scope"> - <div style="line-height: 14px;">SN鍙�</div> + <div style="line-height: 14px;">鎵规鍙�</div> <div class="th" @click.stop> <template> <el-input type="text" - placeholder="SN鍙�" + placeholder="鎵规鍙�" v-model="searchContent.outBatchNo" clearable size="mini" @@ -280,7 +280,7 @@ </el-table-column> </el-table> </el-tab-pane> - <el-tab-pane label="闄勪欢"> + <!-- <el-tab-pane label="闄勪欢"> <el-upload ref="upload" action="/mes/operationTask/upload" @@ -292,7 +292,7 @@ :auto-upload="false" list-type="picture" ></el-upload> - </el-tab-pane> + </el-tab-pane> --> </el-tabs> </div> </div> diff --git a/src/views/quality/Packaging_ledger/index.vue b/src/views/quality/Packaging_ledger/index.vue index c465c2d..718fb62 100644 --- a/src/views/quality/Packaging_ledger/index.vue +++ b/src/views/quality/Packaging_ledger/index.vue @@ -33,6 +33,7 @@ </el-col> <el-col :span="2"> <el-button + v-if="permissions.quality_packaging_ledger_info_save" style="float: right; padding: 3px 0" type="text" @click="addpreserve" @@ -41,7 +42,7 @@ </el-col> <el-col :span="2"> <el-button - v-if="!isCheck" + v-if="!isCheck && permissions.quality_packaging_ledger_info_add" style="float: right; padding: 3px 0" type="text" @click="relateOperationParam()" @@ -110,6 +111,7 @@ width="80" ></el-table-column> <el-table-column + v-if="permissions.quality_packaging_ledger_info_operate" fixed="right" label="鎿嶄綔" align="center" @@ -171,6 +173,7 @@ import packfromadd from './pack-fromadd.vue' import vueQr from 'vue-qr' import PrintJS from 'print-js' +import { mapGetters } from 'vuex' export default { data(){ return { @@ -270,33 +273,8 @@ searchInfoType: 'datetimerange', }, ], - toolbar: [ - { - text: '鏂板', - type: 'primary', - fun: this.addOrUpdateHandle - }, - { - text: '鏍囩鎵撳嵃', - type: 'primary', - fun: this.printLabel - }, - ], - operator: [ - { - text: '妫�楠�', - icon: 'el-icon-position', - type: 'text', - size: 'small', - fun: this.check - },{ - text: '鍒犻櫎', - icon: 'el-icon-delete', - type: 'text', - size: 'small', - fun: this.deleteHandle - } - ], + toolbar: [], + operator: null, operatorConfig: { fixed: 'right', label: '鎿嶄綔', @@ -312,6 +290,45 @@ packfromadd, vueQr }, + created(){ + if(this.permissions.quality_packaging_ledger_add){ + this.table.toolbar.push({ + text: '鏂板', + type: 'primary', + fun: this.addOrUpdateHandle + }) + } + if(this.permissions.quality_packaging_ledger_labelprint){ + this.table.toolbar.push({ + text: '鏍囩鎵撳嵃', + type: 'primary', + fun: this.printLabel + }) + } + let arr = [] + if(this.permissions.quality_packaging_ledger_inspect){ + arr.push({ + text: '妫�楠�', + icon: 'el-icon-position', + type: 'text', + size: 'small', + fun: this.check + }) + } + if(this.permissions.quality_packaging_ledger_del){ + arr.push({ + text: '鍒犻櫎', + icon: 'el-icon-delete', + type: 'text', + size: 'small', + fun: this.deleteHandle + }) + } + this.table.operator = arr.length>0 ? arr : null + }, + computed:{ + ...mapGetters(['permissions']) + }, watch: { diaPrintTab(newVal){ if(!newVal){ diff --git a/src/views/quality/packageinspect/index.vue b/src/views/quality/packageinspect/index.vue index 3cc33c5..e8a924d 100644 --- a/src/views/quality/packageinspect/index.vue +++ b/src/views/quality/packageinspect/index.vue @@ -142,13 +142,7 @@ }, ], toolbar: [], - operator: [ - { - text: '浣滃簾', - type: 'text', - size: 'small', - fun: this.deleteHandle - }], + operator: null, operatorConfig: { fixed: 'right', label: '鎿嶄綔', @@ -161,7 +155,16 @@ components: { ttable, }, - created() { }, + created() { + if(this.permissions.quality_packageinspect_del){ + this.table.operator = [{ + text: '浣滃簾', + type: 'text', + size: 'small', + fun: this.deleteHandle + }] + } + }, computed: { ...mapGetters(['permissions']) }, @@ -193,6 +196,10 @@ }, // 鏂板 / 淇敼 addOrUpdateHandle(row) { + if(!this.permissions.quality_packageinspect_edit && row.id!=null){ + this.$message.error("璇ヨ鑹叉病鏈夋搷浣滄潈闄�") + return + } this.$router.push({ name: 'packageInspectForm', query: { diff --git a/src/views/quality/processconfiguration/index.vue b/src/views/quality/processconfiguration/index.vue index 2802435..b364506 100644 --- a/src/views/quality/processconfiguration/index.vue +++ b/src/views/quality/processconfiguration/index.vue @@ -272,26 +272,7 @@ // fun: this.handleExport // }, ], - operator: [ - // { - // text: '鍒犻櫎', - // type: 'text', - // size: 'small', - // fun: this.deleteHandle - // }, - { - text: '鎻愪氦瀹℃牳', - type: 'text', - size: 'small', - fun: this.Submitreview - }, - { - text: '瀹℃牳缁撴灉', - type: 'text', - size: 'small', - fun: this.AuditResult - } - ], + operator: null, operatorConfig: { fixed: 'right', label: '鎿嶄綔', @@ -314,6 +295,24 @@ }, created() { // this.getType() + let arr = [] + if(this.permissions.quality_processconfiguration_submit){ + arr.push({ + text: '鎻愪氦瀹℃牳', + type: 'text', + size: 'small', + fun: this.Submitreview + }) + } + if(this.permissions.quality_processconfiguration_result){ + arr.push({ + text: '瀹℃牳缁撴灉', + type: 'text', + size: 'small', + fun: this.AuditResult + }) + } + this.table.operator = arr.length>0 ? arr : null }, methods: { getQueryParam(data){ diff --git a/src/views/quality/teststandard/index.vue b/src/views/quality/teststandard/index.vue index 4be8c9b..52b4d38 100644 --- a/src/views/quality/teststandard/index.vue +++ b/src/views/quality/teststandard/index.vue @@ -26,6 +26,7 @@ </el-col> <el-col :span="8" :offset="4"> <el-button + v-if="permissions.quality_teststandard_layout" style="float: right; padding: 3px 0" type="text" @click="beginItemLayOut" @@ -39,7 +40,7 @@ type="text" :disabled="isSubmit" v-thinclick="`dataFormTestStandardParam`" - v-if="editable" + v-if="editable && permissions.quality_teststandard_save" >淇濆瓨 </el-button> </el-col> @@ -48,7 +49,7 @@ style="float: right; padding: 3px 0" type="text" @click="relateOperationParam()" - v-if="editable" + v-if="editable && permissions.quality_teststandard_insert" >娣诲姞 </el-button> </el-col> @@ -191,22 +192,22 @@ </template> </el-table-column><el-table-column label="娴嬭瘯鏂规硶" - prop="purpose" - align="center" - width="80" - > - <template slot-scope="scope"> - <el-input v-model="scope.row.purpose"></el-input> - </template> - </el-table-column> - <el-table-column - label="娴嬭瘯鐩殑" prop="method" align="center" width="80" > <template slot-scope="scope"> <el-input v-model="scope.row.method"></el-input> + </template> + </el-table-column> + <el-table-column + label="娴嬭瘯鐩殑" + prop="purpose" + align="center" + width="80" + > + <template slot-scope="scope"> + <el-input v-model="scope.row.purpose"></el-input> </template> </el-table-column> @@ -232,7 +233,7 @@ </el-table-column> --> <el-table-column label="鍗曚綅" prop="unit" align="center" /> <!--<el-table-column label="鍙傛暟绫诲瀷" prop="type" align="center" :formatter="getParam"/>--> - <el-table-column label="鎿嶄綔" align="center"> + <el-table-column label="鎿嶄綔" align="center" v-if="permissions.quality_teststandard_table_operate"> <template slot-scope="scope"> <el-button type="text" @@ -308,6 +309,7 @@ import { copyTestStandard } from '../../../api/quality/teststandard' import EditParamForm from './edit-param-form' import itemLayout from './item-layout' +import { mapGetters } from 'vuex' export default { data() { return { @@ -424,71 +426,8 @@ searchInfoType: 'text' } ], - toolbar: [ - { - text: '鏂板', - type: 'primary', - fun: this.addOrUpdateHandle - }, - { - text: '澶嶅埗', - type: 'primary', - fun: this.copy - }, - { - text: '鎵瑰噯', - fun: () => { - this.changeState('accept') - }, - disabled: false, - permitArr: [] - }, - { - text: '鎷掔粷', - fun: () => { - this.changeState('reject') - }, - disabled: false, - permitArr: [] - }, - { - text: '鎾ら攢', - fun: () => { - this.changeState('cancel') - }, - disabled: false, - permitArr: [] - }, - { - text: '澶辨晥', - fun: () => { - this.changeState('disabled') - }, - disabled: false, - permitArr: [] - }, - { - text: '鍒犻櫎', - fun: () => { - this.deleteAll() - }, - disabled: false, - permitArr: [] - } - ], - operator: [ - { - text: '鍒犻櫎', - icon: 'el-icon-delete', - type: 'text', - size: 'small', - fun: this.deleteHandle - // show: { - // val: ['01draft'], - // key: 'state' - // } - } - ], + toolbar: [], + operator: null, operatorConfig: { fixed: 'right', label: '鎿嶄綔', @@ -557,6 +496,7 @@ itemLayout }, computed: { + ...mapGetters(['permissions']), editable: function() { if (!this.currentTestStandard) { return true @@ -575,6 +515,74 @@ this.rowDrop() }, created() { + if(this.permissions.quality_teststandard_add){ + this.table.toolbar.push({ + text: '鏂板', + disabled: false, + type: 'primary', + fun: ()=>{this.addOrUpdateHandle()}, + permitArr: [] + }) + } + if(this.permissions.quality_teststandard_copy){ + this.table.toolbar.push({ + text: '澶嶅埗', + type: 'primary', + disabled: false, + fun: ()=>{this.copy()}, + permitArr: [] + }) + } + if(this.permissions.quality_teststandard_accept){ + this.table.toolbar.push({ + text: '鎵瑰噯', + disabled: false, + fun: ()=>{this.changeState('accept')}, + permitArr: [], + }) + } + if(this.permissions.quality_teststandard_revoke){ + this.table.toolbar.push({ + text: '鎷掔粷', + disabled: false, + fun: ()=>{this.changeState('reject')}, + permitArr: [], + }) + } + if(this.permissions.quality_teststandard_cancel){ + this.table.toolbar.push({ + text: '鎾ら攢', + disabled: false, + fun: () => {this.changeState('cancel')}, + permitArr: [], + }) + } + if(this.permissions.quality_teststandard_lose){ + this.table.toolbar.push({ + text: '澶辨晥', + disabled: false, + fun: () => {this.changeState('disabled')}, + permitArr: [], + }) + } + if(this.permissions.quality_teststandard_del){ + this.table.toolbar.push({ + text: '鎵归噺鍒犻櫎', + type:'primary', + disabled: false, + permitArr: [], + fun: ()=>{this.deleteAll()}, + }) + } + if(this.permissions.quality_teststandard_del){ + this.table.operator = [{ + text: '鍒犻櫎', + icon: 'el-icon-delete', + type: 'text', + size: 'small', + fun: this.deleteHandle + }] + } this.initDirParamType() this.initDirInspectionType() }, diff --git a/src/views/technology/document/document-form.vue b/src/views/technology/document/document-form.vue index 906bb1f..93cf63a 100644 --- a/src/views/technology/document/document-form.vue +++ b/src/views/technology/document/document-form.vue @@ -535,7 +535,7 @@ :richContent="ele.remark" ></rich-text> </el-tab-pane> --> - <el-tab-pane label="妫�娴嬫爣鍑�"> + <!-- <el-tab-pane label="妫�娴嬫爣鍑�"> <checkStandardTable ref="documentTestStandardTable" :dataFormId="dataForm.id" @@ -554,7 +554,7 @@ refreshTestStandardInfo " ></checkStandardTable> - </el-tab-pane> + </el-tab-pane> --> <!-- <el-tab-pane label="鎶芥瑙勫垯"> <div> <div style="padding: 0px 20px;"> diff --git a/src/views/technology/document/teststandard.vue b/src/views/technology/document/teststandard.vue index 4607896..699a20c 100644 --- a/src/views/technology/document/teststandard.vue +++ b/src/views/technology/document/teststandard.vue @@ -42,6 +42,7 @@ align="center" /> <el-table-column label="鍗曚綅" prop="unit" align="center" /> + <el-table-column label="娴嬭瘯鏂规硶" prop="method" align="center" /> </el-table> </el-col> </el-row> diff --git a/src/views/technology/structure/index.vue b/src/views/technology/structure/index.vue index 256c93c..3704dd8 100644 --- a/src/views/technology/structure/index.vue +++ b/src/views/technology/structure/index.vue @@ -6,7 +6,6 @@ @handleSelectionChange="handleSelectionChange" @customUploadPage="structureImport" :uploadInfo="uploadInfo" - :customUpload="customUpload" :prelang="prelang" :options="options" :ajaxFun="ajaxFun" @@ -19,47 +18,6 @@ v-if="permissions.technology_structure_copy">澶嶅埗</el-button> </template> </ttable> - <!-- 寮圭獥, 鏂板 / 淇敼 --> - <el-dialog - title="瀵煎叆" - :visible.sync="importStructureVisible" - width="50%" - > - <span> - <div style="display:flex;justify-content:space-around;"> - <div> - <el-upload - style="margin-left:8px;display: inline;" - class="upload-demo" - drag - :headers="headers" - :action="zhuangbeiUploadInfo.url" - :beforeUpload="beforeAvatarUpload" - :limit="1" - :show-file-list="false" - :file-list="zhuangbeifileList" - :data="zhuangbeiUploadInfo.uploadData" - :on-success="zhuangbeiFileSuccessUploadScan" - :on-error="handleError" - accept=".xlsx,.xls,.csv, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel" - :auto-upload="true" - ref="zhuangbeiUploadScan" - multiple - > - <i class="el-icon-upload"></i> - <div class="el-upload__text"><em>瀵煎叆浜у搧缁撴瀯</em></div> - <div class="el-upload__tip" slot="tip"> - 鍙兘涓婁紶xlsx/xls鏂囦欢锛屼笖涓嶈秴杩�10M<el-button - type="text" - style="font-size:12px;" - ></el-button - > - </div> - </el-upload> - </div> - </div> - </span> - </el-dialog> </basic-container> </div> </template> @@ -98,6 +56,8 @@ uploadInfo: { // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl isShow: true, + fileName: '浜у搧缁撴瀯妯℃澘', + download: true, url: '/mes/structure/uploadExcelPlus' }, prelang: 'structure', @@ -268,11 +228,6 @@ // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl isShow: true, url: '/mes/structure/upload' - }, - zhuangbeiUploadInfo: { - // 鏄惁灞曠ず涓婁紶EXCEL浠ュ強瀵瑰簲鐨剈rl - isShow: true, - url: '/mes/structure/uploadExcelPlus' }, zhuangbeifileList: [], shepinfileList: [], diff --git a/vue.config.js b/vue.config.js index 604c254..e5ad73d 100644 --- a/vue.config.js +++ b/vue.config.js @@ -5,7 +5,7 @@ // const url = 'http://192.168.32.45:9999' -const url = 'http://192.168.2.63:9999' +const url = 'http://192.168.2.7:9999' // const url = 'http://localhost:9999' -- Gitblit v1.9.3