diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/CrowdnessIndicatorRankings/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/CrowdnessIndicatorRankings/index.vue index a7cfaef2..0314e34e 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/CrowdnessIndicatorRankings/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/CrowdnessIndicatorRankings/index.vue @@ -287,7 +287,6 @@ export default { } const self = this; setTimeout(() => { - console.log(self.detailData,'---------------') // 获取map接口 const { AMap, mapIns } = self.$refs.AMapContainerRef.getMapInstance(); const { longitude, dimension, eventName } = self.detailData; diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/components/ScopeTable.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/components/ScopeTable.vue index 9b84a6b8..e08e17b1 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/components/ScopeTable.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/components/ScopeTable.vue @@ -4,11 +4,10 @@ + style="width: 123px;"> - @@ -30,8 +29,31 @@ style="width: 75px;"> 公里 + + + + + + + + + + + + + + 新增 + + + 删除 + + + - + + + @@ -62,12 +84,6 @@ - - - - - @@ -113,7 +129,28 @@ - + + + + {{ itm.deviceName }} + + {{ itm.content }} + + + + + + + + + + + + + + + + 恢复: @@ -125,12 +162,6 @@ - - - - - @@ -166,17 +197,18 @@ - - + + + + {{ item.deviceName }} + {{ item.content }} + + + @@ -309,12 +341,9 @@ export default { } }, async mounted() { - // this.loadData(2); }, methods: { - initData() { - - }, + initData() { }, async loadData(deviceType = 1) { this.sbOptions = []; let result = await request({ @@ -347,14 +376,30 @@ export default { this.isShowDialog = false; }, dialogSubmit(data) { - console.log('qbbData', data) this.tableInfo[this.clickQbbName] = data.content; // this.tableData[this.index].otherConfig = JSON.stringify(data); - } + }, } } + \ No newline at end of file diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/data.js b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/data.js index 775abffd..3f2b1835 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/data.js +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/data.js @@ -4,6 +4,7 @@ export const defaultTableInfo = { deviceType: 2, searchRule: 1, number: 0, + isDefault: true // zx_operationType: 2, // hf_operationType: 2, }; diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/index.vue index 83aa5bd4..5e5b1f86 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DeviceControl/index.vue @@ -7,6 +7,8 @@ :index="index" @onAdd="onAdd" @onDel="onDel" + @onConfirm="onConfirm" + @onContentEdit="onContentEdit" > @@ -59,7 +61,6 @@ export default { this.initData(this.detailData); }, initData(eventInfo) { - console.log("eventInfo", eventInfo); request({ url: `business/plans/list/event/type`, method: "post", @@ -120,6 +121,51 @@ export default { } this.tableData.splice(index, 1); }, + onConfirm(index){ + const param = { + "dcEvent": { + "eventType": this.detailData.eventType, + "direction": this.detailData.direction, + "id": this.detailData.id, + "stakeMark": this.detailData.stakeMark, + "subclass": this.detailData.subclass + }, + "dcExecuteAction": { + "id": "", + "emergencyPlansId": "", + "deviceType": this.tableData[index].deviceType, + "searchRule": this.tableData[index].searchRule, + "number": this.tableData[index].number, + "deviceList": this.tableData[index].devList.join(','), + "executeConfig": "{\"operationType\":2}", + "recoverConfig": "{\"operationType\":2}" + } + } + request({ + url: `business/plans/list/event/emergencyPlans`, + method: "post", + data: param, + }).then(result=>{ + if (result.code != 200) return Message.error(result?.msg); + let data = result.data; + this.tableData[index].executeConfig = JSON.parse(data.executeConfig) + this.tableData[index].recoverConfig = JSON.parse(data.recoverConfig) + this.tableData[index].zx_operationType = this.tableData[index].executeConfig?.operationType; + this.tableData[index].hf_operationType = this.tableData[index].recoverConfig?.operationType; + this.tableData = _.cloneDeep(this.tableData) + }) + }, + onContentEdit({field,index,idx,type}){ + if(type==='edit'){ + this.tableData[index][field]['contentList'][idx]['isEditor'] = this.tableData[index][field]['contentList'][idx].content; + } else if(type === 'cancel'){ + this.tableData[index][field]['contentList'][idx]['content'] = this.tableData[index][field]['contentList'][idx].isEditor; + delete this.tableData[index][field]['contentList'][idx].isEditor + } else if(type === 'confirm'){ + delete this.tableData[index][field]['contentList'][idx].isEditor + } + this.tableData = _.cloneDeep(this.tableData) + }, handleSubmit(value = 1) { let dcArr = []; this.tableData.forEach((item) => { diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/index.vue index 0ca7df3e..45497256 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/index.vue @@ -63,8 +63,14 @@ export default { let h = window.location.href.split("="); if (h.length === 2) { this.detailId = window.location.href.split("=")[1]; + localStorage.setItem('commandDispatch',this.detailId) } else { - this.detailId = "b825c7bbf4de43cdb8f689e270adf7a1"; + let id = localStorage.getItem('commandDispatch') + if(id && id !== ''){ + this.detailId = id; + } else { + this.detailId = "b825c7bbf4de43cdb8f689e270adf7a1"; + } } this.getDetail(); }, diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/manage/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/manage/index.vue index a950e12d..9a312ff6 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/manage/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/manage/index.vue @@ -342,7 +342,6 @@ export default { }, /** 修改按钮操作 */ handleUpdate(row) { - console.log(row,'-------------------') this.formData = row; this.modelVisible = true; },
恢复: