提交 8b667ecf authored 作者: zhuyongshuai's avatar zhuyongshuai

fix:点击时间段搜索没用的问题

上级 aeaa3e15
......@@ -146,7 +146,8 @@
<div v-if="scope.row.station.length !== 0">
<div v-for="(items, index) in scope.row.station" :key="index">
<div v-if="isTimeInRange(useAppStoreInstance.globalTimeLineEndSelectTime, items.startTime, items.endTime)">
<div
v-if="isTimeInRange(useAppStoreInstance.globalTimeLineEndSelectTime, items.startTime, items.endTime)">
{{ items.siteName }}
</div>
<div v-else>-</div>
......@@ -269,16 +270,8 @@
</div>
<el-dialog v-model="errorDialogVisible"
:show-close="false"
:modal="false"
width="300"
hight="50"
:destroy-on-close="true"
:close-on-click-modal="true"
style="background: rgba(0, 0, 0, 0);padding: 0;margin: 0;"
>
<el-dialog v-model="errorDialogVisible" :show-close="false" :modal="false" width="300" hight="50"
:destroy-on-close="true" :close-on-click-modal="true" style="background: rgba(0, 0, 0, 0);padding: 0;margin: 0;">
<errorDialog :errorDeviceList="errorDeviceList" :satlTitle="satlTitle" :baseDeviceList="baseDeviceList"
@errorDialoghandleClose="errorDialoghandleClose"></errorDialog>
......@@ -297,6 +290,7 @@ import wss from '@/utils/requestSocekt.js'
import useAppStore from '@/store/module/app'
import local from '@/utils/local.js'
import { ElMessage } from 'element-plus';
import { da } from 'element-plus/es/locales.mjs';
const useAppStoreInstance = useAppStore();
// 激活的标签页
......@@ -321,6 +315,9 @@ const globalIntervalTime = ref('')
const globalIntervalTimeTemp = ref('')
const globaleAutoPlay = ref(true)
const carouselKey = ref(0)
watch(globalIntervalTime, (newValue, oldValue) => {
// //console.log("globalIntervalTime发生变化了");
......@@ -414,7 +411,7 @@ const satelliteData = ref();
const searchSateValue = ref('')
function searchSatelliteList() {
//console.log("cao cao2", primitiveSatelliteData.value);
console.log("拿到的数据", primitiveSatelliteData.value);
const filteredData = primitiveSatelliteData.value.filter(item =>
item.name.toLowerCase().includes(searchSateValue.value.toLowerCase()) ||
......@@ -422,7 +419,7 @@ function searchSatelliteList() {
item.manufacturer.toLowerCase().includes(searchSateValue.value.toLowerCase()) ||
item.status.toLowerCase().includes(searchSateValue.value.toLowerCase())
);
// //console.log(filteredData);
console.log(filteredData);
satelliteData.value = filteredData
}
......@@ -491,8 +488,8 @@ function tableHandleRowClickFn(row, column, event) {
// })))
if (window.ue5) {
window.ue5("callBackAllDialogFn", String(JSON.stringify({
type:"DeviceFaultDialog",
status:"open"
type: "DeviceFaultDialog",
status: "open"
})));
}
}
......@@ -503,8 +500,8 @@ function errorDialoghandleClose() {
errorDialogVisible.value = false
if (window.ue5) {
window.ue5("callBackAllDialogFn", String(JSON.stringify({
type:"DeviceFaultDialog",
status:"close"
type: "DeviceFaultDialog",
status: "close"
})));
}
}
......@@ -562,11 +559,12 @@ const transformSatelliteData = (data) => {
const wssTransformSatelliteData = (data) => {
// console.log("wssTransformSatelliteData:", data)
// 检查 data 是否为对象且不为 null
if (typeof data === 'object' && data !== null && !Array.isArray(data)) {
return [{
name: data?.satelliteName || '',
station: data?.siteName === null ? '-' : data?.siteName,
station: (data?.siteName === null || data?.siteName.length === 0) ? '-' : data?.siteName,
manufacturer: data?.manufacturer || '',
status: data?.satelliteStatus || '正常',
statusClass: satelliteStatusMap[data?.satelliteStatus || '正常'] || 'normal',
......@@ -576,7 +574,7 @@ const wssTransformSatelliteData = (data) => {
// 如果意外传入了数组,仍然处理数组
return data.map(item => ({
name: item?.satelliteName || '',
station: item?.siteName === null ? '-' : item?.siteName,
station: (item?.siteName === null || item?.siteName.length === 0) ? '-' : item?.siteName,
manufacturer: item?.manufacturer || '',
status: item?.satelliteStatus || '正常',
statusClass: satelliteStatusMap[item?.satelliteStatus || '正常'] || 'normal',
......@@ -730,14 +728,14 @@ const transformGroundSatelliteData = (data) => {
return [
{ label: '地面站数', value: data?.groundStationNum === null ? 0 : data?.groundStationNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/NumberOfGroundStations.png' , import.meta.url).href},
{ label: '开通格网数', value: data?.openGridNum === null ? 0 : data?.openGridNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/ActivateGridNumber.png' , import.meta.url).href},
{ label: '弧段数量', value: data?.arcNum === null ? 0 : data?.arcNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/NumberOfArcSegments.png' , import.meta.url).href},
{ label: '执行情况-弧段', value: data?.arcExecuteNum === null ? 0 : data?.arcExecuteNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/ExecutionStatusArcSegment.png' , import.meta.url).href},
{ label: '上注完成情况(星)', value: data?.arcCompleteNum === null || data?.arcCompleteNum === undefined ? 0 : data?.arcCompleteNum,CurrentURL:new URL('../../assets/images/leftGroundIcon/CompletionStatusOfTheAboveNote.png' , import.meta.url).href },
{ label: '上注失败星数(星)', value: data?.arcFaultNum === null || data?.arcFaultNum === undefined ? 0 : data?.arcFaultNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/NumberOfStarsFailedToBet.png' , import.meta.url).href},
{ label: '设备故障', value: data?.faultDeviceNum === null ? 0 : data?.faultDeviceNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/NumberOfFaultyDevices.png' , import.meta.url).href},
{ label: '地面站数', value: data?.groundStationNum === null ? 0 : data?.groundStationNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/NumberOfGroundStations.png', import.meta.url).href },
{ label: '开通格网数', value: data?.openGridNum === null ? 0 : data?.openGridNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/ActivateGridNumber.png', import.meta.url).href },
{ label: '弧段数量', value: data?.arcNum === null ? 0 : data?.arcNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/NumberOfArcSegments.png', import.meta.url).href },
{ label: '执行情况-弧段', value: data?.arcExecuteNum === null ? 0 : data?.arcExecuteNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/ExecutionStatusArcSegment.png', import.meta.url).href },
{ label: '上注完成情况(星)', value: data?.arcCompleteNum === null || data?.arcCompleteNum === undefined ? 0 : data?.arcCompleteNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/CompletionStatusOfTheAboveNote.png', import.meta.url).href },
{ label: '上注失败星数(星)', value: data?.arcFaultNum === null || data?.arcFaultNum === undefined ? 0 : data?.arcFaultNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/NumberOfStarsFailedToBet.png', import.meta.url).href },
{ label: '设备故障', value: data?.faultDeviceNum === null ? 0 : data?.faultDeviceNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/NumberOfFaultyDevices.png', import.meta.url).href },
]
};
......@@ -747,14 +745,14 @@ const wssTransformGroundSatelliteData = (data) => {
// 检查 data 是否为对象且不为 null
if (typeof data === 'object' && data !== null && !Array.isArray(data)) {
return [
{ label: '地面站数', value: data?.groundStationNum === null ? 0 : data?.groundStationNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/NumberOfGroundStations.png' , import.meta.url).href},
{ label: '开通格网数', value: data?.openGridNum === null ? 0 : data?.openGridNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/ActivateGridNumber.png' , import.meta.url).href},
{ label: '弧段数量', value: data?.arcNum === null ? 0 : data?.arcNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/NumberOfArcSegments.png' , import.meta.url).href},
{ label: '执行情况-弧段', value: data?.arcExecuteNum === null ? 0 : data?.arcExecuteNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/ExecutionStatusArcSegment.png' , import.meta.url).href},
{ label: '上注完成情况(星)', value: data?.arcCompleteNum === null || data?.arcCompleteNum === undefined ? 0 : data?.arcCompleteNum,CurrentURL:new URL('../../assets/images/leftGroundIcon/CompletionStatusOfTheAboveNote.png' , import.meta.url).href },
{ label: '上注失败星数(星)', value: data?.arcFaultNum === null || data?.arcFaultNum === undefined ? 0 : data?.arcFaultNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/NumberOfStarsFailedToBet.png' , import.meta.url).href},
{ label: '设备故障', value: data?.faultDeviceNum === null ? 0 : data?.faultDeviceNum ,CurrentURL:new URL('../../assets/images/leftGroundIcon/NumberOfFaultyDevices.png' , import.meta.url).href},
{ label: '地面站数', value: data?.groundStationNum === null ? 0 : data?.groundStationNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/NumberOfGroundStations.png', import.meta.url).href },
{ label: '开通格网数', value: data?.openGridNum === null ? 0 : data?.openGridNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/ActivateGridNumber.png', import.meta.url).href },
{ label: '弧段数量', value: data?.arcNum === null ? 0 : data?.arcNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/NumberOfArcSegments.png', import.meta.url).href },
{ label: '执行情况-弧段', value: data?.arcExecuteNum === null ? 0 : data?.arcExecuteNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/ExecutionStatusArcSegment.png', import.meta.url).href },
{ label: '上注完成情况(星)', value: data?.arcCompleteNum === null || data?.arcCompleteNum === undefined ? 0 : data?.arcCompleteNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/CompletionStatusOfTheAboveNote.png', import.meta.url).href },
{ label: '上注失败星数(星)', value: data?.arcFaultNum === null || data?.arcFaultNum === undefined ? 0 : data?.arcFaultNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/NumberOfStarsFailedToBet.png', import.meta.url).href },
{ label: '设备故障', value: data?.faultDeviceNum === null ? 0 : data?.faultDeviceNum, CurrentURL: new URL('../../assets/images/leftGroundIcon/NumberOfFaultyDevices.png', import.meta.url).href },
];
}
......@@ -768,7 +766,7 @@ const leftGetAllListInfo = () => {
coreMetrics.value = orbitMetrics.value[0].headerTitle
})
stellateListInfoApi().then(res => {
//console.log(res.data, "sas---------asasa");
// console.log("sas---------asasa", res.data);
primitiveSatelliteData.value = transformSatelliteData(res.data)
// 按 satelliteName 排序,专门处理 "SS GEN1-15" 格式
primitiveSatelliteData.value.sort((a, b) => {
......@@ -806,6 +804,7 @@ onBeforeMount(() => {
// 监听 webSocket 结束变化,再根据api查一次数据库
watch(() => useAppStoreInstance.globalStartWss, (newValue, oldValue) => {
if (!newValue) {
setTimeout(() => {
leftGetAllListInfo();
......@@ -860,10 +859,10 @@ const errorDeviceListDetailsDialog = ref([])
const tempCount = ref(0)
watch(() =>useAppStoreInstance.globalLeftWssCONTINE, val => {
watch(() => useAppStoreInstance.globalLeftWssCONTINE, val => {
const JSONdata = val
// console.log("useAppStoreInstance.globalLeftWssCONTINE", JSONdata,(JSONdata.type === 'history' && !(JSONdata?.isLagrangeInterpolation === true) ),JSONdata.type === 'realtime');
if (JSONdata.type === 'history' ) {
if (JSONdata.type === 'history') {
const satelliteList = []
JSONdata.CurrData.forEach(items => {
......@@ -2028,14 +2027,17 @@ onUnmounted(() => {
border-color: #434a54;
}
:deep(.setting-input .el-input__wrapper) {
box-shadow: none;
border: none;
}
:deep(.setting-input .el-input__wrapper .el-input__inner) {
box-shadow: none;
border: none;
}
.setting-checkbox {
margin-left: 10px;
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论