修改文件预览
This commit is contained in:
@@ -59,9 +59,9 @@ const tableStore = new TableStore({
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Plus',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return !VITE_FLAG
|
||||
},
|
||||
// disabled: row => {
|
||||
// return !VITE_FLAG
|
||||
// },
|
||||
click: row => {
|
||||
window.open(window.location.origin + '/#/previewFile?' + row.url)
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
>
|
||||
<vxe-column type="seq" title="序号" width="60px"></vxe-column>
|
||||
<!-- <vxe-column field="date" title="日期"></vxe-column> -->
|
||||
<vxe-column field="name" title="统计日期"></vxe-column>
|
||||
<vxe-column field="date" title="统计日期"></vxe-column>
|
||||
<!-- <vxe-column field="monitorName" title="监测点名称"></vxe-column>
|
||||
<vxe-column field="timeSum" title="异常天数" width="80px">
|
||||
<template v-slot="{ row }">
|
||||
@@ -25,19 +25,23 @@
|
||||
|
||||
<div style="width: 920px" v-loading="loading1">
|
||||
<el-form :inline="true" class="form">
|
||||
<!-- <el-form-item label="统计日期">
|
||||
<el-form-item label="统计指标">
|
||||
<el-select
|
||||
v-model="timeList"
|
||||
multiple
|
||||
collapse-tags
|
||||
v-model="targetKey"
|
||||
filterable
|
||||
clearable
|
||||
placeholder="请选择异常天数"
|
||||
style="width: 200px"
|
||||
placeholder="请选择指标"
|
||||
style="width: 150px"
|
||||
@change="init"
|
||||
>
|
||||
<el-option v-for="item in dateList" :key="item" :label="item" :value="item" />
|
||||
<el-option
|
||||
v-for="item in targetList"
|
||||
:key="item.key"
|
||||
:label="item.targetName"
|
||||
:value="item.key"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item> -->
|
||||
|
||||
</el-form-item>
|
||||
<el-form-item class="form_but">
|
||||
<span class="mr20">
|
||||
异常时间:
|
||||
@@ -58,7 +62,6 @@
|
||||
height="auto"
|
||||
:data="TableData1.slice((pageNum - 1) * pageSize, pageNum * pageSize)"
|
||||
v-bind="defaultAttribute"
|
||||
|
||||
>
|
||||
<vxe-column type="seq" title="序号" width="80px">
|
||||
<template #default="{ rowIndex }">
|
||||
@@ -147,6 +150,7 @@ const targetKey = ref('')
|
||||
const errCount = ref('')
|
||||
const timeSum = ref('')
|
||||
const timeList = ref([])
|
||||
const targetList = ref([])
|
||||
const showColumn = ref(true)
|
||||
const open = (data: anyObj, time: string[]) => {
|
||||
// title.value = (num == 0 ? data.targetName : data.monitorName) + '_异常监测点详情'
|
||||
@@ -157,18 +161,15 @@ const open = (data: anyObj, time: string[]) => {
|
||||
timeList.value = []
|
||||
targetKey.value = data.key
|
||||
monitorAbnormalTable({
|
||||
monitorIds:[data.lineId],
|
||||
monitorIds: [data.lineId],
|
||||
targetKey: '',
|
||||
searchBeginTime: time[0],
|
||||
searchEndTime: time[1]
|
||||
})
|
||||
.then(async res => {
|
||||
TableData.value = res.data
|
||||
timeList.value = TableData.value[0]?.dateList.map((item: any) => {
|
||||
return {
|
||||
name: item
|
||||
}
|
||||
})
|
||||
timeList.value = TableData.value[0]?.dateTargetList
|
||||
targetList.value = timeList.value[0].targetKeys
|
||||
await tableRef.value.setCurrentRow(timeList.value[0])
|
||||
await currentChangeEvent()
|
||||
loading.value = false
|
||||
@@ -180,7 +181,10 @@ const open = (data: anyObj, time: string[]) => {
|
||||
}
|
||||
const currentChangeEvent = () => {
|
||||
let data = tableRef.value.getCurrentRecord()
|
||||
|
||||
targetList.value = data.targetKeys
|
||||
if (!targetList.value.some(item => item.key == targetKey.value)) {
|
||||
targetKey.value = ''
|
||||
}
|
||||
// dateList.value = data.dateList
|
||||
//[data.dateList[0]]
|
||||
init()
|
||||
@@ -191,9 +195,9 @@ const init = () => {
|
||||
let data = tableRef.value.getCurrentRecord()
|
||||
monitorAbnormalTableDetail({
|
||||
monitorIds: [TableData.value[0]?.monitorId],
|
||||
time: [data.name],
|
||||
time: [data.date],
|
||||
searchBeginTime: TableData.value[0].date,
|
||||
targetKey: ''
|
||||
targetKey: targetKey.value
|
||||
})
|
||||
.then(res => {
|
||||
errCount.value = res.data.errCount
|
||||
@@ -234,7 +238,7 @@ defineExpose({ open })
|
||||
// justify-content: end;
|
||||
// position: relative;
|
||||
// .form_but {
|
||||
|
||||
|
||||
// right: -22px;
|
||||
// }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user