Explorar el Código

修改负荷平均功率

luogang hace 9 meses
padre
commit
4bba1fe767

+ 24 - 10
ems-ui/src/views/analysis/power/consume.vue

@@ -46,18 +46,18 @@
                 <span>C相:{{ scope.row.uc }}V</span>
               </template>
             </el-table-column>
-            <el-table-column label="有功功率(W)" align="center" show-overflow-tooltip width="250" >
+            <el-table-column label="有功功率(kW)" align="center" show-overflow-tooltip width="250" >
               <template slot-scope="scope">
-                <span>A相:{{ scope.row.pa }}W;</span>
-                <span>B相:{{ scope.row.pb }}W;</span>
-                <span>C相:{{ scope.row.pc }}W</span>
+                <span>A相:{{ scope.row.pa }}kW;</span>
+                <span>B相:{{ scope.row.pb }}kW;</span>
+                <span>C相:{{ scope.row.pc }}kW</span>
               </template>
             </el-table-column>
-            <el-table-column label="无功功率(W)" align="center" show-overflow-tooltip width="250" >
+            <el-table-column label="无功功率(kW)" align="center" show-overflow-tooltip width="250" >
               <template slot-scope="scope">
-                <span>A相:{{ scope.row.qa }}W;</span>
-                <span>B相:{{ scope.row.qb }}W;</span>
-                <span>C相:{{ scope.row.qc }}W</span>
+                <span>A相:{{ scope.row.qa }}kW;</span>
+                <span>B相:{{ scope.row.qb }}kW;</span>
+                <span>C相:{{ scope.row.qc }}kW</span>
               </template>
             </el-table-column>
             <el-table-column label="功率因素" align="center" prop="pf" width="100" />
@@ -185,6 +185,20 @@ export default {
           trigger: 'axis',
           axisPointer: {
             type: 'shadow'
+          },
+          formatter: (params) => {
+            var relVal = params[0].name
+            for (var i = 0, l = params.length; i < l; i++) {
+              relVal =
+                relVal +
+                '<br/>' +
+                params[i].marker +
+                params[i].seriesName +
+                '&nbsp;&nbsp;&nbsp;' +
+                params[i].value +
+                'kW'
+            }
+            return relVal
           }
         },
         legend: {
@@ -194,7 +208,7 @@ export default {
           data: xAxisData
         },
         yAxis: {
-          name: 'W(瓦)',
+          name: 'kW(瓦)',
           type: 'value',
         },
         dataZoom: [
@@ -301,7 +315,7 @@ export default {
           data: xAxisData
         },
         yAxis: {
-          name: 'W(瓦)',
+          name: 'kW(瓦)',
           type: 'value',
         },
         dataZoom: [

+ 27 - 23
ems-ui/src/views/mgr/powergrid.vue

@@ -1,27 +1,29 @@
 <template>
   <div class="app-container">
-    <div class="tips">
-      <el-statistic title="国网接入">
-        <template slot="formatter">
-          10kV
-        </template>
-      </el-statistic>
-      <el-statistic title="光伏总装机">
-        <template slot="formatter">
-          1265.85kW
-        </template>
-      </el-statistic>
-      <el-statistic title="光伏南区装机">
-        <template slot="formatter">
-          660.8kW
-        </template>
-      </el-statistic>
-      <el-statistic title="光伏北区装机">
-        <template slot="formatter">
-          605.05kW
-        </template>
-      </el-statistic>
-    </div>
+    <el-card>
+      <div class="tips">
+        <el-statistic title="国网接入">
+          <template slot="formatter">
+            10kV
+          </template>
+        </el-statistic>
+        <el-statistic title="光伏总装机">
+          <template slot="formatter">
+            1265.85kW
+          </template>
+        </el-statistic>
+        <el-statistic title="光伏南区装机">
+          <template slot="formatter">
+            660.8kW
+          </template>
+        </el-statistic>
+        <el-statistic title="光伏北区装机">
+          <template slot="formatter">
+            605.05kW
+          </template>
+        </el-statistic>
+      </div>
+    </el-card>
     <el-tabs v-model="activeName" @tab-click="tabClick">
       <el-tab-pane label="总览" name="summery">
         <el-row type="flex" :gutter="20" style="margin-top: 20px">
@@ -683,11 +685,13 @@ export default {
 <style lang="scss" scoped>
 .app-container {
   padding-top: 10px;
+
   ::v-deep .el-tabs__content {
     overflow: initial;
   }
 }
-.tips{
+
+.tips {
   display: flex;
 }
 </style>

+ 17 - 12
ems-ui/src/views/mgr/powerstore.vue

@@ -1,12 +1,14 @@
 <template>
   <div class="app-container">
-    <div class="tips">
-      <el-statistic title="总装机">
-        <template slot="formatter">
-          400kW·h
-        </template>
-      </el-statistic>
-    </div>
+    <el-card>
+      <div class="tips">
+        <el-statistic title="总装机">
+          <template slot="formatter">
+            400kW·h
+          </template>
+        </el-statistic>
+      </div>
+    </el-card>
     <el-tabs v-model="activeName" @tab-click="tabClick">
       <el-tab-pane label="总览" name="summary">
         <div class="chartGroup">
@@ -285,10 +287,10 @@ export default {
     async getAreaList () {
       await areaWithFacsCategoryAsTree(this.facsCategory, this.facsSubCategory).then(response => {
         this.areaOptions = [{
-            id: '-1',
-            label: '全部',
-            children: []
-          }].concat(response.data)
+          id: '-1',
+          label: '全部',
+          children: []
+        }].concat(response.data)
       })
     },
     /** 查询储能计量-小时列表 */
@@ -368,13 +370,16 @@ export default {
 
 .app-container {
   padding-top: 10px;
+
   ::v-deep .el-tabs__content {
     overflow: initial;
   }
 }
-.tips{
+
+.tips {
   display: flex;
 }
+
 .chartGroup {
   display: flex;
 

+ 51 - 8
ems-ui/src/views/mgr/poweruse.vue

@@ -5,11 +5,11 @@
         <div class="First">
           <div class="time-range-buttons">
             <el-button :class="{ 'is-active': selectedTimeRange === 'day' }"
-              @click="changeTimeRange('day')">日</el-button>
+              @click="changeTimeRange('day')">日</el-button>
             <el-button :class="{ 'is-active': selectedTimeRange === 'month' }"
-              @click="changeTimeRange('month')">月</el-button>
+              @click="changeTimeRange('month')">月</el-button>
             <el-button :class="{ 'is-active': selectedTimeRange === 'year' }"
-              @click="changeTimeRange('year')">年</el-button>
+              @click="changeTimeRange('year')">年</el-button>
           </div>
           <div class="first-content">
             <div>
@@ -101,7 +101,8 @@
               </div>
               <!--柱状图-->
               <div class="container-block" style="margin-top: 20px;">
-                <BaseChart width="100%" height="350px" v-if="activeName !== 'summery'" :option="equipPowerLineOptions" />
+                <BaseChart width="100%" height="350px" v-if="activeName !== 'summery'"
+                  :option="equipPowerLineOptions" />
               </div>
             </div>
           </div>
@@ -277,6 +278,20 @@ export default {
           trigger: 'axis',
           axisPointer: {
             type: 'shadow'
+          },
+          formatter: (params) => {
+            var relVal = params[0].name
+            for (var i = 0, l = params.length; i < l; i++) {
+              relVal =
+                relVal +
+                '<br/>' +
+                params[i].marker +
+                params[i].seriesName +
+                '&nbsp;&nbsp;&nbsp;' +
+                params[i].value +
+                'kW·h'
+            }
+            return relVal
           }
         },
         legend: {
@@ -329,6 +344,20 @@ export default {
           trigger: 'axis',
           axisPointer: {
             type: 'shadow'
+          },
+          formatter: (params) => {
+            var relVal = params[0].name
+            for (var i = 0, l = params.length; i < l; i++) {
+              relVal =
+                relVal +
+                '<br/>' +
+                params[i].marker +
+                params[i].seriesName +
+                '&nbsp;&nbsp;&nbsp;' +
+                params[i].value +
+                'kW'
+            }
+            return relVal
           }
         },
         xAxis: {
@@ -336,7 +365,7 @@ export default {
           data: xAxisData
         },
         yAxis: {
-          name: 'W(瓦)',
+          name: 'kW(瓦)',
           type: 'value',
         },
         legend: {},
@@ -437,6 +466,20 @@ export default {
           trigger: 'axis',
           axisPointer: {
             type: 'shadow'
+          },
+          formatter: (params) => {
+            var relVal = params[0].name
+            for (var i = 0, l = params.length; i < l; i++) {
+              relVal =
+                relVal +
+                '<br/>' +
+                params[i].marker +
+                params[i].seriesName +
+                '&nbsp;&nbsp;&nbsp;' +
+                params[i].value +
+                'kW'
+            }
+            return relVal
           }
         },
         xAxis: {
@@ -444,7 +487,7 @@ export default {
           data: xAxisData
         },
         yAxis: {
-          name: 'W(瓦)',
+          name: 'kW(瓦)',
           type: 'value',
         },
         dataZoom: [
@@ -539,7 +582,7 @@ export default {
         }
       })
       getPowerMaxLoad(params).then(({code, data}) => {
-        if (code === 200&&data) {
+        if (code === 200 && data) {
           this.powerMaxLoad = parseFloat(data.s).toFixed(2)
         }
       })
@@ -660,7 +703,7 @@ export default {
           formatter: function (params) {
             const {name, value, percent} = params;
             const subentries = params.data.subentry;
-            let tooltipContent = `<div><h4>${name}</h4><p>${value} (${percent}%)</p><ul>`;
+            let tooltipContent = `<div><h4>${name}</h4><p>${value}kW·h (${percent}%)</p><ul>`;
             subentries.forEach(subItem => {
               tooltipContent += `<li>${subItem.name}: ${subItem.value} kW·h</li>`;
             });