|
@@ -38,22 +38,23 @@
|
|
|
<el-option v-for="(item, index) in rmList" :label="item.name" :value="item.id" />
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
- <el-form-item prop="misMes" :label-class="{ 'my-red-label': true }">
|
|
|
+ <el-form-item prop="misMes">
|
|
|
<template #label>
|
|
|
- <span style="color: red;">任务说明</span>
|
|
|
+ <span>任务说明</span>
|
|
|
</template>
|
|
|
<el-input style="width: 1136px;" v-model="newMission.misMes"></el-input>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="SCD文件">
|
|
|
+ <div style="width:100%;text-align: left;">{{ scdName }}</div>
|
|
|
<el-upload ref="upload" class="upload-demo" :http-request="nowUpload" :limit="2"
|
|
|
element-loading-text="上传中..." element-loading-background="rgba(255, 255, 255, 0.8)"
|
|
|
:show-file-list="false">
|
|
|
<template #trigger>
|
|
|
<el-button style="border-bottom: 1px solid #7BBAFD;width: calc(100vw - 1000px);"
|
|
|
- type="primary" plain>点击选择scd文件</el-button>
|
|
|
+ type="primary" plain>选择SCD文件</el-button>
|
|
|
</template>
|
|
|
</el-upload>
|
|
|
- <span v-loading="scdLoading">{{ scdLoading ? '正在进行间隔装置分析' : '分析完成' }}
|
|
|
+ <span style="margin-left: 10px;" v-loading="scdLoading">{{ scdLoading ? ' 正在进行SCD间隔装置分析' : ' SCD分析已完成' }}
|
|
|
</span>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
@@ -70,7 +71,7 @@
|
|
|
<div>
|
|
|
<img src="../../../assets/icon/DotsNine.png" alt="">
|
|
|
</div>
|
|
|
- <div>
|
|
|
+ <div style="height: 24px;line-height: 22px;margin-left: 5px;">
|
|
|
<span>间隔列表</span>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -86,30 +87,29 @@
|
|
|
<div>
|
|
|
<img src="../../../assets/icon/HardDrives.png" alt="">
|
|
|
</div>
|
|
|
- <div style="margin-left: 5px;">
|
|
|
+ <div style="height: 24px;line-height: 22px;margin-left: 5px;">
|
|
|
<span>装置列表——间隔:<em>{{ jg }}</em></span>
|
|
|
<span>检测模型:<em>{{ flashLevel ? flashLevel + '线路保护模型' : '' }}</em></span>
|
|
|
</div>
|
|
|
- <div
|
|
|
- style="position: absolute;top: 0px;right: 0px;display: flex;justify-content: center;align-items: center;">
|
|
|
-
|
|
|
+ <div style="position: absolute;top: 0px;right: 0px;display: flex;justify-content: center;align-items: center;">
|
|
|
+ <!--
|
|
|
<div style="margin: 0 10px;">
|
|
|
<el-checkbox label="开启检测" size="large" />
|
|
|
</div>
|
|
|
- <div>
|
|
|
+ -->
|
|
|
+ <div style="margin: 5px;">
|
|
|
<el-button type="primary" size="small" plain @click="checkTime">选择装置</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
|
-
|
|
|
</div>
|
|
|
- <div v-loading="iedLoading">
|
|
|
+ <div v-loading="iedLoading" style="margin: 10px;float: left;">
|
|
|
<!-- <div v-for="(item, index) in mx">
|
|
|
{{ item.ied_name }}
|
|
|
</div> -->
|
|
|
<el-tag v-for="(item, index) in mx" :key="item.ied_name" @click="tagClick(item, index)" size="large"
|
|
|
- :class="item.isChoose ? 'mx-2' : 'mx-1'" type="info" :closable="item.isChoose" effect="plain"
|
|
|
- @close="tagClose(item, index)">
|
|
|
- {{ item.ied_name }}
|
|
|
+ :class="item.isChoose ? 'mx-2' : 'mx-1'" closable="true" effect="plain"
|
|
|
+ @close="tagClose(item)">
|
|
|
+ {{ '['+item.ied_name+']'+(item.attr_desc||'') }}
|
|
|
</el-tag>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -122,7 +122,7 @@
|
|
|
<!-- 模态框组件 -->
|
|
|
<div>
|
|
|
<LookScd v-if="scdLooks" :scdLooks="scdLooks" @nowBack="nowBack" @lookNum="lookNum"></LookScd>
|
|
|
- <ModelTree v-if="treeMool" :treeMool="treeMool" :treeNeed="treeNeed" @treeBack="treeBack" @treeNum="treeNum">
|
|
|
+ <ModelTree v-if="treeMool" :treeMool="treeMool" :treeNeed="treeNeed" :checkedNodeNames="checkedNodeNames" @treeBack="treeBack" @treeNum="treeNum">
|
|
|
</ModelTree>
|
|
|
<FlashCreate v-if="fcModal" :fcModal="fcModal" @fcBack="fcBack"></FlashCreate>
|
|
|
<CheckIed v-if="iedModal" :iedModal="iedModal" :loadScdId="loadScdId" @iedBack="iedBack"
|
|
@@ -142,7 +142,7 @@ import LookScd from '../modalComp/LookScd.vue';
|
|
|
import ModelTree from '../modalComp/ModelTree.vue';
|
|
|
import FlashCreate from '../modalComp/FlashCreate.vue';
|
|
|
import CheckIed from '../modalComp/CheckIed.vue';
|
|
|
-import { ElMessage, ElLoading } from 'element-plus';
|
|
|
+import { ElMessage,ElMessageBox, ElLoading } from 'element-plus';
|
|
|
export default {
|
|
|
props: {
|
|
|
btnSelect: {
|
|
@@ -221,6 +221,7 @@ export default {
|
|
|
id: "area_id",
|
|
|
})
|
|
|
let treeNeed = ref([])//modelTree.vue需要的回显数据
|
|
|
+ let checkedNodeNames = ref([])
|
|
|
let anyData = ref([])
|
|
|
let states = ref(0)
|
|
|
let flashLevel = ref("")
|
|
@@ -244,17 +245,32 @@ export default {
|
|
|
if (props.editRow.name) {
|
|
|
needEdit.value = props.editRow
|
|
|
newMission.value.misName = needEdit.value.name//任务名称
|
|
|
- newMission.value.misNum = needEdit.value.id//任务id
|
|
|
+ newMission.value.misNum = needEdit.value.code//任务id
|
|
|
newMission.value.flashId = needEdit.value.station_id//变电站id
|
|
|
newMission.value.misMes = needEdit.value.memo//备注或描述
|
|
|
newMission.value.reportNow = needEdit.value.report_id//报告模板
|
|
|
loadScdId.value = needEdit.value.scd_id//scdid
|
|
|
task.getTaskById({ id: needEdit.value.id - 0 }).then(res => {
|
|
|
if (res.data != null) {
|
|
|
+ let modelnames = res.data.models.map((item, index) => {
|
|
|
+ return item.model_name
|
|
|
+ })
|
|
|
let arr = res.data.models.map((item, index) => {
|
|
|
- return item.id
|
|
|
+ return item.sys_model_id
|
|
|
})
|
|
|
+ cmodel.value = modelnames.join(',')
|
|
|
mxId.value = arr
|
|
|
+ treeNeed.value = arr
|
|
|
+ checkedNodeNames.value = modelnames
|
|
|
+ loadScdId.value = res.data.scd_id
|
|
|
+ scdName.value = res.data.scd_info.scd_name
|
|
|
+ successScd.value = true
|
|
|
+ scd.getLoadScd({ scd_id: res.data.scd_id*1 }).then(res => {
|
|
|
+ if (res.code == 0) {
|
|
|
+ successScd.value = true
|
|
|
+ anyData.value = res.data
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
})
|
|
|
} else {
|
|
@@ -276,7 +292,6 @@ export default {
|
|
|
value: item.id
|
|
|
}
|
|
|
})
|
|
|
- console.log(flashList.value, 'flash');
|
|
|
}
|
|
|
})
|
|
|
})
|
|
@@ -347,6 +362,9 @@ export default {
|
|
|
|
|
|
}
|
|
|
function nowUpload(e) {
|
|
|
+ if( scdLoading.value ){
|
|
|
+ return
|
|
|
+ }
|
|
|
const loading = ElLoading.service({
|
|
|
lock: true,
|
|
|
text: '文件上传中',
|
|
@@ -357,6 +375,7 @@ export default {
|
|
|
if (res.code == 0) {
|
|
|
loading.close()
|
|
|
}
|
|
|
+ scdName.value = res.data.filename
|
|
|
scd.loadScd({ station_id: newMission.value.flashId - 0, scd_path: res.data.path, scd_name: res.data.filename }).then(the => {
|
|
|
// scd.getLoadScd({ scd_id: the.data - 0 }).then(lod => {
|
|
|
// console.log(lod,'rsasdas');
|
|
@@ -390,7 +409,7 @@ export default {
|
|
|
if (res.code == 0) {
|
|
|
ElMessage({
|
|
|
type: "success",
|
|
|
- message: "添加ied成功!",
|
|
|
+ message: "间隔装置设置保存成功!",
|
|
|
duration: 1500,
|
|
|
})
|
|
|
emit("createBack", 0)
|
|
@@ -398,14 +417,16 @@ export default {
|
|
|
ElMessage({
|
|
|
type: "error",
|
|
|
message: res.msg,
|
|
|
- duration: 1500,
|
|
|
+ duration: 3000,
|
|
|
})
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
function tagClose(row, num) {
|
|
|
- mx.value.splice(mx.value.indexOf(row), 1)
|
|
|
- iedName.value = mx.value.map(item => item.ied_name).join(',');
|
|
|
+ ElMessageBox.confirm('确认从该间隔移除当前装置'+row.ied_name+'吗?','删除装置').then(() => {
|
|
|
+ mx.value.splice(mx.value.indexOf(row), 1)
|
|
|
+ iedName.value = mx.value.map(item => item.ied_name).join(',');
|
|
|
+ }).catch(() => {})
|
|
|
}
|
|
|
function tagClick(row, num) {
|
|
|
// 将所有对象的 isChoose 属性设置为 false
|
|
@@ -449,6 +470,17 @@ export default {
|
|
|
iedModal.value = data
|
|
|
}
|
|
|
function iedArrBack(data) {
|
|
|
+ for(let i=0; i<data.length; i++){
|
|
|
+ let obj = mx.value.filter(item => item.ied_name==data[i].ied_name)
|
|
|
+ if( obj != null && obj.length > 0){
|
|
|
+ ElMessage({
|
|
|
+ type: "info",
|
|
|
+ message: data[i].ied_name+":该装置已存在!",
|
|
|
+ duration: 3000,
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
mx.value = mx.value.concat(data)
|
|
|
iedName.value = mx.value.map(item => item.ied_name).join(',');
|
|
|
}
|
|
@@ -512,6 +544,7 @@ export default {
|
|
|
iedLoading,
|
|
|
needEdit,//需要编辑的任务
|
|
|
treeNeed,//modelTree.vue需要的回显id
|
|
|
+ checkedNodeNames,
|
|
|
states,
|
|
|
myForm,//表单ref
|
|
|
resetForm,
|
|
@@ -545,7 +578,7 @@ em {
|
|
|
|
|
|
.formBox {
|
|
|
width: 1136px;
|
|
|
- height: 339px;
|
|
|
+ height: 360px;
|
|
|
margin: 0 auto;
|
|
|
/* border-bottom: 1px dashed #dbdbdb; */
|
|
|
}
|
|
@@ -568,14 +601,14 @@ em {
|
|
|
|
|
|
.gapBox {
|
|
|
width: 288px;
|
|
|
- height: calc(100vh - 600px);
|
|
|
+ height: calc(100vh - 640px);
|
|
|
overflow-y: auto;
|
|
|
border: 1px solid #5779D7;
|
|
|
}
|
|
|
|
|
|
.unitBox {
|
|
|
width: 832px;
|
|
|
- height: calc(100vh - 600px);
|
|
|
+ height: calc(100vh - 640px);
|
|
|
overflow-y: auto;
|
|
|
border: 1px solid #5779D7;
|
|
|
position: relative;
|
|
@@ -595,19 +628,23 @@ em {
|
|
|
}
|
|
|
|
|
|
.mx-1 {
|
|
|
- width: 100px;
|
|
|
+ float: left;
|
|
|
+ min-width: 100px;
|
|
|
height: 30px;
|
|
|
margin-right: 10px;
|
|
|
margin-top: 5px;
|
|
|
+ margin-bottom: 5px;
|
|
|
border: 1px solid #5779D7;
|
|
|
color: black;
|
|
|
}
|
|
|
|
|
|
.mx-2 {
|
|
|
- width: 100px;
|
|
|
+ float: left;
|
|
|
+ min-width: 100px;
|
|
|
height: 30px;
|
|
|
margin-right: 10px;
|
|
|
margin-top: 5px;
|
|
|
+ margin-bottom: 5px;
|
|
|
border: 1px solid #5779D7;
|
|
|
background-color: rgba(89, 120, 213, 0.3);
|
|
|
color: #5779D7;
|
|
@@ -631,7 +668,6 @@ em {
|
|
|
|
|
|
:deep(.el-tag--large .el-tag__close) {
|
|
|
margin-left: 25px;
|
|
|
- pointer-events: none;
|
|
|
}
|
|
|
|
|
|
:deep(.el-icon svg) {
|