diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/views/home/pipeline/components/detail.vue b/src/views/home/pipeline/components/detail.vue index 106d488..b68eb45 100644 --- a/src/views/home/pipeline/components/detail.vue +++ b/src/views/home/pipeline/components/detail.vue @@ -106,7 +106,7 @@ // align: 'center', // }, { - text: '设备使用状态', + text: '设备在用状态', value: 'onState', align: 'center', }, diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/views/home/pipeline/components/detail.vue b/src/views/home/pipeline/components/detail.vue index 106d488..b68eb45 100644 --- a/src/views/home/pipeline/components/detail.vue +++ b/src/views/home/pipeline/components/detail.vue @@ -106,7 +106,7 @@ // align: 'center', // }, { - text: '设备使用状态', + text: '设备在用状态', value: 'onState', align: 'center', }, diff --git a/src/views/home/pipeline/components/detailInfoDialog.vue b/src/views/home/pipeline/components/detailInfoDialog.vue index ffe9f93..b9b9421 100644 --- a/src/views/home/pipeline/components/detailInfoDialog.vue +++ b/src/views/home/pipeline/components/detailInfoDialog.vue @@ -6,14 +6,15 @@ - { }"> + {}" + > - + - {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + - + 详情 @@ -219,22 +261,102 @@ - - + + {{ item.text }} - + {{ detailInfo[item.value] || '' }} + + + {{ detailInfo[item.value] || '' }} + + + + {{ detailInfo[item.value] || '' }} + - + + - {{ item.text }} : - {{ item.name.includes('燃气') || item.name.includes('哨兵') ? item.value - : item.stateName }} - {{ item.unit - }} - + {{ item.name }} : + + {{ + item.name.includes('燃气') || item.name.includes('哨兵') || item.name.includes('智能警示桩') + ? item.value + : item.stateName + }} + + {{ item.unit }} + 更多 @@ -301,7 +423,9 @@ flex-wrap: wrap; box-sizing: border-box; padding: 6px 0; - + .last-value { + width: 100% !important; + } .descriptions-item { width: 48%; margin: 4px 5px; @@ -312,7 +436,9 @@ .label-no { width: 28% !important; } - + .last-label { + width: 16% !important; + } .label { width: 34%; box-sizing: border-box; diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/views/home/pipeline/components/detail.vue b/src/views/home/pipeline/components/detail.vue index 106d488..b68eb45 100644 --- a/src/views/home/pipeline/components/detail.vue +++ b/src/views/home/pipeline/components/detail.vue @@ -106,7 +106,7 @@ // align: 'center', // }, { - text: '设备使用状态', + text: '设备在用状态', value: 'onState', align: 'center', }, diff --git a/src/views/home/pipeline/components/detailInfoDialog.vue b/src/views/home/pipeline/components/detailInfoDialog.vue index ffe9f93..b9b9421 100644 --- a/src/views/home/pipeline/components/detailInfoDialog.vue +++ b/src/views/home/pipeline/components/detailInfoDialog.vue @@ -6,14 +6,15 @@ - { }"> + {}" + > - + - {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + - + 详情 @@ -219,22 +261,102 @@ - - + + {{ item.text }} - + {{ detailInfo[item.value] || '' }} + + + {{ detailInfo[item.value] || '' }} + + + + {{ detailInfo[item.value] || '' }} + - + + - {{ item.text }} : - {{ item.name.includes('燃气') || item.name.includes('哨兵') ? item.value - : item.stateName }} - {{ item.unit - }} - + {{ item.name }} : + + {{ + item.name.includes('燃气') || item.name.includes('哨兵') || item.name.includes('智能警示桩') + ? item.value + : item.stateName + }} + + {{ item.unit }} + 更多 @@ -301,7 +423,9 @@ flex-wrap: wrap; box-sizing: border-box; padding: 6px 0; - + .last-value { + width: 100% !important; + } .descriptions-item { width: 48%; margin: 4px 5px; @@ -312,7 +436,9 @@ .label-no { width: 28% !important; } - + .last-label { + width: 16% !important; + } .label { width: 34%; box-sizing: border-box; diff --git a/src/views/home/pipeline/components/gasDataDialog.vue b/src/views/home/pipeline/components/gasDataDialog.vue new file mode 100644 index 0000000..fa91c9e --- /dev/null +++ b/src/views/home/pipeline/components/gasDataDialog.vue @@ -0,0 +1,312 @@ + + + + + + + + + 采集时间: + + 上传时间: + + + 搜索 + + + + + + + + + + + + diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/views/home/pipeline/components/detail.vue b/src/views/home/pipeline/components/detail.vue index 106d488..b68eb45 100644 --- a/src/views/home/pipeline/components/detail.vue +++ b/src/views/home/pipeline/components/detail.vue @@ -106,7 +106,7 @@ // align: 'center', // }, { - text: '设备使用状态', + text: '设备在用状态', value: 'onState', align: 'center', }, diff --git a/src/views/home/pipeline/components/detailInfoDialog.vue b/src/views/home/pipeline/components/detailInfoDialog.vue index ffe9f93..b9b9421 100644 --- a/src/views/home/pipeline/components/detailInfoDialog.vue +++ b/src/views/home/pipeline/components/detailInfoDialog.vue @@ -6,14 +6,15 @@ - { }"> + {}" + > - + - {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + - + 详情 @@ -219,22 +261,102 @@ - - + + {{ item.text }} - + {{ detailInfo[item.value] || '' }} + + + {{ detailInfo[item.value] || '' }} + + + + {{ detailInfo[item.value] || '' }} + - + + - {{ item.text }} : - {{ item.name.includes('燃气') || item.name.includes('哨兵') ? item.value - : item.stateName }} - {{ item.unit - }} - + {{ item.name }} : + + {{ + item.name.includes('燃气') || item.name.includes('哨兵') || item.name.includes('智能警示桩') + ? item.value + : item.stateName + }} + + {{ item.unit }} + 更多 @@ -301,7 +423,9 @@ flex-wrap: wrap; box-sizing: border-box; padding: 6px 0; - + .last-value { + width: 100% !important; + } .descriptions-item { width: 48%; margin: 4px 5px; @@ -312,7 +436,9 @@ .label-no { width: 28% !important; } - + .last-label { + width: 16% !important; + } .label { width: 34%; box-sizing: border-box; diff --git a/src/views/home/pipeline/components/gasDataDialog.vue b/src/views/home/pipeline/components/gasDataDialog.vue new file mode 100644 index 0000000..fa91c9e --- /dev/null +++ b/src/views/home/pipeline/components/gasDataDialog.vue @@ -0,0 +1,312 @@ + + + + + + + + + 采集时间: + + 上传时间: + + + 搜索 + + + + + + + + + + + + diff --git a/src/views/home/pipeline/components/map.vue b/src/views/home/pipeline/components/map.vue index 6e04960..d1cda40 100644 --- a/src/views/home/pipeline/components/map.vue +++ b/src/views/home/pipeline/components/map.vue @@ -72,7 +72,7 @@ url: `${publicPath}/image/pipeline/underground-normal.png`, // 图标地址 anchor: new mapRef.value.AMap.Pixel(4, 4), // 图标显示位置偏移量,基准点为图标左上角 size: new mapRef.value.AMap.Size(20, 20), // 图标的尺寸 - zIndex: 99, // 每种样式图标的叠加顺序,数字越大越靠前 + zIndex: 100, // 每种样式图标的叠加顺序,数字越大越靠前 }, { url: `${publicPath}/image/pipeline/地埋式哨兵-异常.png`, // 图标地址 @@ -90,7 +90,7 @@ url: `${publicPath}/image/pipeline/warning-normal.png`, // 图标地址 anchor: new mapRef.value.AMap.Pixel(4, 4), // 图标显示位置偏移量,基准点为图标左上角 size: new mapRef.value.AMap.Size(20, 20), // 图标的尺寸 - zIndex: 99, // 每种样式图标的叠加顺序,数字越大越靠前 + zIndex: 100, // 每种样式图标的叠加顺序,数字越大越靠前 }, { url: `${publicPath}/image/pipeline/警示桩-异常.png`, // 图标地址 diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/views/home/pipeline/components/detail.vue b/src/views/home/pipeline/components/detail.vue index 106d488..b68eb45 100644 --- a/src/views/home/pipeline/components/detail.vue +++ b/src/views/home/pipeline/components/detail.vue @@ -106,7 +106,7 @@ // align: 'center', // }, { - text: '设备使用状态', + text: '设备在用状态', value: 'onState', align: 'center', }, diff --git a/src/views/home/pipeline/components/detailInfoDialog.vue b/src/views/home/pipeline/components/detailInfoDialog.vue index ffe9f93..b9b9421 100644 --- a/src/views/home/pipeline/components/detailInfoDialog.vue +++ b/src/views/home/pipeline/components/detailInfoDialog.vue @@ -6,14 +6,15 @@ - { }"> + {}" + > - + - {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + - + 详情 @@ -219,22 +261,102 @@ - - + + {{ item.text }} - + {{ detailInfo[item.value] || '' }} + + + {{ detailInfo[item.value] || '' }} + + + + {{ detailInfo[item.value] || '' }} + - + + - {{ item.text }} : - {{ item.name.includes('燃气') || item.name.includes('哨兵') ? item.value - : item.stateName }} - {{ item.unit - }} - + {{ item.name }} : + + {{ + item.name.includes('燃气') || item.name.includes('哨兵') || item.name.includes('智能警示桩') + ? item.value + : item.stateName + }} + + {{ item.unit }} + 更多 @@ -301,7 +423,9 @@ flex-wrap: wrap; box-sizing: border-box; padding: 6px 0; - + .last-value { + width: 100% !important; + } .descriptions-item { width: 48%; margin: 4px 5px; @@ -312,7 +436,9 @@ .label-no { width: 28% !important; } - + .last-label { + width: 16% !important; + } .label { width: 34%; box-sizing: border-box; diff --git a/src/views/home/pipeline/components/gasDataDialog.vue b/src/views/home/pipeline/components/gasDataDialog.vue new file mode 100644 index 0000000..fa91c9e --- /dev/null +++ b/src/views/home/pipeline/components/gasDataDialog.vue @@ -0,0 +1,312 @@ + + + + + + + + + 采集时间: + + 上传时间: + + + 搜索 + + + + + + + + + + + + diff --git a/src/views/home/pipeline/components/map.vue b/src/views/home/pipeline/components/map.vue index 6e04960..d1cda40 100644 --- a/src/views/home/pipeline/components/map.vue +++ b/src/views/home/pipeline/components/map.vue @@ -72,7 +72,7 @@ url: `${publicPath}/image/pipeline/underground-normal.png`, // 图标地址 anchor: new mapRef.value.AMap.Pixel(4, 4), // 图标显示位置偏移量,基准点为图标左上角 size: new mapRef.value.AMap.Size(20, 20), // 图标的尺寸 - zIndex: 99, // 每种样式图标的叠加顺序,数字越大越靠前 + zIndex: 100, // 每种样式图标的叠加顺序,数字越大越靠前 }, { url: `${publicPath}/image/pipeline/地埋式哨兵-异常.png`, // 图标地址 @@ -90,7 +90,7 @@ url: `${publicPath}/image/pipeline/warning-normal.png`, // 图标地址 anchor: new mapRef.value.AMap.Pixel(4, 4), // 图标显示位置偏移量,基准点为图标左上角 size: new mapRef.value.AMap.Size(20, 20), // 图标的尺寸 - zIndex: 99, // 每种样式图标的叠加顺序,数字越大越靠前 + zIndex: 100, // 每种样式图标的叠加顺序,数字越大越靠前 }, { url: `${publicPath}/image/pipeline/警示桩-异常.png`, // 图标地址 diff --git a/src/views/home/pipeline/index.vue b/src/views/home/pipeline/index.vue index 1f7a2f9..4e6ad56 100644 --- a/src/views/home/pipeline/index.vue +++ b/src/views/home/pipeline/index.vue @@ -34,7 +34,7 @@ { text: '建设年代', value: 'constructEra', align: 'center' }, { text: '详细位置', value: 'position', isRequired: true, align: 'center' }, { text: '管理单位', value: 'deptName', isRequired: true, align: 'center' }, - { text: '使用状态', value: 'onState', align: 'center', width: '90' }, + { text: '在用状态', value: 'onState', align: 'center', width: '90' }, { text: '监控状态', value: 'monitorState', align: 'center' }, ]) // 最终展示列 @@ -80,9 +80,9 @@ lat: item.latGaode, lng: item.lngGaode, id: item.id, - status: item.onState === '投用' ? '1' : '0', + status: item.monitorState === '正常' ? '1' : '0', })) - console.log(mapList.value, 'mapList.value') + // console.log(mapList.value, 'mapList.value') setTimeout(() => { if (tableFlag.value === 'map') { mapRef.value.resetDraw() @@ -126,6 +126,7 @@ id: item.LEDGER_ID, status: item.ONLINE_STATE, })) + // console.log(mapList.value.filter(item => item.lng === '116.7069320679'), '561246664433') setTimeout(() => { if (tableFlag.value === 'map') { mapRef.value.resetDraw() @@ -170,7 +171,7 @@ const monitorStateList = ref<{ id: string; name: string; value: string }[]>([]) // 监控状态 const fetchDict = () => { // 使用状态 - getDictByCode('onState').then((res) => { + getDictByCode('onUseStatus').then((res) => { onStateList.value = res.data }) // 监控状态 @@ -370,7 +371,7 @@ --> - + diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/views/home/pipeline/components/detail.vue b/src/views/home/pipeline/components/detail.vue index 106d488..b68eb45 100644 --- a/src/views/home/pipeline/components/detail.vue +++ b/src/views/home/pipeline/components/detail.vue @@ -106,7 +106,7 @@ // align: 'center', // }, { - text: '设备使用状态', + text: '设备在用状态', value: 'onState', align: 'center', }, diff --git a/src/views/home/pipeline/components/detailInfoDialog.vue b/src/views/home/pipeline/components/detailInfoDialog.vue index ffe9f93..b9b9421 100644 --- a/src/views/home/pipeline/components/detailInfoDialog.vue +++ b/src/views/home/pipeline/components/detailInfoDialog.vue @@ -6,14 +6,15 @@ - { }"> + {}" + > - + - {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + - + 详情 @@ -219,22 +261,102 @@ - - + + {{ item.text }} - + {{ detailInfo[item.value] || '' }} + + + {{ detailInfo[item.value] || '' }} + + + + {{ detailInfo[item.value] || '' }} + - + + - {{ item.text }} : - {{ item.name.includes('燃气') || item.name.includes('哨兵') ? item.value - : item.stateName }} - {{ item.unit - }} - + {{ item.name }} : + + {{ + item.name.includes('燃气') || item.name.includes('哨兵') || item.name.includes('智能警示桩') + ? item.value + : item.stateName + }} + + {{ item.unit }} + 更多 @@ -301,7 +423,9 @@ flex-wrap: wrap; box-sizing: border-box; padding: 6px 0; - + .last-value { + width: 100% !important; + } .descriptions-item { width: 48%; margin: 4px 5px; @@ -312,7 +436,9 @@ .label-no { width: 28% !important; } - + .last-label { + width: 16% !important; + } .label { width: 34%; box-sizing: border-box; diff --git a/src/views/home/pipeline/components/gasDataDialog.vue b/src/views/home/pipeline/components/gasDataDialog.vue new file mode 100644 index 0000000..fa91c9e --- /dev/null +++ b/src/views/home/pipeline/components/gasDataDialog.vue @@ -0,0 +1,312 @@ + + + + + + + + + 采集时间: + + 上传时间: + + + 搜索 + + + + + + + + + + + + diff --git a/src/views/home/pipeline/components/map.vue b/src/views/home/pipeline/components/map.vue index 6e04960..d1cda40 100644 --- a/src/views/home/pipeline/components/map.vue +++ b/src/views/home/pipeline/components/map.vue @@ -72,7 +72,7 @@ url: `${publicPath}/image/pipeline/underground-normal.png`, // 图标地址 anchor: new mapRef.value.AMap.Pixel(4, 4), // 图标显示位置偏移量,基准点为图标左上角 size: new mapRef.value.AMap.Size(20, 20), // 图标的尺寸 - zIndex: 99, // 每种样式图标的叠加顺序,数字越大越靠前 + zIndex: 100, // 每种样式图标的叠加顺序,数字越大越靠前 }, { url: `${publicPath}/image/pipeline/地埋式哨兵-异常.png`, // 图标地址 @@ -90,7 +90,7 @@ url: `${publicPath}/image/pipeline/warning-normal.png`, // 图标地址 anchor: new mapRef.value.AMap.Pixel(4, 4), // 图标显示位置偏移量,基准点为图标左上角 size: new mapRef.value.AMap.Size(20, 20), // 图标的尺寸 - zIndex: 99, // 每种样式图标的叠加顺序,数字越大越靠前 + zIndex: 100, // 每种样式图标的叠加顺序,数字越大越靠前 }, { url: `${publicPath}/image/pipeline/警示桩-异常.png`, // 图标地址 diff --git a/src/views/home/pipeline/index.vue b/src/views/home/pipeline/index.vue index 1f7a2f9..4e6ad56 100644 --- a/src/views/home/pipeline/index.vue +++ b/src/views/home/pipeline/index.vue @@ -34,7 +34,7 @@ { text: '建设年代', value: 'constructEra', align: 'center' }, { text: '详细位置', value: 'position', isRequired: true, align: 'center' }, { text: '管理单位', value: 'deptName', isRequired: true, align: 'center' }, - { text: '使用状态', value: 'onState', align: 'center', width: '90' }, + { text: '在用状态', value: 'onState', align: 'center', width: '90' }, { text: '监控状态', value: 'monitorState', align: 'center' }, ]) // 最终展示列 @@ -80,9 +80,9 @@ lat: item.latGaode, lng: item.lngGaode, id: item.id, - status: item.onState === '投用' ? '1' : '0', + status: item.monitorState === '正常' ? '1' : '0', })) - console.log(mapList.value, 'mapList.value') + // console.log(mapList.value, 'mapList.value') setTimeout(() => { if (tableFlag.value === 'map') { mapRef.value.resetDraw() @@ -126,6 +126,7 @@ id: item.LEDGER_ID, status: item.ONLINE_STATE, })) + // console.log(mapList.value.filter(item => item.lng === '116.7069320679'), '561246664433') setTimeout(() => { if (tableFlag.value === 'map') { mapRef.value.resetDraw() @@ -170,7 +171,7 @@ const monitorStateList = ref<{ id: string; name: string; value: string }[]>([]) // 监控状态 const fetchDict = () => { // 使用状态 - getDictByCode('onState').then((res) => { + getDictByCode('onUseStatus').then((res) => { onStateList.value = res.data }) // 监控状态 @@ -370,7 +371,7 @@ --> - + diff --git a/src/views/home/rule/alarm/index.vue b/src/views/home/rule/alarm/index.vue index e62199c..0eaaf34 100644 --- a/src/views/home/rule/alarm/index.vue +++ b/src/views/home/rule/alarm/index.vue @@ -25,7 +25,7 @@ const total = ref(0) // 初始展示列 const columns = ref([ - { text: '报警名称', value: 'alarmName', align: 'center', isRequire: false }, + { text: '报警名称', value: 'alarmName', align: 'center', isRequired: false }, { text: '报警类型', value: 'alarmTypeName', align: 'center' }, { text: '设备类型', value: 'typeName', align: 'center' }, { text: '产品', value: 'productName', align: 'center' }, diff --git a/src/components/TableContainer/configColumnsDialog.vue b/src/components/TableContainer/configColumnsDialog.vue index 2b9a6fc..ba52593 100644 --- a/src/components/TableContainer/configColumnsDialog.vue +++ b/src/components/TableContainer/configColumnsDialog.vue @@ -19,7 +19,7 @@ } else { // checkList.value = data.columns.filter((item: any) => item.isRequired).map((item: any) => item.text) - checkList.value = data.columns.map((item: any) => item.text) + checkList.value = data.columns.filter((item: any) => item.isRequired !== false).map((item: any) => item.text) } dialogFormVisible.value = true } diff --git a/src/components/TableContainer/index.vue b/src/components/TableContainer/index.vue index 6e6af6a..d5e5701 100644 --- a/src/components/TableContainer/index.vue +++ b/src/components/TableContainer/index.vue @@ -65,7 +65,7 @@ else { console.log('无存储', props.configTitle, props.columns) // props.edit(props.columns.filter((item: any) => item.isRequired)) - props.edit(props.columns) + props.edit(props.columns.filter((item: any) => item.isRequired !== false)) } diff --git a/src/layouts/components/Tools/alarmList.vue b/src/layouts/components/Tools/alarmList.vue index 7e294c3..960271d 100644 --- a/src/layouts/components/Tools/alarmList.vue +++ b/src/layouts/components/Tools/alarmList.vue @@ -104,7 +104,10 @@ isSound: alarmLevelList.value.filter((citem: any) => citem.id === item.alarmLevel)[0]?.isSound || '', })) loading.value = false - play() + // play() + if (messageList.value.length > 0 && messageList.value.some((item: any) => item.isSound === '1')) { + proxy.playAudio() + } }).catch(() => { loading.value = false }) diff --git a/src/views/home/alarm/current/components/detail.vue b/src/views/home/alarm/current/components/detail.vue index a306b44..94a98a1 100644 --- a/src/views/home/alarm/current/components/detail.vue +++ b/src/views/home/alarm/current/components/detail.vue @@ -224,7 +224,7 @@ {{ detailInfo[item.value] || '' }} diff --git a/src/views/home/alarm/current/components/detailInfoDialog.vue b/src/views/home/alarm/current/components/detailInfoDialog.vue index d48355f..b919f1a 100644 --- a/src/views/home/alarm/current/components/detailInfoDialog.vue +++ b/src/views/home/alarm/current/components/detailInfoDialog.vue @@ -7,6 +7,7 @@ import pendingDialog from './pendingDialog.vue' import remindDialog from './remindDialog.vue' import monitorDataDialog from './monitorDataDialog.vue' +import gasDataDialog from './gasDataDialog.vue' import processDialog from './processDialog.vue' import handlerDialog from './handlerDialog.vue' import { detailAlarm, getPrincipals } from '@/api/home/alarm/current' @@ -58,7 +59,12 @@ // 查看数据 const dataRef = ref() +const gasRef = ref() const viewData = () => { + if(info.value.devTypeName === '管网哨兵') { + gasRef.value.initDialog(info.value) + return + } dataRef.value.initDialog(info.value) } // 更多 @@ -125,6 +131,7 @@ + @@ -166,7 +173,7 @@ 报警设备: {{ info.devcode }} 查看数据 diff --git a/src/views/home/alarm/current/components/gasDataDialog.vue b/src/views/home/alarm/current/components/gasDataDialog.vue new file mode 100644 index 0000000..ed2b98d --- /dev/null +++ b/src/views/home/alarm/current/components/gasDataDialog.vue @@ -0,0 +1,415 @@ + + + + + + + + + + 采集时间: + + + + 搜索 + + + 切换视图 + + + + + + + + {{ scope.$index + 1 }} + + + + + + + + + + + + + + + + diff --git a/src/views/home/alarm/current/components/monitorDataDialog.vue b/src/views/home/alarm/current/components/monitorDataDialog.vue index f763f90..604efae 100644 --- a/src/views/home/alarm/current/components/monitorDataDialog.vue +++ b/src/views/home/alarm/current/components/monitorDataDialog.vue @@ -188,6 +188,7 @@ :total="0" :columns="columns" :query="{}" + :height="350" :list-loading="loadingTable" :pagination="false" > diff --git a/src/views/home/alarm/current/components/processDialog.vue b/src/views/home/alarm/current/components/processDialog.vue index 85d9bcb..fcb5c42 100644 --- a/src/views/home/alarm/current/components/processDialog.vue +++ b/src/views/home/alarm/current/components/processDialog.vue @@ -96,10 +96,14 @@ 时间: ${pending[0].APPROVAL_TIME} 人员: ${pending[0].APPROVAL_PERSON} 操作: ${pending[0].process_name} + 挂起时长: ${pending[0].DESCN?.split('|')[0] || ''}小时 + 挂起原因: ${pending[0].DESCN?.split('|')[1] || ''} ` + console.log( processData.value[1], ' processData.value[1]') } else { const data = uniqueMultiArray(res.data, 'process_name') + console.log(data, '123') // console.log(data, '2222222') data.forEach((item: any, index: number) => { // console.log(item, 'item') diff --git a/src/views/home/alarm/current/index.vue b/src/views/home/alarm/current/index.vue index 3a2d08d..8610a25 100644 --- a/src/views/home/alarm/current/index.vue +++ b/src/views/home/alarm/current/index.vue @@ -29,15 +29,15 @@ const $router = useRouter() // 初始展示列 const columns = ref([ - { text: '报警类型', value: 'alarmType', align: 'center', width: '160' }, - { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '100' }, + { text: '报警类型', value: 'alarmType', align: 'center', width: '130' }, + { text: '报警等级', value: 'alarmLevelName', align: 'center', width: '85' }, { text: '报警原因', value: 'alarmMsg', align: 'center' }, { text: '位置', value: 'position', align: 'center' }, - { text: '设备类型', value: 'devTypeName', align: 'center' }, - { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true }, - { text: '管理单位', value: 'deptName', align: 'center' }, + { text: '设备类型', value: 'devTypeName', align: 'center', width: '145', isRequired: false, }, + { text: '设备编号', value: 'devcode', align: 'center', width: '160', isCustom: true, isRequired: false, }, + { text: '管理单位', value: 'deptName', align: 'center', width: '400' }, { text: '状态', value: 'processStatusName', align: 'center', width: '120' }, - { text: '报警时间', value: 'ts', align: 'center' }, + { text: '报警时间', value: 'alarmTime', align: 'center', width: '170' }, ]) // 最终展示列 const columnsConfig = ref([]) diff --git a/src/views/home/dashboard/components/noticeDialog.vue b/src/views/home/dashboard/components/noticeDialog.vue index 1dd57cc..f27bb53 100644 --- a/src/views/home/dashboard/components/noticeDialog.vue +++ b/src/views/home/dashboard/components/noticeDialog.vue @@ -37,7 +37,7 @@ // 查看详情 const detail = (row: any) => { // 报警类跳转 - if (row.messageTypeDetail.includes('报警')) { + // if (row.messageTypeDetail.includes('报警')) { if (row.alarmId) { $router.push({ name: 'AlarmCurrentDetail', @@ -50,8 +50,22 @@ else { ElMessage.warning('该数据缺少报警信息') } - } + // } } +const disabledBtn = computed(() => { + return (name:string) => { + if(name.includes('解除')) { + return true + } + if(name.includes('施工')) { + return true + } + // if(name.includes('超限')) { + // return false + // } + return false + } +}) @@ -65,7 +79,7 @@ 查看 diff --git a/src/views/home/ledger/ledger/components/gridList.vue b/src/views/home/ledger/ledger/components/gridList.vue index fa9ad75..bad2c42 100644 --- a/src/views/home/ledger/ledger/components/gridList.vue +++ b/src/views/home/ledger/ledger/components/gridList.vue @@ -18,8 +18,8 @@ { text: '负责人', value: 'principal', align: 'center' }, { text: '负责人联系电话', value: 'telephone', align: 'center' }, { text: '压力级制', value: 'pressType', align: 'center', isRequired: true }, - { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true }, - { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true }, + { text: '管线长度', value: 'pipeLength', align: 'center', isRequired: true, width: '140' }, + { text: '坐标状态', value: 'locationStateName', align: 'center', isRequired: true, width: '90' }, ]) // 最终展示列 const columnsConfig = ref([]) @@ -34,7 +34,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 }) // 查询数据 const fetchData = () => { @@ -55,7 +55,7 @@ offset: 1, gridCode: '', // 编号 locationState: '', // 位置状态 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 } fetchData() } @@ -103,11 +103,11 @@ } // const isUsed = ref<{ id: string; name: string; value: string }[]>([]) // 是否启用 // // 获取字典 -// const fetchDict = async () => { -// // 是否启用 -// const res = await getDictByCode('isUsed') -// isUsed.value = res.data -// } +const fetchDict = async () => { + // 是否启用 + // const res = await getDictByCode('isUsed') + // isUsed.value = res.data +} onMounted(async () => { // await fetchDict() fetchData() @@ -123,7 +123,7 @@ - + diff --git a/src/views/home/ledger/ledger/components/wellList.vue b/src/views/home/ledger/ledger/components/wellList.vue index 0eb8f7f..d18ee54 100644 --- a/src/views/home/ledger/ledger/components/wellList.vue +++ b/src/views/home/ledger/ledger/components/wellList.vue @@ -42,7 +42,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, }) @@ -65,7 +65,7 @@ offset: 1, tagNumber: '', // 位号 ledgerName: '', // 名称 - responsibleDept: '', // 管理单位 + deptid: '', // 管理单位 locationState: '', type: props.type, } @@ -138,7 +138,7 @@ - + + + {{ scope.row[column.value] }} + + @@ -375,6 +403,18 @@ diff --git a/src/views/home/pipeline/components/detail.vue b/src/views/home/pipeline/components/detail.vue index 106d488..b68eb45 100644 --- a/src/views/home/pipeline/components/detail.vue +++ b/src/views/home/pipeline/components/detail.vue @@ -106,7 +106,7 @@ // align: 'center', // }, { - text: '设备使用状态', + text: '设备在用状态', value: 'onState', align: 'center', }, diff --git a/src/views/home/pipeline/components/detailInfoDialog.vue b/src/views/home/pipeline/components/detailInfoDialog.vue index ffe9f93..b9b9421 100644 --- a/src/views/home/pipeline/components/detailInfoDialog.vue +++ b/src/views/home/pipeline/components/detailInfoDialog.vue @@ -6,14 +6,15 @@ - { }"> + {}" + > - + - {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + {{ baseInfo.deviceCode }} | {{ baseInfo.deviceTypeName }} + - + 详情 @@ -219,22 +261,102 @@ - - + + {{ item.text }} - + {{ detailInfo[item.value] || '' }} + + + {{ detailInfo[item.value] || '' }} + + + + {{ detailInfo[item.value] || '' }} + - + + - {{ item.text }} : - {{ item.name.includes('燃气') || item.name.includes('哨兵') ? item.value - : item.stateName }} - {{ item.unit - }} - + {{ item.name }} : + + {{ + item.name.includes('燃气') || item.name.includes('哨兵') || item.name.includes('智能警示桩') + ? item.value + : item.stateName + }} + + {{ item.unit }} + 更多 @@ -301,7 +423,9 @@ flex-wrap: wrap; box-sizing: border-box; padding: 6px 0; - + .last-value { + width: 100% !important; + } .descriptions-item { width: 48%; margin: 4px 5px; @@ -312,7 +436,9 @@ .label-no { width: 28% !important; } - + .last-label { + width: 16% !important; + } .label { width: 34%; box-sizing: border-box; diff --git a/src/views/home/pipeline/components/gasDataDialog.vue b/src/views/home/pipeline/components/gasDataDialog.vue new file mode 100644 index 0000000..fa91c9e --- /dev/null +++ b/src/views/home/pipeline/components/gasDataDialog.vue @@ -0,0 +1,312 @@ + + + + + + + + + 采集时间: + + 上传时间: + + + 搜索 + + + + + + + + + + + + diff --git a/src/views/home/pipeline/components/map.vue b/src/views/home/pipeline/components/map.vue index 6e04960..d1cda40 100644 --- a/src/views/home/pipeline/components/map.vue +++ b/src/views/home/pipeline/components/map.vue @@ -72,7 +72,7 @@ url: `${publicPath}/image/pipeline/underground-normal.png`, // 图标地址 anchor: new mapRef.value.AMap.Pixel(4, 4), // 图标显示位置偏移量,基准点为图标左上角 size: new mapRef.value.AMap.Size(20, 20), // 图标的尺寸 - zIndex: 99, // 每种样式图标的叠加顺序,数字越大越靠前 + zIndex: 100, // 每种样式图标的叠加顺序,数字越大越靠前 }, { url: `${publicPath}/image/pipeline/地埋式哨兵-异常.png`, // 图标地址 @@ -90,7 +90,7 @@ url: `${publicPath}/image/pipeline/warning-normal.png`, // 图标地址 anchor: new mapRef.value.AMap.Pixel(4, 4), // 图标显示位置偏移量,基准点为图标左上角 size: new mapRef.value.AMap.Size(20, 20), // 图标的尺寸 - zIndex: 99, // 每种样式图标的叠加顺序,数字越大越靠前 + zIndex: 100, // 每种样式图标的叠加顺序,数字越大越靠前 }, { url: `${publicPath}/image/pipeline/警示桩-异常.png`, // 图标地址 diff --git a/src/views/home/pipeline/index.vue b/src/views/home/pipeline/index.vue index 1f7a2f9..4e6ad56 100644 --- a/src/views/home/pipeline/index.vue +++ b/src/views/home/pipeline/index.vue @@ -34,7 +34,7 @@ { text: '建设年代', value: 'constructEra', align: 'center' }, { text: '详细位置', value: 'position', isRequired: true, align: 'center' }, { text: '管理单位', value: 'deptName', isRequired: true, align: 'center' }, - { text: '使用状态', value: 'onState', align: 'center', width: '90' }, + { text: '在用状态', value: 'onState', align: 'center', width: '90' }, { text: '监控状态', value: 'monitorState', align: 'center' }, ]) // 最终展示列 @@ -80,9 +80,9 @@ lat: item.latGaode, lng: item.lngGaode, id: item.id, - status: item.onState === '投用' ? '1' : '0', + status: item.monitorState === '正常' ? '1' : '0', })) - console.log(mapList.value, 'mapList.value') + // console.log(mapList.value, 'mapList.value') setTimeout(() => { if (tableFlag.value === 'map') { mapRef.value.resetDraw() @@ -126,6 +126,7 @@ id: item.LEDGER_ID, status: item.ONLINE_STATE, })) + // console.log(mapList.value.filter(item => item.lng === '116.7069320679'), '561246664433') setTimeout(() => { if (tableFlag.value === 'map') { mapRef.value.resetDraw() @@ -170,7 +171,7 @@ const monitorStateList = ref<{ id: string; name: string; value: string }[]>([]) // 监控状态 const fetchDict = () => { // 使用状态 - getDictByCode('onState').then((res) => { + getDictByCode('onUseStatus').then((res) => { onStateList.value = res.data }) // 监控状态 @@ -370,7 +371,7 @@ --> - + diff --git a/src/views/home/rule/alarm/index.vue b/src/views/home/rule/alarm/index.vue index e62199c..0eaaf34 100644 --- a/src/views/home/rule/alarm/index.vue +++ b/src/views/home/rule/alarm/index.vue @@ -25,7 +25,7 @@ const total = ref(0) // 初始展示列 const columns = ref([ - { text: '报警名称', value: 'alarmName', align: 'center', isRequire: false }, + { text: '报警名称', value: 'alarmName', align: 'center', isRequired: false }, { text: '报警类型', value: 'alarmTypeName', align: 'center' }, { text: '设备类型', value: 'typeName', align: 'center' }, { text: '产品', value: 'productName', align: 'center' }, diff --git a/src/views/home/well/components/monitorDataGasList.vue b/src/views/home/well/components/monitorDataGasList.vue index a85c8f7..9cdfa8c 100644 --- a/src/views/home/well/components/monitorDataGasList.vue +++ b/src/views/home/well/components/monitorDataGasList.vue @@ -75,7 +75,7 @@ loadingTable.value = true listQuery.value.wellId = $route.query.id as string || $props.id getMonitorData(listQuery.value).then((res) => { - list.value = res.data['燃气智能监测终端'] || res.data['燃气智能监测终端(一体化)'] || [] + list.value = res.data['燃气智能监测终端'] || res.data['燃气智能监测终端(一体化)'] || res.data['管网哨兵'] || [] loadingTable.value = false xAxisData.value = list.value.slice().reverse().map((item: any) => item.logtime) data.value = [