From 4ac563be67aec8eaba22c16d6d765b7799014c89 Mon Sep 17 00:00:00 2001
From: yeg <1347747024@qq.com>
Date: 星期三, 09 九月 2026 12:21:23 +0800
Subject: [PATCH] 对齐控制台三类数据字段
---
src/components/ConsoleDataListPanel.vue | 32 +++++++++++---------------------
1 files changed, 11 insertions(+), 21 deletions(-)
diff --git a/src/components/ConsoleDataListPanel.vue b/src/components/ConsoleDataListPanel.vue
index 461e9d8..40379ca 100644
--- a/src/components/ConsoleDataListPanel.vue
+++ b/src/components/ConsoleDataListPanel.vue
@@ -344,8 +344,8 @@
ElMessage.warning('没有可下载的数据')
return
}
- const headers = activeTab.value === 'cycle' ? ['记录编号', '电池', '循环号', '充电容量(mAh)', '放电容量(mAh)', '充放电效率(%)', '充电能量(mWh)', '放电能量(mWh)'] : activeTab.value === 'step' ? ['记录编号', '电池', '循环号', '工步序号', '工步', '工步时间', '容量(mAh)', '能量(mWh)', '起始电压(V)', '终止电压(V)', '充电中值电压(V)', '放电中值电压(V)'] : ['记录编号', '电池', '循环号', '实际工步号', '实际工步名称', '记录序号', '设备时间', '服务器接收时间', '电压(V)', '电流(mA)', '容量(mAh)', '能量(mWh)', '温度(℃)', '正电位(V)', '负电位(V)']
- const records = activeTab.value === 'cycle' ? filteredRows.value.map(row => [row.recordNo, row.batteryNo, row.cycleNo, row.chargeCapacity, row.dischargeCapacity, row.efficiency, row.chargeEnergy, row.dischargeEnergy]) : activeTab.value === 'step' ? filteredRows.value.map(row => [row.recordNo, row.batteryNo, row.cycleNo, row.stepNo, row.stepName, row.stepDuration, row.capacity, row.energy, row.startVoltage, row.endVoltage, row.chargeMedianVoltage, row.dischargeMedianVoltage]) : filteredRows.value.map(row => [row.recordNo, row.batteryNo, row.cycleNo, row.stepNo, row.stepName, row.sequenceId, row.recordedAt, row.serverReceivedAt, row.voltage, row.current, row.capacity, row.energy, row.temperature, row.positivePotential, row.negativePotential])
+ const headers = activeTab.value === 'cycle' ? ['记录编号', '电池', '循环序号', '充电容量(mAh)', '放电容量(mAh)', '充放电效率(%)', '充电能量(mWh)', '放电能量(mWh)'] : activeTab.value === 'step' ? ['记录编号', '电池', '循环序号', '工步序号', '工步名称', '工步时间(h:min:s.ms)', '容量(mAh)', '能量(mWh)', '起始电压(V)', '终止电压(V)', '充电中值电压(V)', '放电中值电压(V)'] : ['记录编号', '电池', '循环序号', '工步序号', '工步名称', '记录序号', '记录时间(h:min:s.ms)', '电压(V)', '电流(mA)', '容量(mAh)', '能量(mWh)', '绝对时间', '温度(℃)', '正电位(V)', '负电位(V)']
+ const records = activeTab.value === 'cycle' ? filteredRows.value.map(row => [row.recordNo, row.batteryNo, row.cycleNo, row.chargeCapacity, row.dischargeCapacity, row.efficiency, row.chargeEnergy, row.dischargeEnergy]) : activeTab.value === 'step' ? filteredRows.value.map(row => [row.recordNo, row.batteryNo, row.cycleNo, row.stepNo, row.stepName, row.stepDuration, row.capacity, row.energy, row.startVoltage, row.endVoltage, row.chargeMedianVoltage, row.dischargeMedianVoltage]) : filteredRows.value.map(row => [row.recordNo, row.batteryNo, row.cycleNo, row.stepNo, row.stepName, row.sequenceId, row.recordedAt, row.voltage, row.current, row.capacity, row.energy, row.absoluteTime, row.temperature, row.positivePotential, row.negativePotential])
const blob = new Blob([`\uFEFF${[headers, ...records].map(item => item.map(escapeCsv).join(',')).join('\n')}`], { type: 'text/csv;charset=utf-8' })
const url = URL.createObjectURL(blob)
const anchor = document.createElement('a')
@@ -428,13 +428,12 @@
</th>
<th>记录编号</th>
<th>电池</th>
- <th>循环号</th>
- <th>实际工步号</th>
- <th>实际工步名称</th>
+ <th>循环序号</th>
+ <th>工步序号</th>
+ <th>工步名称</th>
<th>记录序号</th>
<th>设备时间</th>
- <th>服务器接收时间</th>
- <th class="source-column">来源</th>
+ <th>绝对时间</th>
<th>温度(℃)</th>
<th>正电位(V)</th>
<th>负电位(V)</th>
@@ -448,10 +447,8 @@
<th class="selection-column"></th>
<th>记录编号</th>
<th>电池</th>
- <th>循环号</th>
- <th>工步</th>
- <th>设备时间</th>
- <th>服务器接收时间</th>
+ <th>循环序号</th>
+ <th>工步名称</th>
<th>工步时间</th>
<th>容量(mAh)</th>
<th>能量(mWh)</th>
@@ -465,9 +462,7 @@
<th class="selection-column"></th>
<th>记录编号</th>
<th>电池</th>
- <th>循环号</th>
- <th>设备时间</th>
- <th>服务器接收时间</th>
+ <th>循环序号</th>
<th>充电容量(mAh)</th>
<th>放电容量(mAh)</th>
<th>充放电效率(%)</th>
@@ -491,8 +486,7 @@
<td>{{ row.stepName }}</td>
<td>{{ row.sequenceId }}</td>
<td>{{ row.recordedAt }}</td>
- <td>{{ row.serverReceivedAt }}</td>
- <td class="source-column" :title="row.sourceIdentity">{{ row.sourceType === 'COLLECTOR' ? `采集器 ${row.collectorCode}` : row.sourceType === 'SNAPSHOT' ? '检测柜 + 采集器' : '检测柜' }}<small>{{ row.sourceIdentity }}</small><small v-if="row.sourceType === 'SNAPSHOT'">采集器 {{ row.collectorCode }} · {{ row.collectorDeviceTime }}</small><small v-if="row.sourceType === 'COLLECTOR'">{{ row.channelCode }}</small><small v-if="row.extensionMeasurements !== '-'">{{ row.extensionMeasurements }}</small></td>
+ <td>{{ row.absoluteTime }}</td>
<td><el-input v-if="editing && draftRows[row.id]" v-model="draftRows[row.id].temperature" size="small" /><span v-else>{{ row.temperature }}</span></td>
<td><el-input v-if="editing && draftRows[row.id]" v-model="draftRows[row.id].positivePotential" size="small" /><span v-else>{{ row.positivePotential }}</span></td>
<td><el-input v-if="editing && draftRows[row.id]" v-model="draftRows[row.id].negativePotential" size="small" /><span v-else>{{ row.negativePotential }}</span></td>
@@ -526,8 +520,6 @@
</td>
<td>{{ row.cycleNo }}</td>
<td>{{ row.stepNo }} · {{ row.stepName }}</td>
- <td>{{ row.recordedAt }}</td>
- <td>{{ row.serverReceivedAt }}</td>
<td>
<el-input v-if="editing && draftRows[row.id]" v-model="draftRows[row.id].stepDuration" size="small" />
<span v-else>{{ row.stepDuration }}</span>
@@ -569,8 +561,6 @@
<strong>{{ row.batteryNo }}</strong>
</td>
<td>{{ row.cycleNo }}</td>
- <td>{{ row.recordedAt }}</td>
- <td>{{ row.serverReceivedAt }}</td>
<td>
<el-input v-if="editing && draftRows[row.id]" v-model="draftRows[row.id].chargeCapacity" size="small" />
<span v-else>{{ row.chargeCapacity }}</span>
@@ -597,7 +587,7 @@
</tr></template
>
<tr v-if="!loading && !pagedRows.length">
- <td :colspan="activeTab === 'realtime' ? 19 : activeTab === 'step' ? 15 : 12" class="empty-cell">
+ <td :colspan="activeTab === 'realtime' ? 17 : activeTab === 'step' ? 14 : 10" class="empty-cell">
{{ loadError || '暂无检测柜记录' }}
</td>
</tr>
--
Gitblit v1.7.1