diff --git a/public/map/components/ShipHistoryDialog.vue b/public/map/components/ShipHistoryDialog.vue index 0154c3a..5bcccfd 100644 --- a/public/map/components/ShipHistoryDialog.vue +++ b/public/map/components/ShipHistoryDialog.vue @@ -103,7 +103,7 @@ import { ElTableColumn, ElPagination } from 'element-plus' -import { CARGO_CATEGORY, FACILITY_TYPE, getOperationTypeLabel, OPERATION_TYPE } from './dictionaryTable'; +import { CARGO_CATEGORY, FACILITY_TYPE, HARBOR_DISTRICT, getOperationTypeLabel, OPERATION_TYPE } from './dictionaryTable'; import { formatDuration, formatTimestamp, showStatus } from './utils'; import { RealtimeDeviceData } from '@/types/shorepower'; @@ -173,14 +173,14 @@ const berthingColumns = ref([ { prop: 'shipBasicInfo.tonnage', label: '最大载重', width: 150 }, { prop: 'shipBasicInfo.voyage', label: '航线', width: 150 }, { prop: 'applyInfo.departureHarborDistrict', label: '起运港', width: 150 }, - { prop: 'applyInfo.arrivalHarborDistrict', label: '到达港', width: 150 }, + { prop: 'arrivalHarborDistrict', label: '到达港', width: 150 }, { prop: 'applyInfo.operationType', label: '靠泊类型', width: 150, formatter: (_row, _column, cellValue) => getOperationTypeLabel(cellValue, OPERATION_TYPE) }, { prop: '', label: '作业内容', width: 180 }, - { + /* { prop: 'applyInfo.loadingCargoCategory', label: '货物类型', width: 180, formatter: (row) => { if (row.applyInfo.operationType === 1) { - return row.applyInfo.loadingCargoCategory; + return getOperationTypeLabel(row.applyInfo.loadingCargoCategory, CARGO_CATEGORY); } else if (row.applyInfo.operationType === 2) { return row.applyInfo.unloadingCargoCategory; } else if (row.applyInfo.operationType === 3) { @@ -188,7 +188,7 @@ const berthingColumns = ref([ } return ''; } - }, + }, */ { prop: 'applyInfo.loadingCargoCategory', label: '货物名称', width: 180, @@ -392,9 +392,10 @@ const handleGetShipHistortyList = async (param) => { const startIndex = (pageNo - 1) * pageSize; const endIndex = startIndex + pageSize; const paginatedList = filteredList.slice(startIndex, endIndex); - + const harborDistructList = await HARBOR_DISTRICT() const buildData = await Promise.all(paginatedList.map(async item => ({ ...item, + arrivalHarborDistrict: getOperationTypeLabel(item.applyInfo.arrivalHarborDistrict, harborDistructList), }))) berthingTableData.value = buildData berthingTotal.value = totalFiltered diff --git a/public/map/components/ShorePowerUsage.vue b/public/map/components/ShorePowerUsage.vue index 2f5e209..fd36189 100644 --- a/public/map/components/ShorePowerUsage.vue +++ b/public/map/components/ShorePowerUsage.vue @@ -988,6 +988,7 @@ const handleGetRealTimeAllData = async (realtimeDeviceData: RealtimeDeviceData[] ids: ids.join(','), // year: new Date().getFullYear() } + if (!params.ids) return; let yearDataRes: RealtimeDeviceData[] = [] let weekDataRes: RealtimeDeviceData[] = [] let monthDataRes: RealtimeDeviceData[] = [] diff --git a/public/map/components/cesiumMap.vue b/public/map/components/cesiumMap.vue index d13b9ce..a7f900a 100644 --- a/public/map/components/cesiumMap.vue +++ b/public/map/components/cesiumMap.vue @@ -999,7 +999,7 @@ onMounted(async () => { position: labelPosition, name: '岸电箱 Label', label: { - text: '岸电箱 A-001', + text: '岸电箱', font: '24px sans-serif', fillColor: Cesium.Color.WHITE, outlineColor: Cesium.Color.BLACK,