diff --git a/src/views/inspection/inspectionobject.vue b/src/views/inspection/inspectionobject.vue index 11412ca..dc54223 100644 --- a/src/views/inspection/inspectionobject.vue +++ b/src/views/inspection/inspectionobject.vue @@ -121,13 +121,7 @@ label: "对象名称", prop: "objectName", search:true, - type: "select", span: 4.5, - dicUrl: "/api/daf-system/dict/dictionary?code=obj_name", - props: { - label: "dictValue", - value: "dictKey" - }, rules: [{ required: true, message: "请输入对象名称", diff --git a/src/views/inspection/inspectionobjectDetail.vue b/src/views/inspection/inspectionobjectDetail.vue index fc1d734..55ae764 100644 --- a/src/views/inspection/inspectionobjectDetail.vue +++ b/src/views/inspection/inspectionobjectDetail.vue @@ -27,6 +27,7 @@ import {getList, getDetail, add, update, remove, takeEffect, lapse} from "@/api/inspection/inspectionobject"; import {mapGetters} from "vuex"; import {getToken} from "@/util/auth"; +import request from "@/router/axios"; export default { name: "inspectionrouteDetail", @@ -35,6 +36,7 @@ export default { addUpdateShowButton:{}, shouldShowButton:{}, readonlyForm:{}, + objectAreaFlag:{}, frame_class: '', form: {}, query: {}, @@ -57,13 +59,8 @@ export default { label: "对象名称", prop: "objectName", search:true, - type: "select", span:8, - dicUrl: "/api/daf-system/dict/dictionary?code=obj_name", - props: { - label: "dictValue", - value: "dictKey" - }, + maxlength: 20, rules: [{ required: true, message: "请输入对象名称", @@ -75,6 +72,7 @@ export default { prop: "station", search:true, type: "select", + disabled: true, span:8, dicUrl: "/api/daf-system/dict/dictionary?code=station", props: { @@ -91,6 +89,37 @@ export default { label: "对象类型", prop: "objectType", span:8, + maxlength: 20, + event: { + change: (val) => { + if (!val) return + if (val) { + if (val=="工器具"){ + const toolsCodeId = this.findObject(this.option.column, "toolsCodeId"); + toolsCodeId.display = true; + const kksNo = this.findObject(this.option.column, "kksNo"); + this.form.kksNo=' '; + kksNo.disabled = true; + if(["view"].includes(this.$route.query.frameMode)) { + kksNo.disabled = false; + const objectNo = this.findObject(this.option.column, "objectNo"); + objectNo.disabled = false; + } + }else{ + const toolsCodeId = this.findObject(this.option.column, "toolsCodeId"); + this.form.toolsCodeId=' '; + toolsCodeId.display = false; + const kksNo = this.findObject(this.option.column, "kksNo"); + kksNo.disabled = false; + if(["view"].includes(this.$route.query.frameMode)) { + kksNo.disabled = false; + const objectNo = this.findObject(this.option.column, "objectNo"); + objectNo.disabled = false; + } + } + } + }, + }, rules: [{ required: true, message: "请输入对象类型", @@ -102,6 +131,7 @@ export default { prop: "objectArea", search:true, span:8, + maxlength: 20, rules: [{ required: true, message: "请输入对象区域", @@ -129,6 +159,7 @@ export default { label: "KKS编号", prop: "kksNo", search:true, + disabled: false, span:8, type: "select", dicUrl: "/api/equipmentledger/getKksList", @@ -136,6 +167,22 @@ export default { label: "kksEncoding", value: "kksEncoding", }, + event: { + change: (val) => { + if (!val) return + if (val) { + request({ + url: '/api/equipmentledger/getDetailList', + method: 'get', + params: { + KksNo: val + } + }).then((res) => { + this.form.station = res.data.data.station; + }) + } + }, + }, rules: [{ required: true, message: "请输入KKS编号", @@ -146,6 +193,36 @@ export default { label: "取消原因", prop: "cancelReason", span: 8, + maxlength: 20, + }, + { + label: "工器具编码", + prop: "toolsCodeId", + display: false, + search:true, + span:8, + type: "select", + dicUrl: "/api/leger/toolinventoryrecord/getToolsCodeIdList", + props: { + label: "toolsCodeId", + value: "toolsCodeId", + }, + event: { + change: (val) => { + if (!val) return + if (val) { + request({ + url: '/api/leger/toolinventoryrecord/getDetailList', + method: 'get', + params: { + toolsCodeId: val + } + }).then((res) => { + this.form.station = res.data.data.stations; + }) + } + }, + }, }, ] }, @@ -172,6 +249,8 @@ export default { this.addUpdateShowButton = false; this.shouldShowButton=true; this.frame_class = 'frame_class'; + const station = this.findObject(this.option.column, "station"); + station.disabled = false; }else{ const objectNo = this.findObject(this.option.column, "objectNo"); objectNo.value = ' '; @@ -276,7 +355,6 @@ export default { this.form = res.data.data; }); } - done(); }, } }; diff --git a/src/views/leger/toolinventoryrecordDetail.vue b/src/views/leger/toolinventoryrecordDetail.vue index 605e545..c6401ef 100644 --- a/src/views/leger/toolinventoryrecordDetail.vue +++ b/src/views/leger/toolinventoryrecordDetail.vue @@ -674,6 +674,7 @@ export default { cancelButtonText: "取消", type: "warning" }).then(() => { + this.tab1_form.checkStatus="1" update(this.tab1_form).then(() => { this.$router.push({ path: "/leger/toolinventoryrecord", diff --git a/src/views/smart/workpermitDetail.vue b/src/views/smart/workpermitDetail.vue index c7d3666..98099ea 100644 --- a/src/views/smart/workpermitDetail.vue +++ b/src/views/smart/workpermitDetail.vue @@ -592,6 +592,7 @@ cancelButtonText: "取消", type: "warning" }).then(() => { + this.tab1_form.checkStatus="1" update(this.tab1_form).then(() => { this.$router.push({ path: "/smart/workpermit", @@ -629,7 +630,7 @@ this.readonlyForm=true; this.shouldShowButton=true; this.addUpdateShowButton=false; - this.UpdateShowButton=false; + this.UpdateShowButton=true; this.frame_class = 'frame_class1'; }, handleChange (column) { @@ -637,6 +638,8 @@ if (column.prop == 'attachment') { this.UpdateShowButton=false; this.attachment_onLoad(); + }if (column.prop == 'information'){ + this.UpdateShowButton=true; } this.attachment_form.ticketCode = this.tab1_form.workTicketNo; },