diff --git a/src/api/device-boot/communicate.ts b/src/api/device-boot/communicate.ts index 13b5a2ce..f4414ef8 100644 --- a/src/api/device-boot/communicate.ts +++ b/src/api/device-boot/communicate.ts @@ -1,27 +1,43 @@ import request from '@/utils/request' // 事件分析 获取数据 -export function getRunOnlineRateData(data:any) { +export function getRunOnlineRateData(data: any) { return request({ - url: "/device-boot/communicate/getRunOnlineRateData", - method: "post", + url: '/device-boot/communicate/getRunOnlineRateData', + method: 'post', data - }); + }) } // 事件分析 运行状态 获取数据 -export function getComFlagInfoData(data:any) { +export function getComFlagInfoData(data: any) { return request({ - url: "/device-boot/communicate/getComFlagInfoData", - method: "post", + url: '/device-boot/communicate/getComFlagInfoData', + method: 'post', data - }); + }) } // 事件分析 运行状态 获取数据 -export function getRunInfoData(data:any) { +export function getRunInfoData(data: any) { return request({ - url: "/device-boot/communicate/getRunInfoData", - method: "post", + url: '/device-boot/communicate/getRunInfoData', + method: 'post', data - }); -} \ No newline at end of file + }) +} +// 根据监测点id获取越限数值 +export function getOverLimitData(data: any) { + return request({ + url: '/device-boot/line/getOverLimitData', + method: 'post', + params: data + }) +} +// 获取监测点id取监测点信息 +export function getLineDetail(data: any) { + return request({ + url: '/device-boot/commLine/getLineDetail', + method: 'get', + params: data + }) +} diff --git a/src/api/event-boot/highAndLowPressure.ts b/src/api/event-boot/highAndLowPressure.ts index de7a23af..5e8a4b27 100644 --- a/src/api/event-boot/highAndLowPressure.ts +++ b/src/api/event-boot/highAndLowPressure.ts @@ -15,4 +15,12 @@ export function updateEventReason(data: any) { method: 'post', data }) -} \ No newline at end of file +} +//获取暂态事件明细 +export function queryEventDetailByEventId(params: any) { + return request({ + url: '/event-boot/rmpEventDetail/queryEventDetailByEventId', + method: 'GET', + params + }) +} diff --git a/src/api/user-boot/user.ts b/src/api/user-boot/user.ts index d285f9c1..480dc2db 100644 --- a/src/api/user-boot/user.ts +++ b/src/api/user-boot/user.ts @@ -54,8 +54,15 @@ export function getUserById() { } // 刷新token +// 导出一个名为refreshToken的函数,该函数返回一个Promise对象 export function refreshToken(): Promise { + // 调用useAdminInfo函数获取管理员信息,并将其赋值给adminInfo变量 const adminInfo = useAdminInfo() + // 调用login函数,传入一个对象作为参数,该对象包含grant_type、refresh_token和username三个属性 + // grant_type设置为'refresh_token',表示使用刷新令牌的方式获取新的访问令牌 + // refresh_token使用adminInfo中的refresh_token属性 + // username使用adminInfo中的loginName属性 + // 返回login函数的调用结果,即一个Promise对象 return login({ grant_type: 'refresh_token', refresh_token: adminInfo.refresh_token, diff --git a/src/assets/11111.gif b/src/assets/11111.gif new file mode 100644 index 00000000..2986314b Binary files /dev/null and b/src/assets/11111.gif differ diff --git a/src/components/echarts/MyEchart.vue b/src/components/echarts/MyEchart.vue index e59645d6..453c7738 100644 --- a/src/components/echarts/MyEchart.vue +++ b/src/components/echarts/MyEchart.vue @@ -15,8 +15,7 @@ import { color, gradeColor3 } from './color' import { useConfig } from '@/stores/config' const config = useConfig() // import { nextTick } from 'process' - - +const emit = defineEmits(['triggerPoint']) color[0] = config.layout.elementUiPrimary[0] const chartRef = ref() @@ -37,7 +36,7 @@ const initChart = () => { chart?.dispose() } // chart?.dispose() - chart = echarts.init(chartRef.value as HTMLDivElement) + chart = echarts.getInstanceByDom(chartRef.value as HTMLDivElement) || echarts.init(chartRef.value as HTMLDivElement) const options = { title: { left: 'center', @@ -69,10 +68,11 @@ const initChart = () => { }, toolbox: { right: 20, - top: 20, + top: 15, feature: { saveAsImage: { - title: '保存图片', + title: '', // 按钮标题 + icon: 'path://M892.342857 463.238095l-73.142857-68.266666-258.438095 258.438095V29.257143h-97.52381v624.152381L204.8 394.971429 131.657143 463.238095l380.342857 380.342857zM107.27619 897.219048h804.571429v97.523809H107.27619z' // 自定义图标路径 }, ...(props.options?.toolbox?.featureProps || null) @@ -87,8 +87,8 @@ const initChart = () => { ...(props.options?.toolbox || null) }, legend: { - right: 20, - top: 0, + right: 50, + top: 25, itemGap: 10, itemStyle: {}, // textStyle: { @@ -100,7 +100,7 @@ const initChart = () => { ...(props.options?.legend || null) }, grid: { - top: '60px', + top: '70px', left: '30px', right: '70px', bottom: props.options?.options?.dataZoom === null ? '10px' : '40px', @@ -132,7 +132,13 @@ const initChart = () => { handlerBar(options) // 处理柱状图 chart.setOption(options, true) - + chart.group = 'group' + // 添加点击事件 + chart.on('click', function (params) { + if (params.seriesName == '暂态触发点') { + emit('triggerPoint', params.data) + } + }) setTimeout(() => { chart.resize() }, 0) @@ -223,9 +229,9 @@ const handlerXAxis = () => { // textStyle: { fontFamily: 'dinproRegular', color: '#000', - fontSize: '12', + fontSize: '12' // } - }, + } // boundaryGap: false, } // props.options?.xAxis 是数组还是对象 @@ -256,11 +262,17 @@ const resizeObserver = new ResizeObserver(entries => { }, 100) } }) +const setOptions = (options: any) => { + chart.setOption(options) +} +const getChart = () => { + return chart +} onMounted(() => { initChart() resizeObserver.observe(chartRef.value!) }) -defineExpose({ initChart }) +defineExpose({ initChart, setOptions, getChart }) onBeforeUnmount(() => { resizeObserver.unobserve(chartRef.value!) chart?.dispose() diff --git a/src/components/echarts/rmsboxi.vue b/src/components/echarts/rmsboxi.vue index 8ddbb697..b9a8ea64 100644 --- a/src/components/echarts/rmsboxi.vue +++ b/src/components/echarts/rmsboxi.vue @@ -1,11 +1,12 @@ diff --git a/src/components/form/datePicker/index.vue b/src/components/form/datePicker/index.vue index 749f6408..1c0a9700 100644 --- a/src/components/form/datePicker/index.vue +++ b/src/components/form/datePicker/index.vue @@ -19,7 +19,7 @@ import { ref, onMounted, nextTick, watch } from 'vue' interface Props { nextFlag?: boolean - theCurrentTime: boolean + theCurrentTime?: boolean } const props = withDefaults(defineProps(), { diff --git a/src/components/table/header/index.vue b/src/components/table/header/index.vue index 6ab5c393..015f948f 100644 --- a/src/components/table/header/index.vue +++ b/src/components/table/header/index.vue @@ -48,7 +48,7 @@ import { mainHeight } from '@/utils/layout' import { useDictData } from '@/stores/dictData' import { Search, RefreshLeft } from '@element-plus/icons-vue' import { defineProps } from 'vue' - +const emit = defineEmits(['selectChange',]) const tableStore = inject('tableStore') as TableStore const tableHeader = ref() const datePickerRef = ref() @@ -139,20 +139,17 @@ onUnmounted(() => { }) const handlerHeight = () => { + tableStore.table.publicHeight + tableHeader.value.offsetHeight + (tableStore.showPage ? 58 : 0) + 20 tableStore.table.height = mainHeight( tableStore.table.publicHeight + tableHeader.value.offsetHeight + (tableStore.showPage ? 58 : 0) + 20 ).height as string } const computedSearchRow = () => { - if (!headerForm.value.$el) return - - // 清空headerFormSecond.value.$el下的元素 while (headerFormSecond.value.$el.firstChild) { headerForm.value.$el.appendChild(headerFormSecond.value.$el.firstChild) } - // 获取第一行放了几个表单 const elFormItem = headerForm.value.$el.querySelectorAll('.el-form-item') @@ -160,10 +157,10 @@ const elFormItem = headerForm.value.$el.querySelectorAll('.el-form-item') let width = 0 for (let i = 0; i < elFormItem.length; i++) { width += elFormItem[i].offsetWidth + 32 + if (width > headerForm.value.$el.offsetWidth) { headerFormSecond.value.$el.appendChild(elFormItem[i]) } - } // 判断是否需要折叠 @@ -177,6 +174,7 @@ if (headerFormSecond.value.$el.scrollHeight > 0) { const showSelect = ref(false) const showSelectChange = () => { showSelect.value = !showSelect.value + emit('selectChange', showSelect.value) } const onComSearch = async () => { if (props.datePicker && timeAll.value) { @@ -205,7 +203,7 @@ const onExport = () => { tableStore.onTableAction('export', { showAllFlag: true }) } -defineExpose({ onComSearch, areaRef, setDatePicker, setTheDate, datePickerRef, showSelectChange }) +defineExpose({ onComSearch, areaRef, setDatePicker, setTheDate, datePickerRef, showSelectChange,computedSearchRow }) + diff --git a/src/views/pqs/harmonicMonitoring/monitoringPoint/online/shishishuju/spectrum.vue b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/shishishuju/spectrum.vue new file mode 100644 index 00000000..d497b097 --- /dev/null +++ b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/shishishuju/spectrum.vue @@ -0,0 +1,345 @@ + + + diff --git a/src/views/pqs/harmonicMonitoring/monitoringPoint/online/shishishuju/trend.vue b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/shishishuju/trend.vue new file mode 100644 index 00000000..0f1ed0c6 --- /dev/null +++ b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/shishishuju/trend.vue @@ -0,0 +1,384 @@ + + + diff --git a/src/views/pqs/harmonicMonitoring/monitoringPoint/online/wentaishujufenxi/index.vue b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/wentaishujufenxi/index.vue index 1900e2f0..382561d9 100644 --- a/src/views/pqs/harmonicMonitoring/monitoringPoint/online/wentaishujufenxi/index.vue +++ b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/wentaishujufenxi/index.vue @@ -1,57 +1,96 @@ diff --git a/src/views/pqs/harmonicMonitoring/monitoringPoint/online/wentaizhibiaohegelv/index.vue b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/wentaizhibiaohegelv/index.vue index ab833cfd..824c0aff 100644 --- a/src/views/pqs/harmonicMonitoring/monitoringPoint/online/wentaizhibiaohegelv/index.vue +++ b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/wentaizhibiaohegelv/index.vue @@ -1,19 +1,26 @@