From d0d16b98dd31759bd6a6e1e79f6c2446e2829c6a Mon Sep 17 00:00:00 2001 From: fengrong Date: Tue, 26 Nov 2024 10:45:30 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A6=96=E9=A1=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ui/dasadmin/src/views/backend/dashboard.vue | 3 +++ .../src/views/backend/realData/index.vue | 21 +++++++++++++++++-- 2 files changed, 22 insertions(+), 2 deletions(-) diff --git a/ui/dasadmin/src/views/backend/dashboard.vue b/ui/dasadmin/src/views/backend/dashboard.vue index 4741df41..2e8187aa 100644 --- a/ui/dasadmin/src/views/backend/dashboard.vue +++ b/ui/dasadmin/src/views/backend/dashboard.vue @@ -577,6 +577,9 @@ $labelHeight: 30px; p{ padding-right: 30px; display: inline-block; + span{ + padding-right: 10px; + } } } } diff --git a/ui/dasadmin/src/views/backend/realData/index.vue b/ui/dasadmin/src/views/backend/realData/index.vue index 0d75c9e2..fbb0cd12 100644 --- a/ui/dasadmin/src/views/backend/realData/index.vue +++ b/ui/dasadmin/src/views/backend/realData/index.vue @@ -169,8 +169,8 @@ const tableItem1: any = [ title: '发电机转速' }, { - label: '有功功率 (MW)', - unit:' (MW)', + label: '有功功率 (kW)', + unit:' (kW)', prop: 'igenpower', align: 'center', custom: 'header', @@ -408,6 +408,7 @@ const selectTable = (selected: TableType[] | null) => { console.error('Selected is null or undefined') return } + debugger selected.forEach((item, index) => { if (!multipleSelection.value.some(item1 => item1.attributeCode === item.attributeCode)) { multipleSelection.value.push(item); @@ -561,15 +562,31 @@ const getTableData = () => { }); tableColumn.value = [...tableItem0, ...tableColumnEnds.value]; } + tableData.value = [] + const deviceNameList=deviceList.value.map((item) => { + return { + id:item.id, + name: item.name ?? '-', + } + }); + deviceId.forEach((item,index) => { objparms.deviceId=item objparms.attributes=multipleSelection.value.map((item) => item.attributeCode) snapshotParms.push({...objparms}) }) + deviceNameList.forEach((item1,index) => { + const NameItem={ + id:item1.id, + name: item1.name, + } + tableData.value.push({...NameItem}) + }) getsnapshotData(snapshotParms).then((res) => { if (res.code == 200) { const tsnapshotVoObject: any = res.data; multipleSelection.value.map((item1: any) => { + //tableData.value = []; tableData.value.forEach((item: any, i: number, arr: any) => { for (const itemKey in tsnapshotVoObject) { if (item.id === itemKey) {