Переглянути джерело

Merge branch 'mw' of http://124.70.43.205:3000/yangxiao/sis_zhfx into wangbo

Administrator 3 роки тому
батько
коміт
e80458f6bd

+ 13 - 38
src/App.vue

@@ -254,45 +254,20 @@ l16.229-16.229l16.229,16.229l42.867-42.867C115.034,45.228,109.133,42.189,102.956
         active-text-color="#6262a2"
         background-color="#36348e"
       >
-        <el-sub-menu
-          :index="index"
-          :title="item.text"
-          v-for="(item, index) in menuData"
-        >
+        <el-sub-menu :index="index" :title="item.text" v-for="(item , index) in menuData">
           <template #title>
-            <router-link :to="item.path">
-              <el-icon>
-                <SvgIcon :svgid="item.icon" />
-              </el-icon>
-            </router-link>
+			  <router-link :to="item.path">
+				<el-icon>
+				  <SvgIcon :svgid="item.icon" />
+				</el-icon>
+			</router-link>
           </template>
-          <el-menu-item-group v-for="(menu, idx) in item.children" :index="idx">
-            <router-link :to="menu.path">
-              <el-menu-item :index="index + '-' + idx">{{
-                menu.text
-              }}</el-menu-item>
-            </router-link>
+          <el-menu-item-group v-for="(menu , idx) in item.children" :index="idx">
+			  <router-link :to="menu.path">
+				<el-menu-item :index="index+'-'+idx">{{menu.text}}</el-menu-item>
+			</router-link>
           </el-menu-item-group>
         </el-sub-menu>
-        <!-- <el-sub-menu index="2" title="菜单2">
-          <template #title>
-            <el-icon>
-              <SvgIcon svgid="svg-matrix" />
-            </el-icon>
-          </template>
-          <el-menu-item-group>
-            <template #title><span>Group One</span></template>
-            <el-menu-item index="2-1">item one</el-menu-item>
-            <el-menu-item index="2-2">item two</el-menu-item>
-          </el-menu-item-group>
-          <el-menu-item-group title="Group Two">
-            <el-menu-item index="2-3">item three</el-menu-item>
-          </el-menu-item-group>
-          <el-sub-menu index="2-4">
-            <template #title><span>item four</span></template>
-            <el-menu-item index="2-4-1">item one</el-menu-item>
-          </el-sub-menu>
-        </el-sub-menu> -->
       </el-menu>
     </div>
     <div class="main-body">
@@ -339,7 +314,7 @@ export default {
       isLogined: true,
       showSisView: false,
       memuCloseTimeout: null,
-      menuData: [],
+	  menuData:[]
     };
   },
 
@@ -405,8 +380,8 @@ export default {
       this.showSisView = res.fullPath === "/sisView";
     },
     "$store.state.menuData"(res) {
-      this.menuData = res;
-    },
+		this.menuData = res;
+	},
   },
 };
 </script>

+ 2 - 0
src/assets/styles/common/common.less

@@ -23,5 +23,7 @@
 @import "../theme/light/light-sp.less"; // 沙盘
 @import "../theme/light/light-qt.less"; // 其他
 
+@import "../theme/light/jjyx-dbgl.less"; // 对标管理
+
 // 暗色主题
 @import "../theme/dark/dark-jsc.less"; // 驾驶舱

+ 95 - 0
src/assets/styles/theme/light/jjyx-dbgl.less

@@ -0,0 +1,95 @@
+// 对标管理
+@import "./setting.less";
+#appBody.light {
+	// 风机绩效榜
+    .com-table {
+		thead tr th{
+			color: @black;
+		}
+		
+		.el-scrollbar tr td {
+			color: @black;
+		}
+		
+		.el-scrollbar tr td.light span {
+			color: @blue;
+		}
+	}
+	.btn.green,.btn:hover{
+		color: @deepblue;
+		border-color: @deepblue;
+		background: rgba(54, 52, 142, 0.2);
+	}
+	
+	.el-select__popper.select,.el-picker__popper{
+		background: @white;
+        border-color: @white;
+		.el-popper__arrow::before{
+			border: 1px solid @white !important;
+			background: @white !important;
+		}
+		.el-select-dropdown__item.selected,.el-select-dropdown__item:hover {
+		    color: @deepblue;
+			background:fade(@deepblue, 20);
+			border: 1px solid @deepblue;
+		}
+		.el-select-dropdown__item{
+			color:@black;
+		}
+	}
+	
+	.el-picker__popper.el-popper[role="tooltip"] {
+		background: @white !important;
+		border-color: @white !important;
+		.el-date-table{
+			th{
+				color:@black ;
+			}
+			td.current:not(.disabled) span{
+				color: @white;
+				background:@blue;
+			}
+			td.today span,span:hover {
+			    color: @blue;
+			}
+			td.prev-month,td.next-month{
+				background: fade(@black,20);
+			}
+			span{
+				color:@black;
+			}
+		}
+		
+	}
+	.el-input{
+		.el-input__inner{
+			background: @white;
+			color: @black;
+		}
+	}
+	.query-item .lable{
+		color:@black;
+	}
+	
+	// 风机绩效榜-明细
+	.main-body{
+		input[type="checkbox"]:checked{
+			background:@blue;
+			border-color: @blue;
+		}
+		input[type="checkbox"]{
+			background: @white;
+			border-color: @white;
+		}
+	} 
+	
+	.decision-page-2{
+		.com-panel{
+			border-radius:0;
+			padding:0;
+		}
+	}
+	.action{
+		color: @blue;
+	}
+}

+ 10 - 10
src/assets/styles/theme/light/jsc-jcjz.less

@@ -5,7 +5,7 @@
 
 #appBody.light {
     .panel-body{
-        background:#fff;
+        background:@white;
         transition: @transition;
     }
     .card-panel .card-left .tag{
@@ -24,30 +24,30 @@
     //驾驶舱模块-矩阵白色主题样式二级页面
     //基本信息-日发电量1
     .wind-site-base-info .generation {
-        background: #fff;
+        background: @white;
     }
     //基本信息-日发电量2
     .el-col-10 {
-        background: #fff;
+        background: @white;
     }
     //基本信息-日发电量右侧
     .wind-site-warning{
-        background: #fff;
+        background: @white;
         transition: @transition;
     }
     //右侧导航栏第一个-天气
     .wind-site-weather[data-v-ccb406f8]{
-        background: #fff;
+        background: @white;
         transition: @transition;
     }
     //右侧导航栏第一个-最右侧
     .light-matrix-small{
-        background: #fff;
+        background: @white;
         transition: @transition;
     }
     //最右侧导航
     .wind-site .page-common-body .page-common-body-menu .page-common-body-menu-box[data-v-3b6e4be5]{
-        background-color: #fff;
+        background-color: @white;
         transition: @transition;
     }
     .wind-site .page-common-body .page-common-body-menu .page-common-body-menu-box .page-common-body-menu-item[data-v-3b6e4be5] {
@@ -55,15 +55,15 @@
     }
     //右侧导航栏第二个底色
      .df-table .custom-table.el-table{
-        background: #fff;
+        background: @white;
         transition: @transition;
     }
     .general-appearance-body{
-        background: #fff;
+        background: @white;
         transition: @transition;
     }
     .booster-station-body{
-        background: #fff;
+        background: @white;
         transition: @transition;
     }
     .Inverter-Info .box-main .Inverter-Info-body .Inverter-Info-title{

+ 3 - 1
src/assets/styles/theme/light/light-jsc.less

@@ -375,11 +375,13 @@
 	
 	.el-popper.is-light.is-pure .el-menu--popup {
 	  padding:0;
+	  .el-menu-item-group__title{padding:0;}
+	  .el-menu-item{height: 46px;line-height: 46px;}
 	}
 	
 	.el-popper.is-light{
-		background:transparent;
 		border:none;
+		.el-menu{border-radius: 0px;}
 	}
 	
     .com-panel-3 {

+ 3 - 1
src/assets/styles/theme/light/setting.less

@@ -4,6 +4,8 @@
 @transition : 0.25s;
 @deepblue   : #36348e;
 @borderRaduis: 12px;
+@blue : #159AFA;
+@white : #ffffff;
 @gray-l     : #B3BDC0;
 @darkgray-1 : #7b7d7e;
-@green      : #05bb4c;
+@green      : #05bb4c;

+ 41 - 14
src/components/chart/combination/bar-line-chart.vue

@@ -123,18 +123,26 @@ export default {
           icon: "ract",
           itemWidth: 8,
           itemHeight: 8,
-          inactiveColor: partten.getColor("gray"),
+          inactiveColor: this.$store.state.themeName === "dark"
+              ? partten.getColor("gray")
+              : "#000",
           textStyle: {
-            color: partten.getColor("grayl"),
+            color: this.$store.state.themeName === "dark"
+              ? partten.getColor("grayl")
+              : "#000",
             fontSize: 12,
           },
         },
         tooltip: {
           trigger: "axis",
-          backgroundColor: "rgba(0,0,0,0.4)",
-          borderColor: partten.getColor("gray"),
+          backgroundColor: this.$store.state.themeName === "dark"
+              ? "rgba(0,0,0,0.4)"
+              : "rgba(255,255,255,0.5)",
+          borderColor: this.$store.state.themeName === "dark"
+              ? partten.getColor("gray")
+              : "#000",
           textStyle: {
-            color: "#fff",
+            color: this.$store.state.themeName === "dark" ? "#fff" : "#000",
             fontSize: util.vh(16),
           },
         },
@@ -153,7 +161,9 @@ export default {
             backgroundColor: "transparent",
             // handleIcon: "path://M306.1,413c0,2.2-1.8,4-4,4h-59.8c-2.2,0-4-1.8-4-4V200.8c0-2.2,1.8-4,4-4h59.8c2.2,0,4,1.8,4,4V413z",
             handleStyle: {
-              color: partten.getColor("green"),
+              color: this.$store.state.themeName === "dark"
+              ? partten.getColor("green")
+              : partten.getColor("blue"),
             },
             moveHandleSize: 0,
             // dataBackground: {
@@ -174,9 +184,13 @@ export default {
             // },
             fillerColor: "transparent",
             textStyle: {
-              color: partten.getColor("grayl"),
+              color: this.$store.state.themeName === "dark"
+              ? partten.getColor("grayl")
+              : "#000",
             },
-            borderColor: partten.getColor("gray"),
+            borderColor: this.$store.state.themeName === "dark"
+              ? partten.getColor("gray")
+              : "#000",
             brushSelect: false,
           },
         ],
@@ -184,7 +198,9 @@ export default {
           {
             type: "category",
             axisLabel: {
-              color: partten.getColor("gray"),
+              color: this.$store.state.themeName === "dark"
+              ? partten.getColor("gray")
+              : "#000",
             },
             inverse: true,
             // minInterval: 10,
@@ -202,12 +218,16 @@ export default {
           {
             type: "value",
             axisLabel: {
-              color: partten.getColor("gray"),
+              color: this.$store.state.themeName === "dark"
+              ? partten.getColor("gray")
+              : "#000",
             },
             axisLine: {
               type: "dashed",
               lineStyle: {
-                color: partten.getColor("gray"),
+                color: this.$store.state.themeName === "dark"
+              ? partten.getColor("gray")
+              : "#000",
               },
               width: 5,
             },
@@ -218,7 +238,7 @@ export default {
               lineStyle: {
                 type: "dashed",
                 dashOffset: 10,
-                color: partten.getColor("gray") + 80,
+                color: this.$store.state.themeName === "dark" ? "#5a6162" : "#000" + 80,
               },
             },
           },
@@ -269,10 +289,14 @@ export default {
           smooth: false, //平滑展示
           xAxisIndex: 1,
           lineStyle: {
-            color: partten.getColor("green"),
+            color: this.$store.state.themeName === "dark"
+              ? partten.getColor("green")
+              : partten.getColor("blue"),
           },
           itemStyle: {
-            color: partten.getColor("green"),
+            color: this.$store.state.themeName === "dark"
+              ? partten.getColor("green")
+              : partten.getColor("blue"),
           },
         });
       }
@@ -315,6 +339,9 @@ export default {
         }
       }
     },
+	"$store.state.themeName"() {
+	  this.initChart();
+	},
   },
 };
 </script>

+ 25 - 10
src/components/chart/pie/dual-pie-chart.vue

@@ -99,10 +99,14 @@ export default {
         color: ["#1893ce", "#edbf00", "#039178", "#ae4802", "#ea8b00"],
         tooltip: {
           trigger: "item",
-          backgroundColor: "rgba(0,0,0,0.4)",
-          borderColor: partten.getColor("gray"),
+          backgroundColor: this.$store.state.themeName === "dark"
+              ? "rgba(0,0,0,0.4)"
+              : "rgba(255,255,255,0.5)",
+          borderColor: this.$store.state.themeName === "dark"
+              ? partten.getColor("gray")
+              : "#000",
           textStyle: {
-            color: "#fff",
+            color: this.$store.state.themeName === "dark" ? "#fff" : "#000",
             fontSize: util.vh(16),
           },
         },
@@ -128,15 +132,21 @@ export default {
           //icon: 'circle',
           itemGap: 12, //图例item间距
           textStyle: {
-            color: partten.getColor("gray"),
+            color: this.$store.state.themeName === "dark"
+              ? partten.getColor("gray")
+              : "#000",
             fontSize: util.vh(14),
             rich: {
               name: {
-                color: partten.getColor("gray"),
+                color: this.$store.state.themeName === "dark"
+              ? partten.getColor("gray")
+              : "#000",
                 fontSize: 12,
               },
               value: {
-                color: partten.getColor("grayl"),
+                color: this.$store.state.themeName === "dark"
+                ? partten.getColor("grayl")
+                : "#000",
                 fontSize: 12,
               },
             },
@@ -175,14 +185,14 @@ export default {
                 // length: 40,
                 // length2: 120,
                 lineStyle: {
-                  color: "#fff",
+                  color: this.$store.state.themeName === "dark" ? "#fff" : "#000",
                   fontSize: util.vh(14),
                 },
               },
             },
             itemStyle: {
               normal: {
-                borderWidth: util.vh(14),
+                borderWidth:this.$store.state.themeName === "dark" ? util.vh(14): util.vh(8),
                 borderColor: "#071812",
               },
             },
@@ -193,10 +203,10 @@ export default {
                 },
                 padding: [0, 0, 0, 0],
                 rich: {
-                  color: "#ffffff" + "cc",
+                  color: this.$store.state.themeName === "dark" ? "#fff" : "#000",
                   percent: {
                     fontSize: util.vh(14),
-                    color: "#ffffff" + "cc",
+                    color: this.$store.state.themeName === "dark" ? "#FFFFFF" : "#000000" ,
                   },
                 },
               },
@@ -220,6 +230,11 @@ export default {
   updated() {
     this.initChart();
   },
+  watch: {
+    "$store.state.themeName"() {
+      this.initChart();
+    },
+  },
 };
 </script>
 

+ 2 - 2
src/helper/partten.js

@@ -12,11 +12,11 @@ const color = [
 	{ key: "cyan", value: "#1cbbb4" },
 	{ key: "brown", value: "#a5673f" },
 	{ key: "mauve", value: "#9c26b0" },
+	{ key: "deepblue", value: "#36348e" },
 ];
 
 function getColor(key) {
-    if (!key)
-        key = "green"
+	if(!color.some(ele=>{ return ele.key === key })) key = "green";
     return color.find((t) => { return t.key == key }).value;
 }
 

Різницю між файлами не показано, бо вона завелика
+ 653 - 702
src/views/NewPages/alarm-center-1.vue


+ 7 - 18
src/views/NewPages/alarm-center-2.vue

@@ -39,26 +39,12 @@
       <table-2 :data="tableData" :height="'88vh'">
         <template v-for="(item, i) in column" :key="i" #[item]="scope">
           <div class="bar">
-            <div class="bar-percent" :style="{
-                width:
-                  (scope.data.count &&
-                    scope.data.count / (scope.data.count + scope.data.time)) *
-                    100 +
-                  'px',
-              }"></div>
-            <span class="value">{{
-              scope.data.count && scope.data.count
-              }}</span>
+          	<div class="bar-percent" :style="{ width: scope?.data?.countStyle }"> </div>
+          	<span class="value">{{ scope?.data?.count }} 次数</span>
           </div>
           <div class="bar">
-            <div class="bar-percent" :style="{
-                width:
-                  (scope.data.count &&
-                    scope.data.time / (scope.data.count + scope.data.time)) *
-                    100 +
-                  'px',
-              }"></div>
-            <span class="value">{{ scope.data.count && scope.data.time }}</span>
+          	<div class="bar-percent" :style="{ width: scope?.data?.timeStyle}"></div>
+          	<span class="value">{{scope?.data?.time }} 分钟</span>
           </div>
         </template>
       </table-2>
@@ -210,6 +196,7 @@ export default {
     },
     async searchData () {
       const { data } = await this.API.requestData({
+		  showLoading:true,
         baseURL: "http://192.168.1.18:8075/",
         subUrl: "shutdown/list",
         data: {
@@ -233,7 +220,9 @@ export default {
             if (k.type == c.name) {
               let obj1 = {
                 count: k.count,
+                countStyle:((k.count / (k.count + k.time)) * 100) + 'px',
                 time: k.time,
+                timeStyle:((k.time / (k.count + k.time)) * 100) + 'px'
               };
               obj[k.type] = obj1;
             }

+ 1 - 1
src/views/singleAnalysis/index.vue

@@ -43,7 +43,7 @@
       <ComTable height="78vh" :data="tableData">
         <template v-slot:tr v-if="tableData.data.length > 0">
           <tr>
-            <td v-for="(item, index) in tableData.column" key="index">
+            <td v-for="(item, index) in tableData.column" :key="index">
               {{ tableDataEnd[item.field] }}
             </td>
           </tr>