store+统计分析+用户管理

This commit is contained in:
ym1026
2025-09-05 09:26:14 +08:00
parent 1cc916c53c
commit 013a2245f5
15 changed files with 911 additions and 278 deletions

View File

@@ -44,42 +44,68 @@ export default {
curStatus: '充电',
list: [
{
key: 'tianshu',
key: 'batttey_type',
value: '磷酸铁锂电池',
d: '',
label: '电池类型',
class: 'item-1'
},
{
key: 'shouyi',
key: 'cooling_type',
value: '风冷',
d: '',
label: '冷却方式',
class: 'item-2'
},
{
key: 'shuliang',
key: 'voltage_rated',
value: 20,
d: 'V',
label: '电池额定总电压',
class: 'item-3'
},
{
key: 'shuliang',
key: 'work_mode',
value: '最优经济化运行模式',
d: '',
label: '运行模式',
class: 'item-4'
class: 'item-4',
list:[
{
label:'手动',
value:0
},
{
label:'峰谷套利',
value:1
},
{
label:'增网配容',
value:2
},
{
label:'应急供电',
value:3
},
{
label:'并网保电',
value:4
},
{
label:'自定时段',
value:5
},
]
},
{
key: 'fadianliang',
key: 'capacity',
value: 20,
d: 'Wh',
label: '电池储能容量',
class: 'item-5'
},
{
key: 'rongliang',
key: 'power_rated',
value: 100,
d: 'Kw',
label: 'PCS额定功率',
@@ -100,8 +126,15 @@ export default {
propsTotal: {
handler(newVal, oldVal) {
if (newVal !== oldVal) {
// 0正常 1故障
this.curStatus=['正常','故障'][this.propsTotal.status]
this.list.forEach((item) => {
item.value = this.propsTotal[item.key]
if(item.key=='work_mode'){
item.value =item.list.map((item)=>this.propsTotal[item.key]==item.value)[0].label
}else {
item.value = this.propsTotal[item.key]
}
})
}
}

View File

@@ -1,5 +1,5 @@
<template>
<div class="onLine">
<div class="statistical">
<div class="content">
<div v-for="item in list" :key="item.key" :class="`item ${item.class}`">
<span>{{ item.value ? item.value : 0 }} {{ item.d }}</span>
@@ -96,7 +96,7 @@ export default {
</script>
<style lang="scss" scoped>
.onLine {
.statistical {
height: calc(100% - 45px);
display: flex;
justify-content: center;