tianyabing %!s(int64=2) %!d(string=hai) anos
pai
achega
c9c39ba8f0

+ 31 - 8
src/components/common/coreData.vue

@@ -1,7 +1,13 @@
 <script>
 import {requireImg} from "@/utils/requireImg";
+import IsNumeric from "ant-design-vue/lib/_util/isNumeric";
 
 export default {
+  computed: {
+    IsNumeric() {
+      return IsNumeric
+    }
+  },
   data() {
     return {
       itemWidth: 150,
@@ -48,17 +54,23 @@ export default {
       >
         <div class="coreData-item-title">
           <span>{{ ele.title }}</span>
-          <div v-if="ele.type === 1 || ele.showStar" style="display: inline-block;background-color: transparent;float: right;margin-right: 2%">
+          <div v-if="ele.showStar" style="display: inline-block;background-color: transparent;float: right;margin-right: 5%">
             <a-avatar :size="28" :src="requireImg('common/star.png')"></a-avatar>
           </div>
         </div>
         <template v-if="ele.type === 1">
           <div class="coreData-high-content">
-            <span>{{ ele.content }}</span>
+            <span :class="IsNumeric(ele.content)?'coreData-item-num':''">{{ ele.content }}</span>
           </div>
         </template>
         <template v-else>
-          <div class="coreData-item-num" v-html="ele.num"></div>
+          <div class="coreData-item-num" >
+            <span>{{ Math.abs(ele.num) }}</span>
+            <span class="anticon" v-if="ele.showTrendIcon" style="font-size: 14px;display: inline-block;margin-left: 3px">
+              <i-icon-park-outline-trending-up style="color: #FF2A00" v-if="Number(ele.num)>0" />
+              <i-icon-park-outline-trending-down style="color: #39E681" v-if="Number(ele.num)<0"  />
+            </span>
+          </div>
           <div class="coreData-item-unit" v-html="ele.unit"></div>
           <div class="coreData-item-history">
             <div class="coreData-item-historyDesc">
@@ -72,8 +84,17 @@ export default {
 
             </div>
             <div class="coreData-item-historyNum" v-if="!isNaN(ele.historyNum)">
-              <span :style="{color: ele.historyNum>0?'red':ele.historyNum<0?'#39E681':''}">{{ Math.abs(ele.historyNum) }}%</span>
+              <span :style="{color: ele.historyNum>0?'red':ele.historyNum<0?'#39E681':''}">
+                {{ Math.abs(ele.historyNum) }}%
+              </span>
             </div>
+            <span class="anticon"
+                  v-if="!ele.hideTrendDesc"
+                  :style="{color: ele.historyNum>0?'red':ele.historyNum<0?'#39E681':''}"
+                  style="vertical-align: middle;font-size: 12px">
+              <a-icon type="caret-up" v-if="ele.historyNum > 0" />
+              <a-icon type="caret-down" v-if="ele.historyNum < 0" />
+            </span>
           </div>
         </template>
       </div>
@@ -100,7 +121,7 @@ export default {
       font-size: 15px;
       max-height: 60px;
       overflow: hidden;
-      font-weight: bold;
+      font-family: PingFangSC-Bold,serif;
       letter-spacing: 1px;
       word-wrap:break-word;
       word-break:break-all;
@@ -111,9 +132,11 @@ export default {
     }
     .coreData-item-num {
       display: inline-block;
-      font-size: 30px;
-      font-weight: bolder;
-      height: 50%;
+      font-size: 22px;
+      color: #4D4D4D;
+      padding-top: 4%;
+      font-family: PingFangSC-Bold,serif;
+      height: 46%;
     }
     .coreData-item-unit {
       display: inline-block;

+ 2 - 0
src/components/dashboard/portrait/cold/coldTrendChart.vue

@@ -83,6 +83,7 @@ export default {
             stack: 'a',
             yAxisIndex:0,
             smooth: true,
+            showSymbol:false,
             lineStyle: {
               color: "#62CC97",
               width: 1,
@@ -100,6 +101,7 @@ export default {
             type: 'line',
             stack: 'b',
             smooth: true,
+            showSymbol:false,
             yAxisIndex:1,
             lineStyle: {
               color: "#FDB456",

+ 5 - 7
src/components/dashboard/portrait/coldPortrait.vue

@@ -10,22 +10,19 @@ export default {
           title: '月总用冷量(kWh)',
           num: 2000,
           historyDesc: '同比',
-          historyNum: '0.4'
+          historyNum: 0.4
         },
         {
           type: 0,
           title: '今日用冷趋势',
           num: 1800,
           historyDesc: '同比',
-          historyNum: '0.4'
+          showTrendIcon: true,
         },
         {
-          type: 0,
+          type: 1,
           title: '能效比',
-          num: 30,
-          unit: '%',
-          historyDesc: '同比',
-          historyNum: '0.4'
+          content: 80,
         },
         {
           type: 0,
@@ -37,6 +34,7 @@ export default {
         {
           type: 1,
           isHighLight: false,
+          showStar: true,
           title: '值得关注',
           content: ''
         },

+ 1 - 0
src/components/dashboard/portrait/electricity/electricityUseChart.vue

@@ -74,6 +74,7 @@ export default {
             type: 'line',
             stack: 'x',
             smooth: true,
+            showSymbol:false,
             areaStyle: {
               color: new this.$echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                 offset: 0,

+ 5 - 6
src/components/dashboard/portrait/electricityPortrait.vue

@@ -23,23 +23,22 @@ export default {
         {
           type: 0,
           title: '今日用电趋势',
-          num: 30,
-          unit: '%',
+          num: -30,
+          showTrendIcon: true,
           historyDesc: '同比',
-          historyNum: 0.4
         },
         {
           type: 0,
           title: '人均用电成本(元/天)',
-          num: 30,
+          num: 80,
           historyDesc: '同比',
           historyNum: -0.4
         },
         {
           type: 1,
-          isHighLight: false,
+          showStar: true,
           title: '值得关注',
-          content: ''
+          content: '用电成本月增速5%,主为动力用电'
         },
       ]
     }

+ 2 - 0
src/components/dashboard/portrait/hot/hotTrendChart.vue

@@ -83,6 +83,7 @@ export default {
             stack: 'a',
             yAxisIndex:0,
             smooth: true,
+            showSymbol:false,
             lineStyle: {
               color: "#62CC97",
               width: 1,
@@ -101,6 +102,7 @@ export default {
             stack: 'b',
             yAxisIndex:1,
             smooth: true,
+            showSymbol:false,
             itemStyle: {
               color: '#FDB456'
             },

+ 6 - 7
src/components/dashboard/portrait/hotPortrait.vue

@@ -16,29 +16,28 @@ export default {
           type: 0,
           title: '今日用热趋势',
           num: 1800,
+          showTrendIcon: true,
           historyDesc: '同比',
-          historyNum: '0.4'
         },
         {
           type: 0,
           title: '人均用热成本(kWh)',
-          num: 30,
-          unit: '%',
+          num: 10,
           historyDesc: '同比',
           historyNum: '0.4'
         },
         {
           type: 0,
           title: '人均用热量(kWh/天)',
-          num: 30,
+          num: 78,
           historyDesc: '同比',
-          historyNum: '0.4'
+          historyNum: '-0.4'
         },
         {
           type: 1,
-          isHighLight: false,
+          showStar: true,
           title: '值得关注',
-          content: ''
+          content: '本月用热将超行业标准20%'
         },
       ]
     }

+ 2 - 2
src/components/dashboard/portrait/moneyPortrait.vue

@@ -36,9 +36,9 @@ export default {
         },
         {
           type: 1,
-          isHighLight: false,
+          showStar: true,
           title: '值得关注',
-          content: ''
+          content: '本月投资将超行业标准20%'
         },
       ]
     }

+ 3 - 0
src/components/dashboard/portrait/person/personTrendChart.vue

@@ -79,6 +79,7 @@ export default {
             type: 'line',
             stack: 'x',
             smooth: true,
+            showSymbol:false,
             areaStyle: {
               color: new this.$echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                 offset: 0,
@@ -102,6 +103,7 @@ export default {
             type: 'line',
             stack: 'x',
             smooth: true,
+            showSymbol:false,
             areaStyle: {
               color: new this.$echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                 offset: 0,
@@ -125,6 +127,7 @@ export default {
             type: 'line',
             stack: 'x',
             smooth: true,
+            showSymbol:false,
             areaStyle: {
               color: new this.$echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                 offset: 0,

+ 1 - 1
src/components/dashboard/portrait/personPortrait.vue

@@ -35,8 +35,8 @@ export default {
         },
         {
           type: 1,
-          isHighLight: false,
           title: '值得关注',
+          showStar: true,
           content: '本周上班时间持续延后'
         },
       ]

+ 1 - 0
src/components/dashboard/portrait/restaurant/restaurantTrendChart.vue

@@ -125,6 +125,7 @@ export default {
             },
             yAxisIndex:1,
             smooth: true,
+            showSymbol:false,
             areaStyle: {
               color: new this.$echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                 offset: 0,

+ 3 - 4
src/components/dashboard/portrait/restaurantPortrait.vue

@@ -23,20 +23,19 @@ export default {
           type: 0,
           title: '餐厅平均单价(元/单)',
           num: 30,
-          unit: '%',
           historyDesc: '同比',
           historyNum: '0.4'
         },
         {
           type: 1,
           title: '第三方结算方式 费用(元)',
-          content: ''
+          content: '200'
         },
         {
           type: 1,
-          isHighLight: false,
+          showStar: true,
           title: '值得关注',
-          content: ''
+          content: '提高合同额'
         },
       ]
     }

+ 1 - 0
src/components/dashboard/portrait/supermarket/supermarketTrendChart.vue

@@ -125,6 +125,7 @@ export default {
             },
             yAxisIndex:1,
             smooth: true,
+            showSymbol:false,
             areaStyle: {
               color: new this.$echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                 offset: 0,

+ 4 - 5
src/components/dashboard/portrait/supermarketPortrait.vue

@@ -22,21 +22,20 @@ export default {
         {
           type: 0,
           title: '商超平均单价(元/单)',
-          num: 30,
-          unit: '%',
+          num: 18,
           historyDesc: '同比',
           historyNum: '0.4'
         },
         {
           type: 1,
           title: '第三方结算方式 费用(元)',
-          content: ''
+          content: '30'
         },
         {
           type: 1,
-          isHighLight: false,
           title: '值得关注',
-          content: ''
+          showStar: true,
+          content: '提高合同额'
         },
       ]
     }

+ 1 - 0
src/components/dashboard/portrait/water/waterUseChart.vue

@@ -74,6 +74,7 @@ export default {
             type: 'line',
             stack: 'x',
             smooth: true,
+            showSymbol:false,
             areaStyle: {
               color: new this.$echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                 offset: 0,

+ 4 - 4
src/components/dashboard/portrait/waterPortrait.vue

@@ -24,22 +24,22 @@ export default {
           type: 0,
           title: '今日用水趋势',
           num: 30,
-          unit: '%',
+          showTrendIcon: true,
           historyDesc: '同比',
           historyNum: '0.4'
         },
         {
           type: 0,
           title: '人均用水量(m³)',
-          num: 30,
+          num: 60,
           historyDesc: '同比',
           historyNum: '0.4'
         },
         {
           type: 1,
-          isHighLight: false,
+          showStar: true,
           title: '值得关注',
-          content: ''
+          content: '用水量低于行业标准20%'
         },
       ]
     }

+ 1 - 1
src/components/home/ContainerAside.vue

@@ -71,7 +71,7 @@ export default {
         </span>
             <span>{{ item.name }}</span>
           </template>
-          <a-menu-item v-for="subItem in item.children" :key="subItem.path" :route="subItem.path">
+          <a-menu-item v-for="subItem in item.children" :key="subItem.router" :route="subItem.router">
             <span class="anticon" style="vertical-align: text-top">
           <a-avatar class="function-avatar" shape="square" :size="20" :src="requireImg(item.icon)"></a-avatar>
         </span>