bug更改

This commit is contained in:
王兴凯 2026-07-16 14:40:20 +08:00
parent 87781537f9
commit b78e578c46
9 changed files with 163 additions and 29 deletions

View File

@ -54,7 +54,7 @@ export function getFishTab(stcd: string) {
// 检查水质站是否启用 AI 预测功能 // 检查水质站是否启用 AI 预测功能
export function checkAnalysisShow(data: any) { export function checkAnalysisShow(data: any) {
return request({ return request({
url: '/api/dec-lygk-base-server/base/vmsstbprpt/GetKendoList', url: '/overview/vmsstbprpt/GetKendoList',
method: 'post', method: 'post',
data data
}); });

View File

@ -128,7 +128,7 @@ export function dwInfoGetKendoListCust(data: any) {
data data
}); });
} }
//月均水温对比,图表,表格 /api/wmp-env-server/sw/monthDetail/Det/GetKendoListCust //月均水温对比,图表,表格
export function DetGetKendoListCust(data: any) { export function DetGetKendoListCust(data: any) {
return request({ return request({
url: '/wt/monthDetail/Det/GetKendoListCust', url: '/wt/monthDetail/Det/GetKendoListCust',

View File

@ -1,23 +1,23 @@
import request from '@/utils/request'; import request from '@/utils/request';
// 获取所有沿程配置数据 // 飞行路径
export function threedroambGetKendoListCust(data: any) { export function threedroambGetKendoListCust(data: any) {
return request({ return request({
url: '/api/wmp-sys-server/sys/threedroamb/GetKendoListCust', url: '/threedroamb/GetKendoListCust',
method: 'post', method: 'post',
data: data data: data
}); });
} }
export function threedroambsave(data: any) { export function threedroambsave(data: any) {
return request({ return request({
url: '/api/wmp-sys-server/sys/threedroamb/save', url: '/threedroamb/save',
method: 'post', method: 'post',
data: data data: data
}); });
} }
export function threedroambdelete(data: any) { export function threedroambdelete(data: any) {
return request({ return request({
url: '/api/wmp-sys-server/sys/threedroamb/delete', url: '/threedroamb/delete',
method: 'get', method: 'get',
params: data params: data
}); });
@ -25,7 +25,7 @@ export function threedroambdelete(data: any) {
//根据id查询弹窗 //根据id查询弹窗
export function threedroambGetKendoById(data: any) { export function threedroambGetKendoById(data: any) {
return request({ return request({
url: '/api/wmp-sys-server/sys/threedroamb/getThreedRoamDetails', url: '/threedroamb/getThreedRoamDetails',
method: 'get', method: 'get',
params: data params: data
}); });
@ -33,7 +33,7 @@ export function threedroambGetKendoById(data: any) {
// 导入接口 // 导入接口
export function threedroambimport(data: FormData) { export function threedroambimport(data: FormData) {
return request({ return request({
url: '/api/wmp-sys-server/sys/threedroamb/import', url: '/threedroamb/import',
method: 'post', method: 'post',
data: data, data: data,
headers: { 'Content-Type': 'multipart/form-data' } headers: { 'Content-Type': 'multipart/form-data' }
@ -42,7 +42,7 @@ export function threedroambimport(data: FormData) {
// 导出模板 // 导出模板
export function threedroambexport(data: any) { export function threedroambexport(data: any) {
return request({ return request({
url: '/api/wmp-sys-server/sys/threedroamb/export', url: '/threedroamb/export',
method: 'post', method: 'post',
data: data, data: data,
responseType: 'blob' responseType: 'blob'

View File

@ -49,3 +49,11 @@ export function saveBaseWbsbChildDetail(data: any) {
data: data data: data
}); });
} }
//站点类型下拉框
export function sttpGetKendoList(data: any) {
return request({
url: '/base/msalongb/sttp/GetKendoList',
method: 'post',
data: data
});
}

View File

@ -231,12 +231,77 @@ const loadRecordList = async () => {
}; };
const res: any = await getVideoPlayDetail(params); const res: any = await getVideoPlayDetail(params);
if (res?.data?.data) { if (res?.data?.data.length >0) {
recordList.value = res.data.data; recordList.value = res.data.data;
recordTotal.value = res.data.total || 0; recordTotal.value = res.data.total || 0;
} else { } else {
recordList.value = []; //
recordTotal.value = 0; const params1 = {
filter: {
logic: 'and',
filters: [
{
field: 'stcd',
operator: 'in',
value: [selectedStcd.value]
}
]
},
sort: [
{
field: 'tm',
dir: 'desc'
}
]
};
let res1 = await getVideoDetail(params1);
if (res1.data.data.length > 0) {
// tm
const tm = res1.data.data[0].tm;
const endTime = dayjs(tm);
const startTime = endTime.subtract(7, 'day');
dateRange.value = [startTime, endTime];
// getVideoPlayDetail
const newParams = {
filter: {
logic: 'and',
filters: [
{
field: 'stcd',
operator: 'in',
value: [selectedStcd.value]
},
{
field: 'tm',
operator: 'gte',
dataType: 'date',
value: startTime.format('YYYY-MM-DD 00:00:00')
},
{
field: 'tm',
operator: 'lte',
dataType: 'date',
value: endTime.format('YYYY-MM-DD 23:59:59')
}
]
},
sort: [{ field: 'tm', dir: 'desc' }],
skip: 0,
take: pageSize
};
const res2 = await getVideoPlayDetail(newParams);
if (res2?.data?.data?.length > 0) {
recordList.value = res2.data.data;
recordTotal.value = res2.data.total || 0;
} else {
recordList.value = [];
recordTotal.value = 0;
}
} else {
recordList.value = [];
recordTotal.value = 0;
}
} }
} catch (error) { } catch (error) {
recordList.value = []; recordList.value = [];

View File

@ -103,7 +103,7 @@
:default-expand-all="false" :default-expand-all="false"
:selectable="false" :selectable="false"
block-node block-node
style="width: 400px"
> >
<template #title="{ dataRef }"> <template #title="{ dataRef }">
<!-- 编辑状态只显示编辑区域 --> <!-- 编辑状态只显示编辑区域 -->
@ -364,6 +364,15 @@ const refreshNodeSort = (nodes: any[]) => {
const checkDuplicateStcd = (stcd: string, siblings: any[], excludeKey?: string): boolean => { const checkDuplicateStcd = (stcd: string, siblings: any[], excludeKey?: string): boolean => {
return siblings.some(node => node.stcd === stcd && node.key !== excludeKey); return siblings.some(node => node.stcd === stcd && node.key !== excludeKey);
}; };
// +
const checkDuplicateSttpDirection = (sttpName: string, type: number, siblings: any[], excludeKey?: string): boolean => {
return siblings.some(node =>
node.sttpName === sttpName &&
(node.type == 1 || node.ioDirection == 1) === (type == 1) &&
node.key !== excludeKey
);
};
const handleRiverSelect = async (value: string) => { const handleRiverSelect = async (value: string) => {
const res = await getEngInfoDropdown({ baseId: value }); const res = await getEngInfoDropdown({ baseId: value });
stationList.value = (res.data || []).map((item: any) => ({ stationList.value = (res.data || []).map((item: any) => ({
@ -376,7 +385,9 @@ const getNodeTitle = (dataRef: any) => {
if (!dataRef.parentId) { if (!dataRef.parentId) {
return dataRef.ennm || ''; return dataRef.ennm || '';
} else { } else {
return `${dataRef.stnm ||dataRef.ennm || ''}-${dataRef.type == 1 || dataRef.ioDirection == 1 ? '出库' : '入库'}`; const direction = dataRef.type == 1 || dataRef.ioDirection == 1 ? '出库' : '入库';
const sttp = dataRef.sttpName || '';
return sttp ? `${dataRef.stnm || dataRef.ennm || ''}-${sttp}-${direction}` : `${dataRef.stnm || dataRef.ennm || ''}-${direction}`;
} }
}; };
@ -580,8 +591,8 @@ const handleStationSelectConfirm = (data: { record: any; type: number }) => {
const siblings = node.parentId const siblings = node.parentId
? findNodeByKey(treeData.value, node.parentId)?.children || [] ? findNodeByKey(treeData.value, node.parentId)?.children || []
: treeData.value; : treeData.value;
if (checkDuplicateStcd(data.record.stcd, siblings, editingNodeKey.value!)) { if (checkDuplicateSttpDirection(data.record.sttpName, data.type, siblings, editingNodeKey.value!)) {
message.warning('该站点在当前层级已存在,请重新选择'); message.warning('该测站类型在当前方向已存在,请重新选择');
return; return;
} }
@ -601,8 +612,8 @@ const handleStationSelectConfirm = (data: { record: any; type: number }) => {
message.error('父节点不存在'); message.error('父节点不存在');
return; return;
} }
if (checkDuplicateStcd(data.record.stcd, parent.children || [])) { if (checkDuplicateSttpDirection(data.record.sttpName, data.type, parent.children || [])) {
message.warning('该站点在当前层级已存在,请勿重复添加'); message.warning('该测站类型在当前方向已存在,请勿重复添加');
return; return;
} }
const newChild = { const newChild = {
@ -803,18 +814,19 @@ defineExpose({
.tree-node-wrapper { .tree-node-wrapper {
display: flex; display: flex;
justify-content: space-between;
align-items: center; align-items: center;
width: 100%; width: 100%;
padding-right: 8px; padding-right: 8px;
.tree-node-title { .tree-node-title {
flex: 1;
} }
.tree-node-actions { .tree-node-actions {
opacity: 0; opacity: 0;
transition: opacity 0.2s; transition: opacity 0.2s;
margin-left: 18px;
} }
} }

View File

@ -10,7 +10,7 @@
> >
<!-- 搜索表单 --> <!-- 搜索表单 -->
<a-form layout="inline" class="search-form"> <a-form layout="inline" class="search-form">
<a-form-item label="名称"> <a-form-item label="测站名称">
<a-input <a-input
v-model:value="searchName" v-model:value="searchName"
placeholder="请输入测站名称" placeholder="请输入测站名称"
@ -19,8 +19,20 @@
@press-enter="handleSearch" @press-enter="handleSearch"
/> />
</a-form-item> </a-form-item>
<a-form-item label="测站类型">
<a-select
v-model:value="sttpCode"
show-search
placeholder="请选择测站类型"
style="width: 200px"
:options="sttpCodeoptions"
:filter-option="sttpFilterOption"
allow-clear
></a-select>
</a-form-item>
<a-form-item> <a-form-item>
<a-button type="primary" @click="handleSearch">查询</a-button> <a-button type="primary" @click="handleSearch">查询</a-button>
<a-button @click="handleReset" style="margin-left: 8px">重置</a-button>
</a-form-item> </a-form-item>
</a-form> </a-form>
@ -69,7 +81,7 @@
import { ref, computed, watch } from 'vue'; import { ref, computed, watch } from 'vue';
import { noAuthGetKendoPage } from '@/api/select'; import { noAuthGetKendoPage } from '@/api/select';
import BasicTable from '@/components/BasicTable/index.vue'; import BasicTable from '@/components/BasicTable/index.vue';
import { sttpGetKendoList } from '@/api/system/map/ConfigManagement';
interface Props { interface Props {
visible: boolean; visible: boolean;
baseId: string; baseId: string;
@ -84,10 +96,13 @@ const emit = defineEmits<{
(e: 'update:visible', value: boolean): void; (e: 'update:visible', value: boolean): void;
(e: 'confirm', data: { record: any; type: number }): void; (e: 'confirm', data: { record: any; type: number }): void;
}>(); }>();
// label
const sttpFilterOption = (input: string, option: any) => {
return option.label?.toLowerCase().indexOf(input.toLowerCase()) >= 0;
};
// //
const searchName = ref(''); const searchName = ref('');
const sttpCode = ref('');
// //
const tableRef = ref(); const tableRef = ref();
const selectedRow = ref<any>(null); const selectedRow = ref<any>(null);
@ -142,7 +157,13 @@ const handleSearch = () => {
dataType: 'string', dataType: 'string',
value: props.baseId value: props.baseId
} }
: null : null,
{
field: 'STTP',
operator: 'neq',
dataType: 'string',
value: 'ENG'
}
].filter(Boolean); ].filter(Boolean);
if (searchName.value) { if (searchName.value) {
filters.push({ filters.push({
@ -151,6 +172,15 @@ const handleSearch = () => {
value: searchName.value value: searchName.value
}); });
} }
if(sttpCode.value){
filters.push({
field: 'STTP_CODE',
operator: 'eq',
dataType: 'string',
value: sttpCode.value
});
}
const filter = { const filter = {
logic: 'and', logic: 'and',
filters filters
@ -158,14 +188,33 @@ const handleSearch = () => {
tableRef.value?.getList(filter); tableRef.value?.getList(filter);
}; };
//
const handleReset = () => {
searchName.value = '';
sttpCode.value = '';
handleSearch();
};
const sttpCodeoptions = ref([]);
const getsttpGetKendoList = async () => {
let res = await sttpGetKendoList({});
sttpCodeoptions.value = res.data.data.map(item => {
return {
label: item.sttpName,
value: item.sttpCode
};
});
};
// //
watch( watch(
() => props.visible, () => props.visible,
visible => { visible => {
if (visible) { if (visible) {
searchName.value = ''; searchName.value = '';
sttpCode.value = '';
// DOM // DOM
setTimeout(() => handleSearch(), 0); setTimeout(() => handleSearch(), 0);
getsttpGetKendoList();
} }
} }
); );

View File

@ -211,11 +211,12 @@ const editModalCancel = () => {
// //
const handleEditSubmit = async (values: any) => { const handleEditSubmit = async (values: any) => {
// debugger
try { try {
let res = await saveTiltPhoto({ let res = await saveTiltPhoto({
...currentRecord.value, ...currentRecord.value,
...values, ...values,
recordTime:currentRecord.value.recordTime != '-' ? currentRecord.value.recordTime : null
}); });
message.success(`保存成功`); message.success(`保存成功`);

View File

@ -1,8 +1,7 @@
<!-- d:\wordpack\WholeProcessPlatform\frontend\src\views\system\map\components\LayerManagement\index.vue --> <!-- d:\wordpack\WholeProcessPlatform\frontend\src\views\system\map\components\LayerManagement\index.vue -->
<template> <template>
<div class="content"> <div class="content">
预警规则 <LayerManagementSearch
<!-- <LayerManagementSearch
ref="layerManagementSearch" ref="layerManagementSearch"
:handle-add="handleAdd" :handle-add="handleAdd"
@reset="handleReset" @reset="handleReset"
@ -69,7 +68,7 @@
:loading="editLoading" :loading="editLoading"
@cancel="editModalCancel" @cancel="editModalCancel"
@ok="handleEditSubmit" @ok="handleEditSubmit"
/> --> />
</div> </div>
</template> </template>