diff --git a/frontend-sjgl/src/api/DataQueryMenuModule/index.ts b/frontend-sjgl/src/api/DataQueryMenuModule/index.ts index 63501e8d..cb4498e5 100644 --- a/frontend-sjgl/src/api/DataQueryMenuModule/index.ts +++ b/frontend-sjgl/src/api/DataQueryMenuModule/index.ts @@ -114,6 +114,24 @@ export function getFlowDataMonthList(data) { data }); } + +// 生态流量运行数据 - 删除 +export function deleteFlowDataInfo(data) { + return request({ + url: '/eq/data/removeKendoByIds', + method: 'post', + data + }); +} + +// 生态流量运行数据 - 修改 +export function updateEqRsData(data) { + return request({ + url: '/eq/data/updateEqRsData', + method: 'post', + data + }); +} // 水质监测数据 - 断面 export function getWaterDataSectionList(data) { return request({ @@ -331,6 +349,36 @@ export function deleteFpssrlRInfo(data) { }); } +// 过鱼设施AI自动数据 - 分页查询 +export function getFpssrlAiRPageList(data) { + return request({ + url: '/fp/query/qgc/GetKendoListCustAI', + method: 'post', + data + }); +} + +// 过鱼设施AI自动数据 - 编辑 +export function updateFpssrlAiRInfo(data) { + return request({ + url: '/base/fpssrlAiR/update', + method: 'post', + headers: { + 'Content-Type': 'multipart/form-data' + }, + data + }); +} + +// 过鱼设施AI自动数据 - 删除 +export function deleteFpssrlAiRInfo(data) { + return request({ + url: '/base/fpssrlAiR/delete', + method: 'post', + data + }); +} + // 鱼类 放鱼 export function getFishReleaseList(data) { return request({ diff --git a/frontend-sjgl/src/components/BasicTable/index.vue b/frontend-sjgl/src/components/BasicTable/index.vue index 716cc092..88ab0ae9 100644 --- a/frontend-sjgl/src/components/BasicTable/index.vue +++ b/frontend-sjgl/src/components/BasicTable/index.vue @@ -54,7 +54,7 @@ interface Props { data?: any[]; enableRowSelection?: boolean; enableRowHighlight?: boolean; // 是否启用行点击高亮 - rowKey?: string; + rowKey?: string | ((record: any) => string | number); searchParams?: Record; defaultPageSize?: number; isPage?: boolean; @@ -663,7 +663,20 @@ const enhancedColumns = computed(() => { title: String(text) }, { - default: () => String(text) + default: () => + h( + 'span', + { + style: { + display: 'inline-block', + maxWidth: '100%', + overflow: 'hidden', + textOverflow: 'ellipsis', + whiteSpace: 'nowrap' + } + }, + String(text) + ) } ) ); diff --git a/frontend-sjgl/src/components/MapModal/components/BasicInfo.vue b/frontend-sjgl/src/components/MapModal/components/BasicInfo.vue index b1ffe928..c0e14df1 100644 --- a/frontend-sjgl/src/components/MapModal/components/BasicInfo.vue +++ b/frontend-sjgl/src/components/MapModal/components/BasicInfo.vue @@ -359,7 +359,6 @@ const getData = async () => { try { if (props.url && modelStore.params.stcd) { let res: any = await getStcdDetail(props.url, modelStore.params.stcd); - // debugger if (res && res.code) { let data = res.data; data2.value = data; @@ -372,7 +371,6 @@ const getData = async () => { ? modelStore.params.sttp : modelStore.params.sttp) ).columns; - // debugger columns.forEach(item => { if (item.visible) { diff --git a/frontend-sjgl/src/components/MapModal/index.vue b/frontend-sjgl/src/components/MapModal/index.vue index 8773b3c1..8a450a22 100644 --- a/frontend-sjgl/src/components/MapModal/index.vue +++ b/frontend-sjgl/src/components/MapModal/index.vue @@ -529,7 +529,6 @@ const setQGCTabList = async (_tabs: any, stcd: string) => { // 2. 垂向水温 & AI 识别检查(对所有类型执行,与 React 一致) const res4 = await getStInfoByStcd({ stcd }); let newTabs = [...tabs]; - // debugger if (res4 && res4.data && res4.data.relList) { const relList = res4.data.relList; const jianCei = relList.find((item: any) => item.sttpCode === 'WTVT'); diff --git a/frontend-sjgl/src/store/modules/shuJuTianBao.ts b/frontend-sjgl/src/store/modules/shuJuTianBao.ts index b1cec9a7..d8f967eb 100644 --- a/frontend-sjgl/src/store/modules/shuJuTianBao.ts +++ b/frontend-sjgl/src/store/modules/shuJuTianBao.ts @@ -27,7 +27,6 @@ export const useShuJuTianBaoStore = defineStore('shuJuTianBao', () => { try { baseLoading.value = true; const res = await getBaseDropdown({}); - // debugger if (res.data && Array.isArray(res.data)) { const list = [...res.data]; // 直接赋值给 ref,触发响应式更新 diff --git a/frontend-sjgl/src/views/conventionalHydropower/shuiWenJianCe/index.vue b/frontend-sjgl/src/views/conventionalHydropower/shuiWenJianCe/index.vue index ff42f88d..038364e9 100644 --- a/frontend-sjgl/src/views/conventionalHydropower/shuiWenJianCe/index.vue +++ b/frontend-sjgl/src/views/conventionalHydropower/shuiWenJianCe/index.vue @@ -173,7 +173,6 @@ const tableScrollX = computed(() => ); const buildSearchParams = (values: any) => { - // debugger return { logic: 'and', filters: [ diff --git a/frontend-sjgl/src/views/monitorData/Export/index.vue b/frontend-sjgl/src/views/monitorData/Export/index.vue index d6801f4f..1af4598b 100644 --- a/frontend-sjgl/src/views/monitorData/Export/index.vue +++ b/frontend-sjgl/src/views/monitorData/Export/index.vue @@ -482,7 +482,6 @@ const getDict = async () => { let res = await getDictItemsByCode({ dictCode: 'dataField' }); dataFieldOption.value = res.data; formData.monitorElements = dataFieldOption.value.map(item => item.itemCode); - // debugger }; onMounted(() => { getDict(); diff --git a/frontend-sjgl/src/views/monitorData/FishData/EditFishDataAutoModal.vue b/frontend-sjgl/src/views/monitorData/FishData/EditFishDataAutoModal.vue index 7e1219bf..1b9bdd03 100644 --- a/frontend-sjgl/src/views/monitorData/FishData/EditFishDataAutoModal.vue +++ b/frontend-sjgl/src/views/monitorData/FishData/EditFishDataAutoModal.vue @@ -210,7 +210,7 @@ - + - + -
- - - - - - - - - -
- -
-
- - - -
- -
-
- - - - - - - - -
- - - - diff --git a/frontend-sjgl/src/views/monitorData/FishData/FishDataSearch.vue b/frontend-sjgl/src/views/monitorData/FishData/FishDataSearch.vue index f1312a13..c5de8cbd 100644 --- a/frontend-sjgl/src/views/monitorData/FishData/FishDataSearch.vue +++ b/frontend-sjgl/src/views/monitorData/FishData/FishDataSearch.vue @@ -57,8 +57,10 @@ @@ -77,8 +79,8 @@ const emit = defineEmits<{ (e: 'export-btn'): void; (e: 'reset', values: any): void; (e: 'search-finish', values: any): void; - (e: 'add'): void; (e: 'seeEdit'): void; + (e: 'batch-delete'): void; }>(); const basicSearchRef = ref(); @@ -86,13 +88,13 @@ const btnLoading = ref(false); const props = defineProps<{ exportLoading?: boolean; - mway: string; + selectedCount?: number; }>(); const initSearchData = { rvcd: 'all', rstcd: null, stcd: '0086601020VP000006', - mway: props.mway + mway: '1' }; const searchData = ref({ ...initSearchData }); @@ -140,6 +142,22 @@ const searchList: any = computed(() => [ value: item.stcd })) }, + { + type: 'Radio', + name: 'mway', + label: '数据类型', + width: 140, + options: [ + { + label: '人工', + value: '1' + }, + { + label: '自动', + value: '2' + } + ] + }, { type: 'custom', name: 'jcdt', @@ -157,15 +175,13 @@ const onSearchFinish = (values: any) => { const exportBtn = () => { emit('export-btn'); }; - -const handleAdd = () => { - emit('add'); -}; - const seeEdit = () => { emit('seeEdit'); }; -const initCrossSectionList = (params, setDefault = false) => { +const batchDelete = () => { + emit('batch-delete'); +}; +const initCrossSectionList = params => { const filters = []; if (params) { if (params.rvcd != '' && params.rvcd != 'all') { @@ -185,13 +201,6 @@ const initCrossSectionList = (params, setDefault = false) => { }); } } - // 根据人工/自动站过滤过鱼设施 - filters.push({ - field: 'mway', - operator: 'eq', - dataType: 'string', - value: props.mway - }); crossSectionListLoading.value = true; getFishReleaseMonitorSectionList({ filter: { @@ -202,15 +211,6 @@ const initCrossSectionList = (params, setDefault = false) => { }).then(res => { if (res.data?.data) { crossSectionList.value = res.data?.data; - // 首次加载时默认选中第一条过鱼设施 - if (setDefault && crossSectionList.value.length > 0) { - const firstStcd = crossSectionList.value[0].stcd; - initSearchData.stcd = firstStcd; - if (basicSearchRef.value?.formData) { - basicSearchRef.value.formData.stcd = firstStcd; - } - handleSearchFinish({ ...initSearchData, stcd: firstStcd }); - } } crossSectionListLoading.value = false; }); @@ -261,8 +261,9 @@ onMounted(() => { min: `${now.subtract(5, 'year').format('YYYY-MM-DD')} 00:00:00`, max: `${now.format('YYYY-MM-DD')} 23:59:59` }; - // 首次加载:请求设施列表后默认选中第一条并触发搜索 - initCrossSectionList(undefined, true); + initCrossSectionList(); + // 使用 handleSearchFinish 确保包含 jcdt 等完整参数 + handleSearchFinish({ ...initSearchData }); }); diff --git a/frontend-sjgl/src/views/monitorData/FishData/index.vue b/frontend-sjgl/src/views/monitorData/FishData/index.vue index 34aae4f5..4473c69a 100644 --- a/frontend-sjgl/src/views/monitorData/FishData/index.vue +++ b/frontend-sjgl/src/views/monitorData/FishData/index.vue @@ -1,22 +1,697 @@ - +} diff --git a/frontend-sjgl/src/views/monitorData/FishRelease/EditFishReleaseModal.vue b/frontend-sjgl/src/views/monitorData/FishRelease/EditFishReleaseModal.vue new file mode 100644 index 00000000..70a57045 --- /dev/null +++ b/frontend-sjgl/src/views/monitorData/FishRelease/EditFishReleaseModal.vue @@ -0,0 +1,28 @@ + + + diff --git a/frontend-sjgl/src/views/monitorData/FishRelease/FishReleaseDetailModal.vue b/frontend-sjgl/src/views/monitorData/FishRelease/FishReleaseDetailModal.vue new file mode 100644 index 00000000..e847e317 --- /dev/null +++ b/frontend-sjgl/src/views/monitorData/FishRelease/FishReleaseDetailModal.vue @@ -0,0 +1,420 @@ + + + diff --git a/frontend-sjgl/src/views/monitorData/FishRelease/FishReleaseSearch.vue b/frontend-sjgl/src/views/monitorData/FishRelease/FishReleaseSearch.vue index 53684e85..971248f4 100644 --- a/frontend-sjgl/src/views/monitorData/FishRelease/FishReleaseSearch.vue +++ b/frontend-sjgl/src/views/monitorData/FishRelease/FishReleaseSearch.vue @@ -59,6 +59,7 @@ @@ -97,6 +98,7 @@ const emit = defineEmits<{ (e: 'export-btn'): void; (e: 'reset', values: any): void; (e: 'search-finish', values: any): void; + (e: 'seeEdit'): void; }>(); const basicSearchRef = ref(); @@ -157,6 +159,9 @@ const onSearchFinish = (values: any) => { const exportBtn = () => { emit('export-btn'); }; +const seeEdit = () => { + emit('seeEdit'); +}; const onValuesChange = (changedValues: any, allValues: any) => { handleValuesChange(changedValues, allValues); diff --git a/frontend-sjgl/src/views/monitorData/FishRelease/index.vue b/frontend-sjgl/src/views/monitorData/FishRelease/index.vue index ff145756..f09d6eff 100644 --- a/frontend-sjgl/src/views/monitorData/FishRelease/index.vue +++ b/frontend-sjgl/src/views/monitorData/FishRelease/index.vue @@ -5,6 +5,7 @@ @export-btn="exportBtn" @search-finish="onSearchFinish" @reset="onReset" + @seeEdit="handleSeeEdit" :exportLoading="exportLoading" ref="searchRef" /> @@ -19,13 +20,36 @@ sort: sort }" > + + + + + + + diff --git a/frontend-sjgl/src/views/monitorData/FlowData/FlowDataSearch.vue b/frontend-sjgl/src/views/monitorData/FlowData/FlowDataSearch.vue index 01440908..56097142 100644 --- a/frontend-sjgl/src/views/monitorData/FlowData/FlowDataSearch.vue +++ b/frontend-sjgl/src/views/monitorData/FlowData/FlowDataSearch.vue @@ -63,6 +63,14 @@ @@ -78,13 +86,22 @@ const emit = defineEmits<{ (e: 'export-btn'): void; (e: 'reset', values: any): void; (e: 'search-finish', values: any): void; + (e: 'seeEdit'): void; + (e: 'batch-delete'): void; }>(); const basicSearchRef = ref(); const btnLoading = ref(false); -const props = defineProps<{ - exportLoading?: boolean; -}>(); +const props = withDefaults( + defineProps<{ + exportLoading?: boolean; + selectedCount?: number; + showBatchDelete?: boolean; + }>(), + { + showBatchDelete: true + } +); const initSearchData = { rvcd: 'all', @@ -185,6 +202,12 @@ const onSearchFinish = (values: any) => { const exportBtn = () => { emit('export-btn'); }; +const seeEdit = () => { + emit('seeEdit'); +}; +const batchDelete = () => { + emit('batch-delete'); +}; const onValuesChange = (changedValues: any, allValues: any) => { handleValuesChange(changedValues, allValues); diff --git a/frontend-sjgl/src/views/monitorData/FlowData/index.vue b/frontend-sjgl/src/views/monitorData/FlowData/index.vue index 0b30103f..ae13b7cf 100644 --- a/frontend-sjgl/src/views/monitorData/FlowData/index.vue +++ b/frontend-sjgl/src/views/monitorData/FlowData/index.vue @@ -5,6 +5,10 @@ @export-btn="exportBtn" @search-finish="onSearchFinish" @reset="onReset" + @seeEdit="handleSeeEdit" + @batch-delete="handleBatchDelete" + :show-batch-delete="currentSearchParams.timeScale === 'tm'" + :selected-count="selectedRowKeys.length" :exportLoading="exportLoading" ref="searchRef" /> @@ -12,6 +16,7 @@ + + + + + + + + + + diff --git a/frontend-sjgl/src/views/monitorData/fishSurveyData/fishSurveyDataSearch.vue b/frontend-sjgl/src/views/monitorData/fishSurveyData/fishSurveyDataSearch.vue new file mode 100644 index 00000000..c09002b2 --- /dev/null +++ b/frontend-sjgl/src/views/monitorData/fishSurveyData/fishSurveyDataSearch.vue @@ -0,0 +1,300 @@ + + + + + diff --git a/frontend-sjgl/src/views/monitorData/FishData/FishDataAuto.vue b/frontend-sjgl/src/views/monitorData/fishSurveyData/index.vue similarity index 80% rename from frontend-sjgl/src/views/monitorData/FishData/FishDataAuto.vue rename to frontend-sjgl/src/views/monitorData/fishSurveyData/index.vue index 32ff0de2..3c91c891 100644 --- a/frontend-sjgl/src/views/monitorData/FishData/FishDataAuto.vue +++ b/frontend-sjgl/src/views/monitorData/fishSurveyData/index.vue @@ -1,25 +1,28 @@ diff --git a/frontend/src/modules/Ysdwjc/index.vue b/frontend/src/modules/Ysdwjc/index.vue index 76ad8bfa..a5957ea5 100644 --- a/frontend/src/modules/Ysdwjc/index.vue +++ b/frontend/src/modules/Ysdwjc/index.vue @@ -221,7 +221,6 @@ const handleItemClick = (item: MediaItem) => { modelStore.params.sttp = 'WVA'; modelStore.params.stcd = item.stcd; modelStore.title = `${item.stnm} 野生动物监测`; - modelStore.isBasicEdit = true; }; // ==================== 获取站点列表 ==================== @@ -252,7 +251,6 @@ const getStationList = async () => { ] }); const list = res?.data?.data ?? []; - // debugger if (list.length) { select.value.options = list.map((item: any) => ({ label: item.stnm, diff --git a/frontend/src/modules/alongFishMod/TwoLayers/Yanchengyulei.vue b/frontend/src/modules/alongFishMod/TwoLayers/Yanchengyulei.vue index 6b43cfe6..a5d6ba4e 100644 --- a/frontend/src/modules/alongFishMod/TwoLayers/Yanchengyulei.vue +++ b/frontend/src/modules/alongFishMod/TwoLayers/Yanchengyulei.vue @@ -486,7 +486,6 @@ const getTabNumData = async () => { const res = await getTabNum(params); // getTabNum 返回格式:res.data 直接是数组 [{ty, num}, ...] const data = res?.data?.data || []; - // debugger const list = TAB_CONFIG.map(item => ({ ...item, labelWithTooltip: renderTabLabel(item.label, item.prompt) diff --git a/frontend/src/modules/chuixiangshuiwenChangeMod/index.vue b/frontend/src/modules/chuixiangshuiwenChangeMod/index.vue index d5dbe6d6..2f05adb3 100644 --- a/frontend/src/modules/chuixiangshuiwenChangeMod/index.vue +++ b/frontend/src/modules/chuixiangshuiwenChangeMod/index.vue @@ -550,7 +550,6 @@ const initChart = () => { modelStore.params.sttp = 'WTRV'; modelStore.params.enfc = '1'; modelStore.title = stnm; - // modelStore.isBasicEdit = true; modelStore.params.stcd = stcd; modelStore.filter.rangeTm = [startTime, endTime]; diff --git a/frontend/src/modules/dianzhanzhuantiMod/DZChuiXiangShuiWenBianHua/index.vue b/frontend/src/modules/dianzhanzhuantiMod/DZChuiXiangShuiWenBianHua/index.vue index a32c026e..2bede8c7 100644 --- a/frontend/src/modules/dianzhanzhuantiMod/DZChuiXiangShuiWenBianHua/index.vue +++ b/frontend/src/modules/dianzhanzhuantiMod/DZChuiXiangShuiWenBianHua/index.vue @@ -369,7 +369,6 @@ const onUpdateValues = (payload: any) => { return; } // 年份选择 - // debugger if (payload?.datetime) { yearValue.value = dayjs(payload.datetime); } diff --git a/frontend/src/modules/dianzhanzhuantiMod/DZShuiDianZhanSPJK/index.vue b/frontend/src/modules/dianzhanzhuantiMod/DZShuiDianZhanSPJK/index.vue index 365c7fd0..ed4a9d2c 100644 --- a/frontend/src/modules/dianzhanzhuantiMod/DZShuiDianZhanSPJK/index.vue +++ b/frontend/src/modules/dianzhanzhuantiMod/DZShuiDianZhanSPJK/index.vue @@ -204,7 +204,7 @@ const handleSelectMedia = (item: any) => { type: 'video', src: item.flpth || item.src || '' }; - // debugger + }; // 打开更多视频弹窗 @@ -305,7 +305,6 @@ const fetchVideoData = async (stcd: string) => { }; const videoRes = await realTimeVideo(params1); const videoData = videoRes?.data?.data || videoRes?.data || []; - // debugger const videoItems: VideoItem[] = ( Array.isArray(videoData) ? videoData : [] ).map((item: any) => ({ @@ -323,7 +322,6 @@ const fetchVideoData = async (stcd: string) => { })); videoList.value = videoItems; - // debugger currentSlide.value = 0; scrollOffset.value = 0; } catch (error) { diff --git a/frontend/src/modules/dianzhanzhuantiMod/ZXZWYYunXingShuJu/index.vue b/frontend/src/modules/dianzhanzhuantiMod/ZXZWYYunXingShuJu/index.vue index 1e8fcc87..c36c55f7 100644 --- a/frontend/src/modules/dianzhanzhuantiMod/ZXZWYYunXingShuJu/index.vue +++ b/frontend/src/modules/dianzhanzhuantiMod/ZXZWYYunXingShuJu/index.vue @@ -219,7 +219,6 @@ const fetchGardenList = async () => { const res = await getBotanicalGardenList(params); const list = res?.data?.data || []; - // debugger if (list.length === 0) return; const gardenMap = new Map(); diff --git a/frontend/src/modules/dianzhanzhuantiMod/ZenZhiZhanYunXingPG/ZenZhiZhanYunXingDetailModal.vue b/frontend/src/modules/dianzhanzhuantiMod/ZenZhiZhanYunXingPG/ZenZhiZhanYunXingDetailModal.vue index 094139f3..ff561583 100644 --- a/frontend/src/modules/dianzhanzhuantiMod/ZenZhiZhanYunXingPG/ZenZhiZhanYunXingDetailModal.vue +++ b/frontend/src/modules/dianzhanzhuantiMod/ZenZhiZhanYunXingPG/ZenZhiZhanYunXingDetailModal.vue @@ -232,7 +232,6 @@ const fetchFishDic = async () => { filter: { logic: 'and', filters: [] }, select: ['id', 'name'] }); - // debugger const data = res?.data?.data || []; fishDic.value = data.map((item: any) => ({ value: item.id, diff --git a/frontend/src/modules/dianzhanzhuantiMod/ecologicalDataMod/index.vue b/frontend/src/modules/dianzhanzhuantiMod/ecologicalDataMod/index.vue index dfaa913e..732eda9a 100644 --- a/frontend/src/modules/dianzhanzhuantiMod/ecologicalDataMod/index.vue +++ b/frontend/src/modules/dianzhanzhuantiMod/ecologicalDataMod/index.vue @@ -270,7 +270,6 @@ const fetchChartData = async () => { /** SidePanelItem @update-values */ const onUpdateValues = (payload: any) => { - // debugger if (payload?.datetime) { monthValue.value = dayjs(payload.datetime); } diff --git a/frontend/src/modules/dianzhanzhuantiMod/guoyuzongliang/index.vue b/frontend/src/modules/dianzhanzhuantiMod/guoyuzongliang/index.vue index a6274e2a..ebf1e915 100644 --- a/frontend/src/modules/dianzhanzhuantiMod/guoyuzongliang/index.vue +++ b/frontend/src/modules/dianzhanzhuantiMod/guoyuzongliang/index.vue @@ -245,7 +245,7 @@ const fetchFacilityTree = async () => { const res = await getGuoYuZongLiangFacilityTree(params); const list = res?.data?.data ?? []; - // debugger + // 转换为 moreSelect 需要的 { title, value, children } 格式 const treeData = list.map((group: any) => ({ @@ -258,7 +258,7 @@ const fetchFacilityTree = async () => { })) })); facilityTree.value = treeData; - // debugger + if (list.length > 0) { // 取第一个有 stcdVo 的组的第一个子设施作为默认 const firstGroup = list.find((g: any) => g?.items?.some((v: any) => v?.stcd)); diff --git a/frontend/src/modules/dianzhanzhuantiMod/powerStationReleasetaStistics/index.vue b/frontend/src/modules/dianzhanzhuantiMod/powerStationReleasetaStistics/index.vue index c1d9292b..cae99740 100644 --- a/frontend/src/modules/dianzhanzhuantiMod/powerStationReleasetaStistics/index.vue +++ b/frontend/src/modules/dianzhanzhuantiMod/powerStationReleasetaStistics/index.vue @@ -285,9 +285,7 @@ const fetchYear = () => { }; getPowerStationReleaseYear(params) .then((res: any) => { - // debugger const list = res?.data?.data?.[0] ?? []; - // debugger if (list.length > 0) { searchDate.value = dayjs(list[0].plansd); } else { diff --git a/frontend/src/modules/diwenshuijianhuansheshileixingzuchengjijieruqingkuang/TwoLayers/diwenshuijianhuansheshileixingzuchengjijieruqingkuangTwoLayers.vue b/frontend/src/modules/diwenshuijianhuansheshileixingzuchengjijieruqingkuang/TwoLayers/diwenshuijianhuansheshileixingzuchengjijieruqingkuangTwoLayers.vue index eb6b93a0..ea85cfac 100644 --- a/frontend/src/modules/diwenshuijianhuansheshileixingzuchengjijieruqingkuang/TwoLayers/diwenshuijianhuansheshileixingzuchengjijieruqingkuangTwoLayers.vue +++ b/frontend/src/modules/diwenshuijianhuansheshileixingzuchengjijieruqingkuang/TwoLayers/diwenshuijianhuansheshileixingzuchengjijieruqingkuangTwoLayers.vue @@ -276,7 +276,7 @@ const fetchFacilityStats = async () => { "field": "bldsttCcode", "operator": "eq", "dataType": "string", - "value": "2" + "value": formState.bldstt } : null, formState.stnm ? { "field": "stnm", @@ -334,13 +334,6 @@ const fetchBuildStateList = async () => { value: item.itemCode })) buildStateList.value.unshift({ label: '全部', value: '' }) - // 临时模拟数据(实际使用时删除) - // buildStateList.value = [ - // { label: '全部', value: '' }, - // { label: '未建', value: '0' }, - // { label: '在建', value: '1' }, - // { label: '已建', value: '2' } - // ] } catch (error) { console.error('获取建设状态列表失败:', error) } finally { @@ -399,7 +392,7 @@ const handleSearch = () => { "field": "bldsttCcode", "operator": "eq", "dataType": "string", - "value": "2" + "value": formState.bldstt } : null, formState.stnm ? { "field": "stnm", diff --git a/frontend/src/modules/fishSurvey/SurveyQingKuang/DeviceTableModal.vue b/frontend/src/modules/fishSurvey/SurveyQingKuang/DeviceTableModal.vue index b9fb5571..bf977f43 100644 --- a/frontend/src/modules/fishSurvey/SurveyQingKuang/DeviceTableModal.vue +++ b/frontend/src/modules/fishSurvey/SurveyQingKuang/DeviceTableModal.vue @@ -115,7 +115,6 @@ const fishTypeOptions = ref([]); const fetchFishTypeList = async () => { try { const res = await sdFprdRgetFishInfo(); - // debugger if (res && res?.data) { fishTypeOptions.value = res.data.map((item: any) => ({ label: item, diff --git a/frontend/src/modules/huanbaoMod/TwoLayers/HuanbaoModTwoLayers.vue b/frontend/src/modules/huanbaoMod/TwoLayers/HuanbaoModTwoLayers.vue index d47071bc..76e11004 100644 --- a/frontend/src/modules/huanbaoMod/TwoLayers/HuanbaoModTwoLayers.vue +++ b/frontend/src/modules/huanbaoMod/TwoLayers/HuanbaoModTwoLayers.vue @@ -346,7 +346,6 @@ const handleViewDetail = (record: any, type: any) => { modelStore.modalVisible = true; modelStore.params = record; modelStore.params.sttp = record.sttpCode; - // debugger modelStore.title = record.stnm; modelStore.params.stcd = record.stcd; } diff --git a/frontend/src/modules/liuyu/yichangyujing/shuizhijiancegaojing/shuizhijianceshuju.vue b/frontend/src/modules/liuyu/yichangyujing/shuizhijiancegaojing/shuizhijianceshuju.vue index 75027bcd..df9aa56e 100644 --- a/frontend/src/modules/liuyu/yichangyujing/shuizhijiancegaojing/shuizhijianceshuju.vue +++ b/frontend/src/modules/liuyu/yichangyujing/shuizhijiancegaojing/shuizhijianceshuju.vue @@ -195,7 +195,6 @@ const getCardData = async () => { const res = await getShuizhiGaojingList(params); const list = res?.data?.data || []; - // debugger const result = { normal: 0, abnormal: 0, diff --git a/frontend/src/modules/lushengshengtaijiance/index.vue b/frontend/src/modules/lushengshengtaijiance/index.vue index 5ceffbf9..19780717 100644 --- a/frontend/src/modules/lushengshengtaijiance/index.vue +++ b/frontend/src/modules/lushengshengtaijiance/index.vue @@ -135,7 +135,6 @@ const handlePanelChange = (data: any) => { const handleCardClick = (facility: any) => { console.log('卡片被点击,准备打开弹框'); - // debugger currentOrderIndex.value = facility.orderInx; modalVisible.value = true; }; diff --git a/frontend/src/modules/qixidibaohugongzuokaizhanQK/qixidiheduanjianceqingkuangEJ/index.vue b/frontend/src/modules/qixidibaohugongzuokaizhanQK/qixidiheduanjianceqingkuangEJ/index.vue index 5d23a21a..095c2793 100644 --- a/frontend/src/modules/qixidibaohugongzuokaizhanQK/qixidiheduanjianceqingkuangEJ/index.vue +++ b/frontend/src/modules/qixidibaohugongzuokaizhanQK/qixidiheduanjianceqingkuangEJ/index.vue @@ -347,7 +347,6 @@ const handleViewDetail = (record: any, type: any) => { modelStore.modalVisible = true; modelStore.params.sttp = 'VD_FBFM'; modelStore.title = '视频监控站详情信息'; - modelStore.isBasicEdit = true; modelStore.params.stcd = record.stcd; } } diff --git a/frontend/src/modules/shengtaidabiaoTwoMod/TwoLayer/STLLXFFS.vue b/frontend/src/modules/shengtaidabiaoTwoMod/TwoLayer/STLLXFFS.vue index 7b3acca6..7694f324 100644 --- a/frontend/src/modules/shengtaidabiaoTwoMod/TwoLayer/STLLXFFS.vue +++ b/frontend/src/modules/shengtaidabiaoTwoMod/TwoLayer/STLLXFFS.vue @@ -443,7 +443,6 @@ const fetchPieData = async () => { // TODO: 调用实际 API - 待补充接口 const res = await vmsstbprptGetKendoList1(obj); - // debugger if (res?.data?.data) { const dataSource = res.data.data.map((el: any) => ({ id: isAllBase ? el.baseId : el.hbrvcd, diff --git a/frontend/src/modules/shengtaidabiaoTwoMod/index.vue b/frontend/src/modules/shengtaidabiaoTwoMod/index.vue index cdf54d8b..fc8f2229 100644 --- a/frontend/src/modules/shengtaidabiaoTwoMod/index.vue +++ b/frontend/src/modules/shengtaidabiaoTwoMod/index.vue @@ -368,7 +368,6 @@ const getdate = (offsetYears = 0) => { // 提取日期部分(去除时间) startDate1 = formatDate(start); endDate1 = formatDate(end); - // debugger } else { // 否则使用默认的"一个月前到现在" const now = new Date(); @@ -595,7 +594,6 @@ watch( (newVal, oldVal) => { console.log('时间范围变化:', oldVal, '->', newVal); dateArr.value = newVal - // debugger loadData(); // 处理你的逻辑 }, diff --git a/frontend/src/modules/shengtaidabiaoTwoModJJ/TwoLayer/STLLXFFS.vue b/frontend/src/modules/shengtaidabiaoTwoModJJ/TwoLayer/STLLXFFS.vue index 053e8edb..6733d45a 100644 --- a/frontend/src/modules/shengtaidabiaoTwoModJJ/TwoLayer/STLLXFFS.vue +++ b/frontend/src/modules/shengtaidabiaoTwoModJJ/TwoLayer/STLLXFFS.vue @@ -443,7 +443,7 @@ const fetchPieData = async () => { // TODO: 调用实际 API - 待补充接口 const res = await vmsstbprptGetKendoList1(obj); - // debugger + if (res?.data?.data) { const dataSource = res.data.data.map((el: any) => ({ id: isAllBase ? el.baseId : el.hbrvcd, diff --git a/frontend/src/modules/shengtaidabiaoTwoModJJ/index.vue b/frontend/src/modules/shengtaidabiaoTwoModJJ/index.vue index bb397101..24814efe 100644 --- a/frontend/src/modules/shengtaidabiaoTwoModJJ/index.vue +++ b/frontend/src/modules/shengtaidabiaoTwoModJJ/index.vue @@ -370,7 +370,7 @@ const getdate = (offsetYears = 0) => { // 提取日期部分(去除时间) startDate1 = formatDate(start); endDate1 = formatDate(end); - // debugger + } else { // 否则使用默认的"一个月前到现在" const now = new Date(); @@ -597,7 +597,7 @@ watch( (newVal, oldVal) => { console.log('时间范围变化:', oldVal, '->', newVal); dateArr.value = newVal - // debugger + loadData(); // 处理你的逻辑 }, diff --git a/frontend/src/modules/shuiShengShengTaiDiaoCha/index.vue b/frontend/src/modules/shuiShengShengTaiDiaoCha/index.vue index 5d340902..8bdba26d 100644 --- a/frontend/src/modules/shuiShengShengTaiDiaoCha/index.vue +++ b/frontend/src/modules/shuiShengShengTaiDiaoCha/index.vue @@ -183,7 +183,7 @@ const getYearData = async () => { }; const res = await getDftYear(params); - // debugger + const data = res?.data?.data?.[0] || {}; if (Object.keys(data).length > 0) { @@ -260,7 +260,6 @@ const getChartData = async () => { }; const res = await getFishListStat(params); - // debugger chartData.value = res?.data?.data || []; nextTick(() => { updateChart(); diff --git a/frontend/src/modules/shuidianhuangjingjieruMod/TwoLayer/ShuiDianKaiFQKTwoLayer.vue b/frontend/src/modules/shuidianhuangjingjieruMod/TwoLayer/ShuiDianKaiFQKTwoLayer.vue index 27e605a1..b019e568 100644 --- a/frontend/src/modules/shuidianhuangjingjieruMod/TwoLayer/ShuiDianKaiFQKTwoLayer.vue +++ b/frontend/src/modules/shuidianhuangjingjieruMod/TwoLayer/ShuiDianKaiFQKTwoLayer.vue @@ -742,7 +742,7 @@ watch( const result = await fetchTabData(params); tabList.value = result; - // debugger + if (result.length > 0) { if (props.defaultTab) { diff --git a/frontend/src/modules/shuishengshengtaijiance/SsstdcgkTk.vue b/frontend/src/modules/shuishengshengtaijiance/SsstdcgkTk.vue index 0dda5882..549573d3 100644 --- a/frontend/src/modules/shuishengshengtaijiance/SsstdcgkTk.vue +++ b/frontend/src/modules/shuishengshengtaijiance/SsstdcgkTk.vue @@ -264,7 +264,6 @@ const getDcpcOptions = async () => { ]; const res = await getWeStaticsSecond( { filter: params, group }); - // debugger if (res?.data?.data?.length) { const options = res.data.data.map((item: any) => ({ diff --git a/frontend/src/modules/shuiwenjiancegongzuokaizhangqingkuang/shuiwenjiancegongzuoEJ.vue b/frontend/src/modules/shuiwenjiancegongzuokaizhangqingkuang/shuiwenjiancegongzuoEJ.vue index b3d56e07..9bb74545 100644 --- a/frontend/src/modules/shuiwenjiancegongzuokaizhangqingkuang/shuiwenjiancegongzuoEJ.vue +++ b/frontend/src/modules/shuiwenjiancegongzuokaizhangqingkuang/shuiwenjiancegongzuoEJ.vue @@ -519,7 +519,6 @@ const handleViewDetail = (record: any) => { modelStore.modalVisible = true; modelStore.params.sttp = "WT"; modelStore.title = record.stnm ; - // modelStore.isBasicEdit = true; if (tabIndex.value == "27") { modelStore.params.enfc = "1"; } diff --git a/frontend/src/modules/waterQuality/index.vue b/frontend/src/modules/waterQuality/index.vue index deff1af6..26d0b43e 100644 --- a/frontend/src/modules/waterQuality/index.vue +++ b/frontend/src/modules/waterQuality/index.vue @@ -27,6 +27,7 @@ import * as echarts from 'echarts'; import type { EChartsOption } from 'echarts'; import SidePanelItem from '@/components/SidePanelItem/index.vue'; import { qgcGetKendoListCust } from '@/api/sz'; +import { getMonitorDataWaterQualityDetail } from '@/api/mapModal/index'; import { useJidiSelectEventStore } from '@/store/modules/jidiSelectEvent'; import { useModelStore } from '@/store/modules/model'; import { @@ -101,49 +102,23 @@ const indicatorConfig = ref< }> >([]); -// ==================== HSL 随机颜色生成 ==================== +// ==================== 指标颜色 ==================== +// 参考 MonitorInfo.vue 的固定色板,按指标顺序循环取色,颜色稳定可预期 +const COLOR_PALETTE = [ + '#56C2E3', + '#7399C6', + '#4B79AB', + '#78C300', + '#00A050', + '#F7A737' +]; const generateRandomColor = (index: number): string => { - // 使用黄金角度确保颜色均匀分布 - const goldenAngle = 137.508; - const hue = (index * goldenAngle) % 360; - - // 饱和度控制在 45%-65% 之间 - const saturation = 45 + Math.random() * 20; - - // 亮度控制在 45%-60% 之间,避免太亮或太暗 - const lightness = 45 + Math.random() * 15; - - // HSL 转 RGB - const c = ((1 - Math.abs((2 * lightness) / 100 - 1)) * saturation) / 100; - const x = c * (1 - Math.abs(((hue / 60) % 2) - 1)); - const m = lightness / 100 - c / 2; - - let r = 0, - g = 0, - b = 0; - - if (hue < 60) { - [r, g, b] = [c, x, 0]; - } else if (hue < 120) { - [r, g, b] = [x, c, 0]; - } else if (hue < 180) { - [r, g, b] = [0, c, x]; - } else if (hue < 240) { - [r, g, b] = [0, x, c]; - } else if (hue < 300) { - [r, g, b] = [x, 0, c]; - } else { - [r, g, b] = [c, 0, x]; - } - - const toHex = (value: number) => { - const hex = Math.round((value + m) * 255).toString(16); - return hex.length === 1 ? '0' + hex : hex; - }; - - return `#${toHex(r)}${toHex(g)}${toHex(b)}`; + return COLOR_PALETTE[index % COLOR_PALETTE.length]; }; +// 指标颜色映射(来自水质参数接口 showControl.lineColor,key 为指标小写编码) +const indicatorColorMap = ref>({}); + // ==================== 动态指标筛选和配置生成 ==================== const generateIndicatorConfig = (data: StationData[]) => { if (!data || data.length === 0) { @@ -216,54 +191,15 @@ const generateIndicatorConfig = (data: StationData[]) => { .filter(ind => validKeysSet.has(ind.key)) .sort((a, b) => a.sort - b.sort); - // 生成最终配置 + // 生成最终配置:颜色优先取接口配置,缺失时回退到色板 indicatorConfig.value = validIndicators.map((ind, index) => ({ key: ind.key, name: ind.name, unit: ind.description || '', - color: generateRandomColor(index), + color: indicatorColorMap.value[ind.key] || generateRandomColor(index), sort: ind.sort })); - console.log('动态生成指标配置:', indicatorConfig.value); -}; - -// ==================== 模拟数据 ==================== -const generateMockData = () => { - const stations = [ - { stnm: '两河口', stcd: 'ST001', type: '0' }, - { stnm: '锦屏一级', stcd: 'ST002', type: '1' }, - { stnm: '桐子林', stcd: 'ST003', type: '0' }, - { stnm: '溪洛渡', stcd: 'ST004', type: '0' }, - { stnm: '向家坝', stcd: 'ST005', type: '1' }, - { stnm: '三峡', stcd: 'ST006', type: '0' }, - { stnm: '葛洲坝', stcd: 'ST007', type: '0' } - ]; - - const tm = '2024-01-15 08:00:00'; - - // 模拟限值数据 - const mockLimits = { - ph: { min: 6, max: 9 }, - dox: { min: 6 }, - codmn: { max: 4 }, - nh3n: { max: 0.5 }, - tp: { max: 0.1 }, - tn: { max: 1.0 } - }; - - return stations.map((station, index) => ({ - ...station, - tm, - SORT: index + 1, - ph: 7.2 + Math.random() * 0.8, - dox: 6.5 + Math.random() * 2.5, - codmn: 1.5 + Math.random() * 2.0, - nh3n: 0.15 + Math.random() * 0.35, - tp: 0.05 + Math.random() * 0.15, - tn: 0.8 + Math.random() * 1.2, - limits: mockLimits // 新增:存储该站点的所有限值 - })); }; // 定义数据类型接口 @@ -273,44 +209,9 @@ interface StationData { type: string; tm: string; SORT: number; - // 所有水质指标字段(动态) - ph?: number | null; - dox?: number | null; - codmn?: number | null; - codcr?: number | null; - bod5?: number | null; - nh3n?: number | null; - tp?: number | null; - tn?: number | null; - cu?: number | null; - zn?: number | null; - f?: number | null; - se?: number | null; - ars?: number | null; - hg?: number | null; - cd?: number | null; - cr6?: number | null; - pb?: number | null; - cn?: number | null; - vlph?: number | null; - oil?: number | null; - las?: number | null; - s2?: number | null; - fcg?: number | null; - cl?: number | null; - so4?: number | null; - no3?: number | null; - thrd?: number | null; - cond?: number | null; - fe?: number | null; - mn?: number | null; - al?: number | null; - chla?: number | null; - clarity?: number | null; - tu?: number | null; - wtmp?: number | null; limits: Record; - [key: string]: any; // 允许任意水质指标字段 + // 水质指标字段为动态生成,通过索引签名访问 + [key: string]: any; } const mockData = ref([]); @@ -637,17 +538,11 @@ const handleLegendSelectChanged = (params: any) => { const clickedName = name; const isNowSelected = selected[clickedName]; - console.log( - `图例点击: ${clickedName}, 当前状态: ${isNowSelected ? '显示' : '隐藏'}` - ); - console.log('当前可见队列:', visibleSeriesQueue.value); - if (isNowSelected) { // 用户想要显示这个系列 if (visibleSeriesQueue.value.length >= 2) { // 已满2个,移除最早的(队列头部) - const removed = visibleSeriesQueue.value.shift(); - console.log(`已达上限,移除最早系列: ${removed}`); + visibleSeriesQueue.value.shift(); } // 添加到队列尾部 if (!visibleSeriesQueue.value.includes(clickedName)) { @@ -658,135 +553,23 @@ const handleLegendSelectChanged = (params: any) => { const index = visibleSeriesQueue.value.indexOf(clickedName); if (index > -1) { visibleSeriesQueue.value.splice(index, 1); - console.log(`从队列中移除: ${clickedName}`); } } - console.log('更新后可见队列:', visibleSeriesQueue.value); - - // 根据队列构建最终的 selected 状态 - const finalSelected: Record = {}; - indicatorConfig.value.forEach(config => { - finalSelected[config.name] = visibleSeriesQueue.value.includes(config.name); - }); - - // 深拷贝当前配置 - const currentOption = JSON.parse(JSON.stringify(chartInstance.getOption())); - - // 同步图例选中状态 - currentOption.legend[0].selected = finalSelected; - - // 根据图例状态更新 Y 轴显隐 - const newYAxis = currentOption.yAxis.map((item: any) => { - let isShow = false; - let displayIndex = 0; - - // 计算这是第几个显示的Y轴 - for (const key in finalSelected) { - if (finalSelected[key]) { - const config = indicatorConfig.value.find(c => c.name === key); - if (config && config.name === item.name) { - isShow = true; - break; - } - displayIndex++; - } - } - - // 最多只显示2个Y轴 - if (!isShow || displayIndex >= 2) { - return { ...item, show: false }; - } - - return { ...item, show: true }; - }); - - currentOption.yAxis = newYAxis; - - // 动态调整 Y 轴布局 - yAxisShowDynamic(finalSelected, currentOption); - - // 完全替换模式更新 + // 基于最新队列重新生成完整配置(所有 y 轴都带颜色/formatter/min-max, + // 避免从 getOption() 快照激活隐藏 y 轴时丢失样式导致颜色消失、宽度变化) try { - chartInstance.setOption(currentOption, true); - console.log('图表配置已更新'); + const option = getChartOption(); + chartInstance.setOption(option, true); } catch (error) { console.error('图表更新失败:', error); } }; -// ==================== Y轴动态布局调整 ==================== -const yAxisShowDynamic = (selected: Record, options: any) => { - const allShow = options.yAxis?.filter((item: any) => item.show); - const showCount = allShow?.length || 0; - - // 没有显示的Y轴 - if (showCount === 0) { - return; - } - - // 只有一个Y轴:统一置于左侧 - if (showCount === 1) { - delete options.grid.right; - options.grid.left = '80px'; - - options.yAxis = options.yAxis.map((item: any) => { - if (item.show) { - return { - ...item, - position: 'left', - offset: 0 - }; - } - return item; - }); - return; - } - - // 两个Y轴:左侧1个,右侧1个 - if (showCount >= 2) { - let leftAssigned = false; - let rightAssigned = false; - - options.yAxis = options.yAxis.map((item: any) => { - if (!item.show) { - return item; - } - - // 第一个可见的Y轴放在左侧 - if (!leftAssigned) { - leftAssigned = true; - delete options.grid.right; - options.grid.left = '80px'; - - return { - ...item, - position: 'left', - offset: 0 - }; - } else if (!rightAssigned) { - // 第二个Y轴放在右侧 - rightAssigned = true; - options.grid.right = '60px'; - return { - ...item, - position: 'right', - offset: 0 - }; - } else { - // 第三个及以后的Y轴隐藏(理论上不应该到这里) - return { - ...item, - show: false - }; - } - }); - } -}; - // ==================== 数据点点击事件处理 ==================== const handleDataPointClick = (params: any) => { - if (!params || !params.dataIndex) return; + // dataIndex 为 0 时不能直接取反判断,必须判断 null/undefined + if (!params || params.dataIndex == null) return; // 获取点击的数据点对应的站点信息 const dataIndex = params.dataIndex; @@ -796,7 +579,6 @@ const handleDataPointClick = (params: any) => { modelStore.modalVisible = true; modelStore.params.sttp = 'WQFB'; modelStore.title = stationData.stnm; - // modelStore.isBasicEdit = true; modelStore.params.stcd = stationData.stcd; modelStore.filter.rangeTm = [ dayjs(datetimePicker.value.value) @@ -821,8 +603,6 @@ const getecharts = async () => { return; } - console.log('开始获取图表数据,select.value:', select.value.value); - // 设置 loading 状态 loading.value = true; hasData.value = false; @@ -882,8 +662,6 @@ const getecharts = async () => { } } - console.log('原始数据条数:', apiData.length); - // 过滤出有水质数据的站点(sttp === 'WQ')并按sort排序 const filteredData = apiData .filter((item: any) => item.sttp === 'WQ') @@ -931,47 +709,20 @@ const getecharts = async () => { }); } + // 动态收集指标字段(基于 indicators 配置,避免硬编码 30+ 个字段映射) + const indicatorValues: Record = {}; + indicators.forEach(ind => { + const val = item[ind.key]; + indicatorValues[ind.key] = val != null ? Number(val) : null; + }); + return { stnm: stnm, stcd: item.stcd || '', type: item.rstcd ? '1' : '0', // 有rstcd表示是电站出库站 tm: item.tm || '', SORT: index + 1, - ph: item.ph != null ? Number(item.ph) : null, - dox: item.dox != null ? Number(item.dox) : null, - codmn: item.codmn != null ? Number(item.codmn) : null, - codcr: item.codcr != null ? Number(item.codcr) : null, - bod5: item.bod5 != null ? Number(item.bod5) : null, - nh3n: item.nh3n != null ? Number(item.nh3n) : null, - tp: item.tp != null ? Number(item.tp) : null, - tn: item.tn != null ? Number(item.tn) : null, - cu: item.cu != null ? Number(item.cu) : null, - zn: item.zn != null ? Number(item.zn) : null, - f: item.f != null ? Number(item.f) : null, - se: item.se != null ? Number(item.se) : null, - ars: item.ars != null ? Number(item.ars) : null, - hg: item.hg != null ? Number(item.hg) : null, - cd: item.cd != null ? Number(item.cd) : null, - cr6: item.cr6 != null ? Number(item.cr6) : null, - pb: item.pb != null ? Number(item.pb) : null, - cn: item.cn != null ? Number(item.cn) : null, - vlph: item.vlph != null ? Number(item.vlph) : null, - oil: item.oil != null ? Number(item.oil) : null, - las: item.las != null ? Number(item.las) : null, - s2: item.s2 != null ? Number(item.s2) : null, - fcg: item.fcg != null ? Number(item.fcg) : null, - cl: item.cl != null ? Number(item.cl) : null, - so4: item.so4 != null ? Number(item.so4) : null, - no3: item.no3 != null ? Number(item.no3) : null, - thrd: item.thrd != null ? Number(item.thrd) : null, - cond: item.cond != null ? Number(item.cond) : null, - fe: item.fe != null ? Number(item.fe) : null, - mn: item.mn != null ? Number(item.mn) : null, - al: item.al != null ? Number(item.al) : null, - chla: item.chla != null ? Number(item.chla) : null, - clarity: item.clarity != null ? Number(item.clarity) : null, - tu: item.tu != null ? Number(item.tu) : null, - wtmp: item.wtmp != null ? Number(item.wtmp) : null, + ...indicatorValues, limits: limits // 新增:存储该站点的所有限值 }; }); @@ -992,12 +743,42 @@ const getecharts = async () => { return; } + // 获取水质参数配置(showControl.lineColor),用于指标颜色 + // 参考 WaterQuality.vue:颜色来自接口返回的每个参数配置 + try { + const configStcd = modelStore.params.stcd || chartData[0]?.stcd; + if (configStcd) { + const detailRes = await getMonitorDataWaterQualityDetail({ + stcd: configStcd, + tbCode: 'WQ_R', + startTime: getStartTime(), + endTime: getEndTime() + }); + const detailData = detailRes?.data?.data || detailRes?.data || []; + const map: Record = {}; + detailData.forEach((param: any) => { + if (!param.ys) return; + try { + const config = JSON.parse(param.showControl || '{}'); + if (config.lineColor) { + map[param.ys.toLowerCase()] = config.lineColor; + } + } catch { + // 解析失败忽略该参数 + } + }); + indicatorColorMap.value = map; + } + } catch (error) { + // 配置获取失败不影响主流程,颜色走色板回退 + console.error('获取水质参数配置失败:', error); + } + // 动态生成指标配置 generateIndicatorConfig(chartData); // 如果没有有效指标,显示空状态 if (indicatorConfig.value.length === 0) { - console.log('没有有效指标,显示空状态'); hasData.value = false; chartInstance?.clear(); loading.value = false; @@ -1101,7 +882,6 @@ const initChart = async () => { // 初始化可见队列:默认只显示第一个系列(按sort排序后的第一个) visibleSeriesQueue.value = [indicatorConfig.value[0].name]; - console.log('初始化可见队列:', visibleSeriesQueue.value); // 初始化 ECharts 实例 chartInstance = echarts.init(chartRef.value); @@ -1178,7 +958,6 @@ const wbsCode = ref(''); watch( () => stationSource.value, newVal => { - console.log(newVal); wbsCode.value = newVal.wbsCode; select.value.value = newVal.wbsCode; getecharts(); @@ -1199,22 +978,7 @@ watch( { deep: true, immediate: true } ); -// 监听可见系列数量变化,重新设置图表配置以确保 tooltip formatter 使用最新的 visibleSeriesQueue 值 -watch( - () => visibleSeriesQueue.value.length, - (newLength, oldLength) => { - // 只有当长度真正变化时才重新设置 - if ( - newLength !== oldLength && - chartInstance && - indicatorConfig.value.length > 0 - ) { - // 重新生成 option(这会创建新的 formatter 闭包,捕获最新的 visibleSeriesQueue) - const newOption = getChartOption(); - chartInstance.setOption(newOption, true); - } - } -); +// 图例切换时 handleLegendSelectChanged 已基于最新队列重建完整配置,此处无需再监听 diff --git a/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/FishDataManual.vue b/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/FishDataManual.vue deleted file mode 100644 index b69f5574..00000000 --- a/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/FishDataManual.vue +++ /dev/null @@ -1,369 +0,0 @@ - - - - diff --git a/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/FishDataSearch.vue b/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/FishDataSearch.vue index de348c95..b33493e8 100644 --- a/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/FishDataSearch.vue +++ b/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/FishDataSearch.vue @@ -80,13 +80,12 @@ const btnLoading = ref(false); const props = defineProps<{ exportLoading?: boolean; - mway: string; }>(); const initSearchData = { rvcd: 'all', rstcd: null, stcd: '0086601020VP000006', - mway: props.mway + mway: '1' }; const searchData = ref({ ...initSearchData }); @@ -134,6 +133,22 @@ const searchList: any = computed(() => [ value: item.stcd })) }, + { + type: 'Radio', + name: 'mway', + label: '数据类型', + width: 140, + options: [ + { + label: '人工', + value: '1' + }, + { + label: '自动', + value: '2' + } + ] + }, { type: 'custom', name: 'jcdt', diff --git a/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/index.vue b/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/index.vue index 42facee3..421d1faa 100644 --- a/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/index.vue +++ b/frontend/src/views/DataQueryMenuModule/components/monitorData/FishData/index.vue @@ -1,42 +1,551 @@ - - + diff --git a/frontend/src/views/dianZhanZhuanTi/components/DZShuiDianZhanSPJK.vue b/frontend/src/views/dianZhanZhuanTi/components/DZShuiDianZhanSPJK.vue index 365c7fd0..2e968c0e 100644 --- a/frontend/src/views/dianZhanZhuanTi/components/DZShuiDianZhanSPJK.vue +++ b/frontend/src/views/dianZhanZhuanTi/components/DZShuiDianZhanSPJK.vue @@ -204,7 +204,6 @@ const handleSelectMedia = (item: any) => { type: 'video', src: item.flpth || item.src || '' }; - // debugger }; // 打开更多视频弹窗 @@ -305,7 +304,6 @@ const fetchVideoData = async (stcd: string) => { }; const videoRes = await realTimeVideo(params1); const videoData = videoRes?.data?.data || videoRes?.data || []; - // debugger const videoItems: VideoItem[] = ( Array.isArray(videoData) ? videoData : [] ).map((item: any) => ({ @@ -323,7 +321,6 @@ const fetchVideoData = async (stcd: string) => { })); videoList.value = videoItems; - // debugger currentSlide.value = 0; scrollOffset.value = 0; } catch (error) { diff --git a/frontend/src/views/dianZhanZhuanTi/components/ZenZhiZhanYunXingDetailModal.vue b/frontend/src/views/dianZhanZhuanTi/components/ZenZhiZhanYunXingDetailModal.vue index 094139f3..ff561583 100644 --- a/frontend/src/views/dianZhanZhuanTi/components/ZenZhiZhanYunXingDetailModal.vue +++ b/frontend/src/views/dianZhanZhuanTi/components/ZenZhiZhanYunXingDetailModal.vue @@ -232,7 +232,6 @@ const fetchFishDic = async () => { filter: { logic: 'and', filters: [] }, select: ['id', 'name'] }); - // debugger const data = res?.data?.data || []; fishDic.value = data.map((item: any) => ({ value: item.id, diff --git a/frontend/src/views/dianZhanZhuanTi/components/powerStationReleasetaStistics.vue b/frontend/src/views/dianZhanZhuanTi/components/powerStationReleasetaStistics.vue index ca80441b..32afa9c9 100644 --- a/frontend/src/views/dianZhanZhuanTi/components/powerStationReleasetaStistics.vue +++ b/frontend/src/views/dianZhanZhuanTi/components/powerStationReleasetaStistics.vue @@ -285,9 +285,7 @@ const fetchYear = () => { }; getPowerStationReleaseYear(params) .then((res: any) => { - // debugger const list = res?.data?.data?.[0] ?? []; - // debugger if (list.length > 0) { searchDate.value = dayjs(list[0].plansd); } else { diff --git a/frontend/src/views/shengTaiDiaoCha/shuiShengShengTaiDiaoCha/SSSTDCDB.vue b/frontend/src/views/shengTaiDiaoCha/shuiShengShengTaiDiaoCha/SSSTDCDB.vue index 85d16a9a..abd2603c 100644 --- a/frontend/src/views/shengTaiDiaoCha/shuiShengShengTaiDiaoCha/SSSTDCDB.vue +++ b/frontend/src/views/shengTaiDiaoCha/shuiShengShengTaiDiaoCha/SSSTDCDB.vue @@ -190,7 +190,6 @@ const fetchChartData = async () => { } }; const res: any = await getCompareBar(params); - // debugger if (res?.data?.data?.[0]?.dataSource) { chartList.value = res.data.data[0].dataSource; } else { diff --git a/frontend/src/views/system/ConfigManagement/index.vue b/frontend/src/views/system/ConfigManagement/index.vue index 72994059..c379c4e4 100644 --- a/frontend/src/views/system/ConfigManagement/index.vue +++ b/frontend/src/views/system/ConfigManagement/index.vue @@ -185,7 +185,6 @@ const handleEdit = async (record: any) => { const firstLevelNodes = data.filter((item: any) => !item.rstcd); const secondLevelNodes = data.filter((item: any) => item.rstcd); - // debugger const configNodes = firstLevelNodes.map((node: any, index: number) => { const children = secondLevelNodes.filter( (child: any) => child.rstcd === node.stcd @@ -216,7 +215,6 @@ const handleEdit = async (record: any) => { }); currentRecord.value.configNodes = configNodes; - // debugger } editModalVisible.value = true; }; diff --git a/frontend/src/views/system/TiltPhotoManagement/index.vue b/frontend/src/views/system/TiltPhotoManagement/index.vue index d16c9d08..f86b8280 100644 --- a/frontend/src/views/system/TiltPhotoManagement/index.vue +++ b/frontend/src/views/system/TiltPhotoManagement/index.vue @@ -211,7 +211,6 @@ const editModalCancel = () => { // 表单提交 const handleEditSubmit = async (values: any) => { - // debugger try { let res = await saveTiltPhoto({ ...currentRecord.value, diff --git a/frontend/src/views/system/alertRules/components/ConfigManagement/ConfigManagementForm.vue b/frontend/src/views/system/alertRules/components/ConfigManagement/ConfigManagementForm.vue index a194ffde..df68fc2a 100644 --- a/frontend/src/views/system/alertRules/components/ConfigManagement/ConfigManagementForm.vue +++ b/frontend/src/views/system/alertRules/components/ConfigManagement/ConfigManagementForm.vue @@ -367,7 +367,6 @@ const fetchFacilityOptions = async (stationCode: string) => { } else if (formData.ruleType === 'WQ_RULE') { params.filter.filters[1].value = ['WQ']; const res: any = await getMonitorDataWq(params); - // debugger const list = res?.data?.data || []; facilityOptions.value = list.map((item: any) => ({ value: item.stcd , label: item.stnm, stcd: item.stcd })); } else { @@ -514,10 +513,9 @@ const filterOption = (inputValue: string, option: any) => { }; const ennmOptions = ref([]); const handleRiverSelect = async (value: any) => { - // debugger - // + let res: any = await getDictItemsByCode({ dictCode: 'WWQTG' }); - // + if (res?.data?.length > 0) { res.data.forEach((item: any) => { item.value = item.itemCode; diff --git a/frontend/src/views/system/alertRules/components/RulesManagement/LayerManagementForm.vue b/frontend/src/views/system/alertRules/components/RulesManagement/LayerManagementForm.vue index b7a15c91..804f5c43 100644 --- a/frontend/src/views/system/alertRules/components/RulesManagement/LayerManagementForm.vue +++ b/frontend/src/views/system/alertRules/components/RulesManagement/LayerManagementForm.vue @@ -239,7 +239,6 @@ const ennmOptions = ref([]); const handleRiverSelect = async (value: any) => { // let res: any = await getDictItemsByCode({ dictCode: 'WWQTG' }); - // debugger if (res?.data?.length > 0) { res.data.forEach((item: any) => { item.value = item.itemCode; diff --git a/frontend/src/views/system/user/index.vue b/frontend/src/views/system/user/index.vue index 1dc3931d..ad50a0a0 100644 --- a/frontend/src/views/system/user/index.vue +++ b/frontend/src/views/system/user/index.vue @@ -47,6 +47,12 @@ const dialog = ref(false); const treeRef = ref(); const fishTreeRef = ref(); const infoForm = ref(); +//所属组织树型下拉框字段映射 +const treeSelectProps = { + value: 'id', + label: 'orgname', + children: 'childList' +}; //获取企业树形信息 const treeloading = ref(true); function getTree() { @@ -99,7 +105,8 @@ function addClick() { nickname: '', email: '', phone: '', - roleinfo: [] + roleinfo: [], + orgid: '' }; getrole(); } @@ -178,7 +185,8 @@ const info = ref({ nickname: '', email: '', phone: '', - roleinfo: [] as any[] + roleinfo: [] as any[], + orgid: '' }); //修改-用户 function editdepartment(row: any) { @@ -188,6 +196,8 @@ function editdepartment(row: any) { }); info.value = JSON.parse(JSON.stringify(row)); info.value.roleinfo = selectID; + // 回显所属组织 + info.value.orgid = row.orgid; rolesdata.value = row.roles; title.value = '修改用户'; dialogVisible.value = true; @@ -207,7 +217,8 @@ function confirmClick(formEl: any) { nickname: info.value.nickname, email: info.value.email, phone: info.value.phone, - orgid: orgId.value + // 修改时根据所属组织树型下拉框传递 + orgid: info.value.orgid }; const roleids = String(info.value.roleinfo); updataUser(params, roleids).then(() => { @@ -787,7 +798,6 @@ function getrole() { rolename: '' }; listGroupedByTenant(params).then(res => { - // debugger rolesdata.value = res; }); } @@ -1274,6 +1284,17 @@ function handleClearSelection() { + + + +