| | |
| | | |
| | | 测试账号:`admin` / `admin123` |
| | | |
| | | 仓库默认开发配置会同时启用 `druid` 和 `dev-simulator` Profile。`dev-simulator` 负责驱动开发模拟器的发现、采样和实时快照调度;未启用时模拟器页面仍可打开,但不会向模拟器请求数据。需要显式指定时可执行: |
| | | |
| | | ```powershell |
| | | cd E:\YeGproject\jcs\BatteryDetection |
| | | mvn -pl ruoyi-admin -am spring-boot:run -Dspring-boot.run.profiles=druid,dev-simulator |
| | | ``` |
| | | |
| | | 普通 IntelliJ IDEA `RuoYiApplication` 启动会读取该默认配置;若运行配置填写了 Active profiles,则应设为 `druid,dev-simulator`。真实设备部署必须覆盖活动 Profile 并移除 `dev-simulator`。 |
| | | |
| | | ## 文档 |
| | | |
| | | - [项目说明、目录、页面树与开发记录](docs/PROJECT.md) |
| | |
| | | ElMessage.warning('没有可下载的数据') |
| | | return |
| | | } |
| | | const headers = activeTab.value === 'cycle' ? ['记录编号', '电池', '循环号', '充电容量(Ah)', '放电容量(Ah)', '充放电效率(%)', '充电能量(Wh)', '放电能量(Wh)'] : activeTab.value === 'step' ? ['记录编号', '电池', '循环号', '工步序号', '工步', '工步时间', '容量(Ah)', '能量(Wh)', '起始电压(V)', '终止电压(V)', '充电峰值(V)', '放电谷值(V)'] : ['记录编号', '电池', '循环号', '实际工步号', '实际工步名称', '记录序号', '设备时间', '服务器接收时间', '电压(V)', '电流(A)', '容量(Ah)', '能量(Wh)', '温度(℃)', '正电位(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.chargePeakVoltage, row.dischargeValleyVoltage]) : 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, row.extensionMeasurements]) |
| | | const headers = activeTab.value === 'cycle' ? ['记录编号', '电池', '循环号', '充电容量(Ah)', '放电容量(Ah)', '充放电效率(%)', '充电能量(Wh)', '放电能量(Wh)'] : activeTab.value === 'step' ? ['记录编号', '电池', '循环号', '工步序号', '工步', '工步时间', '容量(Ah)', '能量(Wh)', '起始电压(V)', '终止电压(V)', '充电峰值(V)', '放电谷值(V)'] : ['记录编号', '电池', '循环号', '实际工步号', '实际工步名称', '记录序号', '设备时间', '服务器接收时间', '电压(V)', '电流(A)', '容量(Ah)', '能量(Wh)', '温度(℃)', '正电位(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.chargePeakVoltage, row.dischargeValleyVoltage]) : 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 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') |
| | |
| | | <th>温度(℃)</th> |
| | | <th>正电位(V)</th> |
| | | <th>负电位(V)</th> |
| | | <th>其他采集字段</th> |
| | | <th>电压(V)</th> |
| | | <th>电流(A)</th> |
| | | <th>容量(Ah)</th> |
| | |
| | | <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> |
| | | <td>{{ row.extensionMeasurements }}</td> |
| | | <td> |
| | | <el-input v-if="editing && draftRows[row.id]" v-model="draftRows[row.id].voltage" size="small" /> |
| | | <span v-else>{{ row.voltage }}</span> |
| | |
| | | `--spring.data.redis.port=${redisPort}`, |
| | | `--spring.data.redis.password=${redisPassword}`, |
| | | '--spring.data.redis.database=0', |
| | | '--spring.profiles.active=druid,dev-simulator', |
| | | '--spring.devtools.restart.enabled=false', |
| | | `--battery.dev-simulator.port=${simulatorPort}`, |
| | | `--ruoyi.profile=${artifactDir}`, |
| | |
| | | export default defineConfig({ |
| | | plugins: [vue()], |
| | | server: { |
| | | port: 5174, |
| | | port: 6173, |
| | | strictPort: true, |
| | | proxy: { |
| | | '/dev-api': { |