|
@@ -6,7 +6,7 @@
|
|
|
<a-row :gutter="24">
|
|
|
<a-col :xl="6" :lg="7" :md="8" :sm="24">
|
|
|
<a-form-item label="联锁名称">
|
|
|
- <a-input placeholder="请输入联锁名称" v-model="queryParam.interlockName"></a-input>
|
|
|
+ <a-input placeholder="请输入联锁名称" v-model="queryParam.interlockname"></a-input>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
<a-col :xl="6" :lg="7" :md="8" :sm="24">
|
|
@@ -127,6 +127,7 @@
|
|
|
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
|
|
import InterlockSummaryModal from './modules/InterlockSummaryModal'
|
|
|
import {filterMultiDictText} from '@/components/dict/JDictSelectUtil'
|
|
|
+ import { httpAction, getAction } from '@/api/manage'
|
|
|
|
|
|
export default {
|
|
|
name: 'InterlockSummaryList',
|
|
@@ -152,48 +153,77 @@
|
|
|
{
|
|
|
title:'联锁名称',
|
|
|
align:"center",
|
|
|
- dataIndex: 'interlockName'
|
|
|
+ dataIndex: 'interlockname',
|
|
|
+ customRender:function (t,r,index) {
|
|
|
+ return {children: t,attrs: {rowSpan:r.rowSpan}};
|
|
|
+ },
|
|
|
},
|
|
|
{
|
|
|
- title:'系统id',
|
|
|
+ title:'联锁条件',
|
|
|
align:"center",
|
|
|
- dataIndex: 'interlockSystemId'
|
|
|
+ dataIndex: 'interlockConditionTag'
|
|
|
},
|
|
|
{
|
|
|
- title:'装置id',
|
|
|
+ title:'仪表状态',
|
|
|
align:"center",
|
|
|
- dataIndex: 'interlockApparatusId'
|
|
|
+ dataIndex: 'instrumentStatus_dictText'
|
|
|
},
|
|
|
+ // {
|
|
|
+ // title:'系统id',
|
|
|
+ // align:"center",
|
|
|
+ // dataIndex: 'interlockSystemId'
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // title:'装置id',
|
|
|
+ // align:"center",
|
|
|
+ // dataIndex: 'interlockApparatusId'
|
|
|
+ // },
|
|
|
{
|
|
|
title:'联锁状态',
|
|
|
align:"center",
|
|
|
- dataIndex: 'interlockStatus'
|
|
|
- },
|
|
|
- {
|
|
|
- title:'回路健康级别',
|
|
|
- align:"center",
|
|
|
- dataIndex: 'loopHealthLevel'
|
|
|
- },
|
|
|
- {
|
|
|
- title:'逻辑关系',
|
|
|
- align:"center",
|
|
|
- dataIndex: 'ljgx'
|
|
|
+ dataIndex: 'interlockStatus_dictText',
|
|
|
+ customRender:function (t,r,index) {
|
|
|
+ return {children: t,attrs: {rowSpan:r.rowSpan2}};
|
|
|
+ },
|
|
|
},
|
|
|
{
|
|
|
- title:'联锁输出值',
|
|
|
+ title:'控制系统状态',
|
|
|
align:"center",
|
|
|
- dataIndex: 'interlockOutValue'
|
|
|
+ dataIndex: 'controlSystemStatus_dictText',
|
|
|
},
|
|
|
{
|
|
|
- title:'联锁输出值点位',
|
|
|
+ title:'回路健康级别',
|
|
|
align:"center",
|
|
|
- dataIndex: 'interlockOutValueTag'
|
|
|
+ dataIndex: 'loopHealthLevel',
|
|
|
+ customRender:function (t,r,index) {
|
|
|
+ return {children: t,attrs: {rowSpan:r.rowSpan3}};
|
|
|
+ },
|
|
|
},
|
|
|
{
|
|
|
- title:'备注',
|
|
|
+ title:'旁路状态',
|
|
|
align:"center",
|
|
|
- dataIndex: 'remark'
|
|
|
+ dataIndex: 'bypass_dictText',
|
|
|
},
|
|
|
+ // {
|
|
|
+ // title:'逻辑关系',
|
|
|
+ // align:"center",
|
|
|
+ // dataIndex: 'ljgx'
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // title:'联锁输出值',
|
|
|
+ // align:"center",
|
|
|
+ // dataIndex: 'interlockOutValue'
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // title:'联锁输出值点位',
|
|
|
+ // align:"center",
|
|
|
+ // dataIndex: 'interlockOutValueTag'
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // title:'备注',
|
|
|
+ // align:"center",
|
|
|
+ // dataIndex: 'remark'
|
|
|
+ // },
|
|
|
{
|
|
|
title: '操作',
|
|
|
dataIndex: 'action',
|
|
@@ -204,7 +234,7 @@
|
|
|
}
|
|
|
],
|
|
|
url: {
|
|
|
- list: "/summary/interlockSummary/list",
|
|
|
+ list: "/detail/interlockDetail/list1",
|
|
|
delete: "/summary/interlockSummary/delete",
|
|
|
deleteBatch: "/summary/interlockSummary/deleteBatch",
|
|
|
exportXlsUrl: "/summary/interlockSummary/exportXls",
|
|
@@ -224,11 +254,134 @@
|
|
|
},
|
|
|
},
|
|
|
methods: {
|
|
|
+ loadData(arg) {
|
|
|
+ let that = this
|
|
|
+ if(!this.url.list){
|
|
|
+ this.$message.error("请设置url.list属性!")
|
|
|
+ return
|
|
|
+ }
|
|
|
+ //加载数据 若传入参数1则加载第一页的内容
|
|
|
+ if (arg === 1) {
|
|
|
+ this.ipagination.current = 1;
|
|
|
+ }
|
|
|
+ var params = this.getQueryParams();//查询条件
|
|
|
+ this.loading = true;
|
|
|
+ getAction(this.url.list, params).then((res) => {
|
|
|
+ if (res.success) {
|
|
|
+ //update-begin---author:zhangyafei Date:20201118 for:适配不分页的数据列表------------
|
|
|
+ this.dataSource = res.result.records||res.result;
|
|
|
+
|
|
|
+ // 合并单元格
|
|
|
+ //判断跨行
|
|
|
+ let rowSpan = 0
|
|
|
+ let rowSpan2 = 0
|
|
|
+ let rowSpan3 = 0
|
|
|
+ let interlockname = ''
|
|
|
+ let interlocknamePD = ''
|
|
|
+ let interlockStatus = ''
|
|
|
+ let loopHealthLevel = ''
|
|
|
+ for (let i = that.dataSource.length-1; i >= 0; i--) {
|
|
|
+ // 联锁名称合并
|
|
|
+ if (interlockname == '') {
|
|
|
+ that.dataSource[i].rowSpan = 0
|
|
|
+ interlockname = that.dataSource[i].interlockname
|
|
|
+ rowSpan++
|
|
|
+ } else {
|
|
|
+ if(interlockname == that.dataSource[i].interlockname){
|
|
|
+ that.dataSource[i].rowSpan = 0
|
|
|
+ rowSpan++
|
|
|
+ }else{
|
|
|
+ that.dataSource[i+1].rowSpan = rowSpan
|
|
|
+ that.dataSource[i].rowSpan = 0
|
|
|
+ rowSpan = 1
|
|
|
+ interlockname = that.dataSource[i].interlockname
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 联锁状态合并
|
|
|
+ if (interlockStatus == '') {
|
|
|
+ that.dataSource[i].rowSpan2 = 0
|
|
|
+ interlockStatus = that.dataSource[i].interlockStatus
|
|
|
+ interlocknamePD = that.dataSource[i].interlockname
|
|
|
+ rowSpan2++
|
|
|
+ } else {
|
|
|
+ if(interlockStatus == that.dataSource[i].interlockStatus){
|
|
|
+ // that.dataSource[i].rowSpan2 = 0
|
|
|
+ // rowSpan2++
|
|
|
+ if (interlocknamePD == that.dataSource[i].interlockname) {
|
|
|
+ that.dataSource[i].rowSpan2 = 0
|
|
|
+ rowSpan2++
|
|
|
+ } else {
|
|
|
+ that.dataSource[i+1].rowSpan2 = rowSpan2
|
|
|
+ that.dataSource[i].rowSpan2 = 0
|
|
|
+ rowSpan2 = 1
|
|
|
+ interlockStatus = that.dataSource[i].interlockStatus
|
|
|
+ interlocknamePD = that.dataSource[i].interlockname
|
|
|
+ }
|
|
|
+ }else{
|
|
|
+ that.dataSource[i+1].rowSpan2 = rowSpan2
|
|
|
+ that.dataSource[i].rowSpan2 = 0
|
|
|
+ rowSpan2 = 1
|
|
|
+ interlockStatus = that.dataSource[i].interlockStatus
|
|
|
+ interlocknamePD = that.dataSource[i].interlockname
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+ // 回路健康级别合并
|
|
|
+ if (loopHealthLevel == '') {
|
|
|
+ that.dataSource[i].rowSpan3 = 0
|
|
|
+ loopHealthLevel = that.dataSource[i].loopHealthLevel
|
|
|
+ interlocknamePD = that.dataSource[i].interlockname
|
|
|
+ rowSpan3++
|
|
|
+ } else {
|
|
|
+ if(loopHealthLevel == that.dataSource[i].loopHealthLevel){
|
|
|
+ console.log(99,i,interlocknamePD,that.dataSource[i+1].interlockname)
|
|
|
+ if (interlocknamePD == that.dataSource[i+1].interlockname) {
|
|
|
+ console.log(11111)
|
|
|
+ that.dataSource[i].rowSpan3 = 0
|
|
|
+ rowSpan3++
|
|
|
+ } else {
|
|
|
+ console.log(22222)
|
|
|
+ that.dataSource[i+1].rowSpan3 = rowSpan3
|
|
|
+ that.dataSource[i].rowSpan3 = 0
|
|
|
+ rowSpan3 = 1
|
|
|
+ loopHealthLevel = that.dataSource[i].loopHealthLevel
|
|
|
+ interlocknamePD = that.dataSource[i].interlockname
|
|
|
+ }
|
|
|
+ }else{
|
|
|
+ that.dataSource[i+1].rowSpan3 = rowSpan3
|
|
|
+ that.dataSource[i].rowSpan3 = 0
|
|
|
+ rowSpan3 = 1
|
|
|
+ loopHealthLevel = that.dataSource[i].loopHealthLevel
|
|
|
+ interlocknamePD = that.dataSource[i].interlockname
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+ }
|
|
|
+ that.dataSource[0].rowSpan = rowSpan
|
|
|
+ that.dataSource[0].rowSpan2 = rowSpan2
|
|
|
+ that.dataSource[0].rowSpan3 = rowSpan3
|
|
|
+ console.log(22222222222,that.dataSource)
|
|
|
+
|
|
|
+
|
|
|
+ if(res.result.total)
|
|
|
+ {
|
|
|
+ this.ipagination.total = res.result.total;
|
|
|
+ }else{
|
|
|
+ this.ipagination.total = 0;
|
|
|
+ }
|
|
|
+ //update-end---author:zhangyafei Date:20201118 for:适配不分页的数据列表------------
|
|
|
+ }else{
|
|
|
+ this.$message.warning(res.message)
|
|
|
+ }
|
|
|
+ }).finally(() => {
|
|
|
+ this.loading = false
|
|
|
+ })
|
|
|
+ },
|
|
|
initDictConfig(){
|
|
|
},
|
|
|
getSuperFieldList(){
|
|
|
let fieldList=[];
|
|
|
- fieldList.push({type:'string',value:'interlockName',text:'联锁名称',dictCode:''})
|
|
|
+ fieldList.push({type:'string',value:'interlockname',text:'联锁名称',dictCode:''})
|
|
|
fieldList.push({type:'string',value:'interlockSystemId',text:'系统id',dictCode:''})
|
|
|
fieldList.push({type:'string',value:'interlockApparatusId',text:'装置id',dictCode:''})
|
|
|
fieldList.push({type:'string',value:'interlockStatus',text:'联锁状态',dictCode:'interlock_status'})
|