Browse Source

Merge branch 'mw2' of http://61.161.152.110:10101/r/electronic-map into mw2

mw_666 3 years ago
parent
commit
9b33f78bd5

+ 224 - 196
src/views/WindSite/WindSite.vue

@@ -1,203 +1,231 @@
 <template>
-  <div class="wind-site">
-    <div class="page-common-body">
-      <div class="page-common-body-router">
-        <router-view />
-      </div>
-      <div class="page-common-body-menu">
-        <div class="page-common-body-menu-box">
-          <div class="page-common-body-menu-border left top"></div>
-          <div class="page-common-body-menu-border left bottom"></div>
-          <div class="page-common-body-menu-border right top"></div>
-          <div class="page-common-body-menu-border right bottom"></div>
-          <router-link v-for="(menuData, index) of menuDatas" :key="index" :to="menuData.path">
-            <div class="page-common-body-menu-item" @click="clickMenu(index)" :class="{ active: activeIndex == index }">
-              <span class="svg-icon" :class="activeIndex == index ? 'svg-icon-yellow' : 'svg-icon-green'">
-                <SvgIcon :svgid="menuData.icon"></SvgIcon>
-              </span>
-            </div>
-          </router-link>
-        </div>
-      </div>
-    </div>
-  </div>
+	<div class="wind-site">
+		<div class="page-common-body">
+			<div class="page-common-body-router">
+				<router-view />
+			</div>
+			<div class="page-common-body-menu">
+				<div class="page-common-body-menu-box">
+					<div class="page-common-body-menu-border left top"></div>
+					<div class="page-common-body-menu-border left bottom"></div>
+					<div class="page-common-body-menu-border right top"></div>
+					<div class="page-common-body-menu-border right bottom"></div>
+					<router-link v-for="(menuData, index) of menuDatas" :key="index" :to="menuData.path">
+						<div class="page-common-body-menu-item" @click="clickMenu(index)"
+							:class="{ active: activeIndex == index }">
+							<span class="svg-icon" :class="activeIndex == index ? 'svg-icon-yellow' : 'svg-icon-green'">
+								<SvgIcon :svgid="menuData.icon"></SvgIcon>
+							</span>
+						</div>
+					</router-link>
+				</div>
+			</div>
+		</div>
+	</div>
 </template>
 
 <script>
-import SvgIcon from "@com/coms/icon/svg-icon.vue";
-export default {
-  // 名称
-  name: "WindSite",
-  // 使用组件
-  components: {
-    SvgIcon,
-  },
-  // 数据
-  data() {
-    return {
-      activeIndex: 0,
-      menuDatas: [
-        {
-          icon: "svg-s场站监视",
-          path: "/monitor/windsite/home",
-        },
-        {
-          icon: "svg-s指标列表",
-          path: "/monitor/windsite/draughtfanlist",
-        },
-        // {
-        //   icon: "svg-agc",
-        //   path: "/monitor/windsite/matrix",
-        // },
-        // {
-        //   icon: "svg-agc",
-        //   path: "/monitor/windsite/lightmatrix",
-        // },
-        // {
-        //   icon: "svg-intranet-involvement",
-        //   path: "/monitor/windsite/box",
-        // },
-        // {
-        //   icon: "svg-matrix",
-        //   path: "/monitor/windsite/info",
-        // },
-        {
-          icon: "svg-s测风塔",
-          path: "/monitor/windsite/tower",
-        },
-        // {
-        //   icon: "svg-easy-compass",
-        //   path: "/monitor/windsite/Inverter-Info",
-        // },
-        // {
-        //   icon: "svg-easy-compass",
-        //   path: "/monitor/windsite/map",
-        // },
-        // {
-        //   icon: "svg-easy-compass",
-        //   path: "/monitor/windsite/map1",
-        // },
-        {
-          icon: "svg-matrix",
-          path: "/monitor/windsite/matrix",
-        },
-        {
-          icon: "svg-s总貌",
-          path: "/monitor/windsite/generalappearance",
-        },
-        {
-          icon: "svg-s升压站",
-          path: "/monitor/windsite/boosterstation",
-        },
-        {
-          icon: "svg-s地图",
-          path: "/monitor/windsite/map",
-        },
-      ],
-    };
-  },
-  // 函数
-  methods: {
-    clickMenu: function(index) {
-      this.activeIndex = index;
-    },
-  },
-
-  created() {
-    this.menuDatas.forEach((ele) => {
-      ele.path = ele.path + "/" + this.$route.params.wpId;
-    });
-  },
-
-  mounted() {},
-};
+	import SvgIcon from "@com/coms/icon/svg-icon.vue";
+	export default {
+		// 名称
+		name: "WindSite",
+		// 使用组件
+		components: {
+			SvgIcon,
+		},
+		// 数据
+		data() {
+			return {
+				windsitePath: '',
+				activeIndex: 0,
+				menuDatas: [{
+						icon: "svg-s场站监视",
+						path: "/monitor/windsite/home",
+					},
+					{
+						icon: "svg-s指标列表",
+						path: "/monitor/windsite/draughtfanlist",
+					},
+					// {
+					//   icon: "svg-agc",
+					//   path: "/monitor/windsite/matrix",
+					// },
+					// {
+					//   icon: "svg-agc",
+					//   path: "/monitor/windsite/lightmatrix",
+					// },
+					// {
+					//   icon: "svg-intranet-involvement",
+					//   path: "/monitor/windsite/box",
+					// },
+					// {
+					//   icon: "svg-matrix",
+					//   path: "/monitor/windsite/info",
+					// },
+					{
+						icon: "svg-s测风塔",
+						path: "/monitor/windsite/tower",
+					},
+					// {
+					//   icon: "svg-easy-compass",
+					//   path: "/monitor/windsite/Inverter-Info",
+					// },
+					// {
+					//   icon: "svg-easy-compass",
+					//   path: "/monitor/windsite/map",
+					// },
+					// {
+					//   icon: "svg-easy-compass",
+					//   path: "/monitor/windsite/map1",
+					// },
+					{
+						icon: "svg-matrix",
+						path: "/monitor/windsite/matrix",
+					},
+					{
+						icon: "svg-s总貌",
+						path: "/monitor/windsite/generalappearance",
+					},
+					{
+						icon: "svg-s升压站",
+						path: "/monitor/windsite/boosterstation",
+					},
+					{
+						icon: "svg-s地图",
+						path: "/monitor/windsite/map",
+					},
+					{
+						icon: "svg-wind-site",
+						path: this.windsitePath,
+					},
+				],
+			};
+		},
+		// 函数
+		methods: {
+			jumpUrl() {
+				var p = this.$route.path.split('/');
+				var pData = p[p.length - 1].split('_');
+				var wpId = p[p.length - 1];
+				if (wpId.indexOf("FDC") !== -1) {
+					this.windsitePath = `/monitor/windsite/info/${wpId}/${pData[0] + '01_01'}`
+				} else {
+					this.windsitePath = `../../windsite/inverter-info/${wpId}/${pData[0] + '01_01'}`
+				}
+			},
+			clickMenu: function(index) {
+				if (index == 7) { //风场
+					this.jumpUrl();
+					this.menu(index);
+				}
+				this.activeIndex = index;
+			},
+			menu(index) {
+				if(index){
+					this.menuDatas[index].path = this.windsitePath;
+				}else{
+					this.menuDatas.forEach((ele) => {
+						if (ele.icon == 'svg-wind-site') {
+							ele.path = this.windsitePath
+						} else {
+							ele.path = ele.path + "/" + this.$route.params.wpId;
+						}
+					});
+				}
+			}
+		},
+		created() {
+			this.jumpUrl();
+			this.menu();
+		},
+	};
 </script>
 
 <style lang="less" scoped>
-.wind-site {
-  .page-common-body {
-    display: flex;
-    flex-direction: row;
-    margin-top: 0.741vh;
-
-    .page-common-body-router {
-      overflow: auto;
-      overflow-x: hidden;
-      height: calc(100vh - 7.037vh);
-      flex: 1 1 auto;
-    }
-
-    .page-common-body-menu {
-      width: 7.407vh;
-      padding: 0 1.481vh 1.481vh 1.481vh;
-
-      .page-common-body-menu-box {
-        border: 0.093vh solid @darkgray;
-        background-color: fade(@darkgray, 30%);
-        padding: 2.222vh 0.185vh;
-        position: relative;
-
-        .page-common-body-menu-border {
-          position: absolute;
-          width: 0.37vh;
-          height: 0.37vh;
-          background-color: @write;
-          border-radius: 50%;
-
-          &.left {
-            left: -0.185vh;
-          }
-
-          &.right {
-            right: -0.185vh;
-          }
-
-          &.top {
-            top: -0.185vh;
-          }
-
-          &.bottom {
-            bottom: -0.185vh;
-          }
-        }
-
-        .page-common-body-menu-item {
-          border: 0.093vh solid fade(@green, 40%);
-          width: 3.889vh;
-          height: 3.889vh;
-          border-radius: 0.278vh;
-          margin-top: 0.741vh;
-          display: flex;
-          align-items: center;
-          justify-content: center;
-          cursor: pointer;
-
-          a {
-            line-height: 0;
-          }
-
-          // &:first-child {
-          //   margin-top: 0;
-          // }
-
-          &.active {
-            border-color: fade(@yellow, 40%);
-            position: relative;
-
-            &::after {
-              content: "";
-              width: calc(100% - 0.37vh);
-              height: calc(100% - 0.37vh);
-              position: absolute;
-              border: 0.093vh solid @yellow;
-              box-shadow: 0 0 0.37vh @yellow;
-              top: 0.093vh;
-              left: 0.093vh;
-            }
-          }
-        }
-      }
-    }
-  }
-}
-</style>
+	.wind-site {
+		.page-common-body {
+			display: flex;
+			flex-direction: row;
+			margin-top: 0.741vh;
+
+			.page-common-body-router {
+				overflow: auto;
+				overflow-x: hidden;
+				height: calc(100vh - 7.037vh);
+				flex: 1 1 auto;
+			}
+
+			.page-common-body-menu {
+				width: 7.407vh;
+				padding: 0 1.481vh 1.481vh 1.481vh;
+
+				.page-common-body-menu-box {
+					border: 0.093vh solid @darkgray;
+					background-color: fade(@darkgray, 30%);
+					padding: 2.222vh 0.185vh;
+					position: relative;
+
+					.page-common-body-menu-border {
+						position: absolute;
+						width: 0.37vh;
+						height: 0.37vh;
+						background-color: @write;
+						border-radius: 50%;
+
+						&.left {
+							left: -0.185vh;
+						}
+
+						&.right {
+							right: -0.185vh;
+						}
+
+						&.top {
+							top: -0.185vh;
+						}
+
+						&.bottom {
+							bottom: -0.185vh;
+						}
+					}
+
+					.page-common-body-menu-item {
+						border: 0.093vh solid fade(@green, 40%);
+						width: 3.889vh;
+						height: 3.889vh;
+						border-radius: 0.278vh;
+						margin-top: 0.741vh;
+						display: flex;
+						align-items: center;
+						justify-content: center;
+						cursor: pointer;
+
+						a {
+							line-height: 0;
+						}
+
+						// &:first-child {
+						//   margin-top: 0;
+						// }
+
+						&.active {
+							border-color: fade(@yellow, 40%);
+							position: relative;
+
+							&::after {
+								content: "";
+								width: calc(100% - 0.37vh);
+								height: calc(100% - 0.37vh);
+								position: absolute;
+								border: 0.093vh solid @yellow;
+								box-shadow: 0 0 0.37vh @yellow;
+								top: 0.093vh;
+								left: 0.093vh;
+							}
+						}
+					}
+				}
+			}
+		}
+	}
+</style>

File diff suppressed because it is too large
+ 858 - 831
src/views/WindSite/pages/Home/Home.vue


+ 2 - 2
src/views/WindSite/pages/Info/Base-Info.vue

@@ -68,8 +68,8 @@
       <el-col :span="10" class="background">
         <el-row type="flex" justify="center" :align="'middle'" class="power-load">
           <!-- 功率复核 PowerLoad -->
-          <el-col v-for="item in PowerLoad" :key="item" :span="6">
-            <dash-pie-chart :title="item.title" :value="sourceMap.jczbmap && sourceMap.jczbmap[item.key]" height="9.722vh" />
+          <el-col v-for="(item , index) in PowerLoad" :key="item" :span="6">
+            <dash-pie-chart :title="item.title" :value="sourceMap.jczbmap && sourceMap.jczbmap[item.key]" height="9.722vh" :max="index==0 ? 100 : 2500"/>
           </el-col>
         </el-row>
       </el-col>

+ 13 - 7
src/views/WindSite/pages/Info/Info.vue

@@ -234,18 +234,20 @@ export default {
   created() {
     let that = this;
     that.wpId = that.$route.params.wpId;
+	that.wtId = that.$route.params.wtId;
+	this.$router.replace(`/monitor/windsite/info/${that.wpId}/${that.wtId}`);
     that.$nextTick(() => {
       that.requestData(false);
-      that.timmer = setInterval(() => {
-        that.requestData(false);
-      }, that.$store.state.websocketTimeSec);
+      // that.timmer = setInterval(() => {
+      //   that.requestData(false);
+      // }, that.$store.state.websocketTimeSec);
     });
   },
 
-  unmounted() {
-    clearInterval(this.timmer);
-    this.timmer = null;
-  },
+  // unmounted() {
+  //   clearInterval(this.timmer);
+  //   this.timmer = null;
+  // },
 
   watch:{
     // "$route"(res){
@@ -257,6 +259,10 @@ export default {
     //     this.requestData(false);
     //   }, this.$store.state.websocketTimeSec);
     // }
+	sourceMap(res){
+		console.log(res)
+		this.sourceMap = res;
+	}
   }
 };
 </script>

+ 13 - 1
src/views/WindSite/pages/Matrix.vue

@@ -12,7 +12,7 @@
       </div>
     </div>
     <div class="panel-body">
-      <div class="card" v-for="(cItem, cIndex) of sourceMap.fjmap[0]" :key="cIndex" :class="cItem.color">
+      <div class="card" v-for="(cItem, cIndex) of sourceMap.fjmap[0]" :key="cIndex" :class="cItem.color" @click="jumpUrl(cItem.wpId,cItem.wtId)">
         <div class="card-panel">
           <div class="card-left">
             <div class="tag">{{ cItem.wtnum }}</div>
@@ -214,6 +214,17 @@ export default {
         path: `/monitor/windsite/matrix/${res.code}`,
       });
     },
+	jumpUrl(wpId, wtId){
+		if (wpId.indexOf("FDC") !== -1) {
+		  this.$router.push({
+		    path: `/monitor/windsite/info/${wpId}/${wtId}`
+		  });
+		} else {
+		  this.$router.push({
+		    path: `../../windsite/inverter-info/${wpId}/${wtId}`
+		  });
+		}
+	  },
   },
 
   created() {
@@ -307,6 +318,7 @@ export default {
       flex: 1 0 125px;
     }
     .card {
+		cursor: pointer;
       margin-right: 4px;
       margin-top: 4px;
       flex: 1 0 125px;

+ 86 - 129
src/views/WindSite/pages/Tower.vue

@@ -43,7 +43,7 @@
         </div>
       </div>
     </Panel>
-    <toolbar-panel class="rose-chart" title="功率曲线">
+    <toolbar-panel class="rose-chart" title="72小时功率曲线">
       <!-- <template v-slot:tools>
       </template> -->
       <!-- <template v-slot:default> -->
@@ -98,20 +98,20 @@ export default {
       cftmap: {},
       glvos: [],
       rmgtmap: {
-        indicator: ["N0", "N1", "N2", "N3", "N4", "N5"],
+        indicator: ["N0", "N1"],
         data: [
           {
-            value: [44200, 14200, 20000, 35000, 50000, 38000],
+            value: [44200, 14200],
             name: "",
           },
         ],
       },
       rmgtTitle: "",
       ymgtmap: {
-        indicator: ["N0", "N1", "N2", "N3", "N4", "N5"],
+        indicator: ["N0", "N1"],
         data: [
           {
-            value: [44200, 14200, 20000, 35000, 50000, 38000],
+            value: [0, 14200],
             name: "",
           },
         ],
@@ -141,127 +141,84 @@ export default {
   // 函数
   methods: {
     requestLine() {
-      let that = this;
-      that.API.requestData({
-        method: "POST",
-        subUrl: "genreset/findPowerInfo",
-        timeout: 60000,
-        data: {
-          id: that.wpId,
-        },
-        success(res) {
-
-          let rdlKey = ["value1", "value2", "value3", "speed"];
-          let DayPower = {
-            // 图表所用单位
-            units: ["(万kWh)", "(m/s)"],
-            value: [
-              {
-                title: "发电量",
-                yAxisIndex: 0,
-                value: [],
-              },
-              {
-                title: "上网电量",
-                yAxisIndex: 0,
-                value: [],
-              },
-              {
-                title: "购网电量",
-                yAxisIndex: 0,
-                value: [],
-              },
-              {
-                title: "实时风速",
-                yAxisIndex: 1,
-                value: [],
-              },
-            ],
-          };
-
-          let glKey = [
-            "value1",
-            "value2",
-            "value3",
-            "value4",
-            "value5",
-            "value6",
-            "value7",
-          ];
-          let Powertrend = [
-            {
-              title: "应发功率",
-              smooth: true,
-              value: [],
-            },
-            {
-              title: "实发功率",
-              smooth: true,
-              value: [],
-            },
-            {
-              title: "理论功率",
-              smooth: true,
-              value: [],
-            },
-            {
-              title: "4小时预测功率",
-              smooth: true,
-              value: [],
-            },
-            {
-              title: "保证功率",
-              smooth: true,
-              value: [],
-            },
-            {
-              title: "平均风速",
-              smooth: true,
-              value: [],
-            },
-            {
-              title: "24小时预测功率",
-              smooth: true,
-              value: [],
-            },
-          ];
-
-          rdlKey.forEach((keyEle, keyIndex) => {
-            res.data.rdlvos.forEach((cEle) => {
-              DayPower.value[keyIndex].value.push({
-                text: cEle.timestr,
-                value: cEle[keyEle],
-              });
-            });
-          });
-
-          glKey.forEach((keyEle, keyIndex) => {
-            res.data.glvos.forEach((cEle) => {
-              Powertrend[keyIndex].value.push({
-                text: new Date(cEle.time).formatDate("hh:mm"),
-                value: cEle[keyEle],
-              });
-            });
-          });
-
-          that.DayPower = DayPower;
-          that.Powertrend = Powertrend;
-        },
-      });
-    },
-    requestData(showLoading) {
-      let that = this;
-      that.API.requestData({
-        showLoading,
-        method: "POST",
-        subUrl: "monitor/findCftInfo",
-        data: {
-          wpId: that.wpId,
-        },
-        success(res) {
-          that.cftmap = res.data.cftmap;
-        },
-      });
+		 let that = this;
+		that.API.requestData({
+		  method: "POST",
+		  subUrl: "/monitor/findCftInfo",
+		  timeout: 60000,
+		  data: {
+		    wpId: that.wpId,
+		  },
+		success(res) {
+			var data = res.data;
+			that.cftmap = data.cftmap;
+			// 日资源玫瑰图
+			var rmgtmapIndicator = [],
+				rmgtmapData = [];
+			data.rmgtmap.data.forEach(item =>{
+				rmgtmapIndicator.push(item.name);
+				rmgtmapData.push(item.data1)
+			})
+			that.rmgtmap = {
+				indicator: rmgtmapIndicator,
+				data: [{value: rmgtmapData}]
+			};
+			// 月资源玫瑰图
+			var ymgtmapIndicator = [],
+				ymgtmapData = [];
+			data.ymgtmap.data.forEach(item =>{
+				ymgtmapIndicator.push(item.name);
+				ymgtmapData.push(item.data1)
+			})
+			that.ymgtmap = {
+				indicator: ymgtmapIndicator,
+				data: [{value: ymgtmapData}]
+			};
+			
+			// 72小时功率曲线图
+			let glKey = ["value2","value1","value5","value4","value7","value6"];
+			let Powertrend = [
+			  {
+			    title: "实发功率",
+			    smooth: true,
+			    value: [],
+			  },
+			  {
+			    title: "理论功率",
+			    smooth: true,
+			    value: [],
+			  },
+			  {
+			    title: "保证功率",
+			    smooth: true,
+			    value: [],
+			  },
+			  {
+			    title: "4小时预测功率",
+			    smooth: true,
+			    value: [],
+			  },
+			  {
+			    title: "24小时预测功率",
+			    smooth: true,
+			    value: [],
+			  },
+			  {
+			    title: "平均风速",
+			    smooth: true,
+			    value: [],
+			  },
+			];
+			glKey.forEach((keyEle, keyIndex) => {
+			  res.data.glvos.forEach((cEle) => {
+			    Powertrend[keyIndex].value.push({
+			      text: new Date(cEle.time).formatDate("hh:mm"),
+			      value: cEle[keyEle],
+			    });
+			  });
+			});
+			that.Powertrend = Powertrend;
+		}})
     },
     getWp () {
       let that = this;
@@ -307,7 +264,7 @@ export default {
       });
       this.wpId = res.code;
       this.renderBtnActiveIndex ();
-      this.requestData(false);
+      // this.requestData(false);
       this.requestLine();
     },
   },
@@ -317,10 +274,10 @@ export default {
     that.wpId = that.$route.params.wpId;
     that.getWp();
     that.$nextTick(() => {
-      that.requestData(false);
+      // that.requestData(false);
       that.requestLine();
       that.timmer = setInterval(() => {
-        that.requestData(false);
+        // that.requestData(false);
         that.requestLine();
       }, 60 * 1000);
     });

File diff suppressed because it is too large
+ 1229 - 1195
src/views/malfunctionRecall/components/fault-diagnosis.vue


+ 276 - 316
src/views/malfunctionRecall/index.vue

@@ -1,49 +1,24 @@
 <template>
-  <div class="knowledge-2">
-    <div class="query mg-b-8">
-      <div class="query-items">
-        <div class="query-item">
-          <div class="lable">场站:</div>
-          <div class="search-input">
-            <el-select
-              v-model="wpId"
-              clearable
-              placeholder="请选择"
-              popper-class="select"
-              @change="
-                (wpId) => {
-                  getWt(wpId, true);
-                }
-              "
-            >
-              <el-option
-                v-for="item in wpArray"
-                :key="item.id"
-                :value="item.id"
-                :label="item.name"
-              />
-            </el-select>
-          </div>
-        </div>
-        <div class="query-item">
-          <div class="lable">风机:</div>
-          <div class="search-input">
-            <el-select
-              v-model="wtId"
-              clearable
-              placeholder="请选择"
-              popper-class="select"
-            >
-              <el-option
-                v-for="item in wtArray"
-                :key="item.id"
-                :value="item.id"
-                :label="item.name"
-              />
-            </el-select>
-          </div>
-        </div>
-        <!-- <div class="query-item">
+	<div class="knowledge-2">
+		<div class="query mg-b-8">
+			<div class="query-items">
+				<div class="query-item">
+					<div class="lable">场站:</div>
+					<div class="search-input">
+						<el-select v-model="wpId" clearable placeholder="请选择" popper-class="select" @change=" (wpId) => { getWt(wpId, true); } ">
+							<el-option v-for="item in wpArray" :key="item.id" :value="item.id" :label="item.name" />
+						</el-select>
+					</div>
+				</div>
+				<div class="query-item">
+					<div class="lable">风机:</div>
+					<div class="search-input">
+						<el-select v-model="wtId" clearable placeholder="请选择" popper-class="select">
+							<el-option v-for="item in wtArray" :key="item.id" :value="item.id" :label="item.name" />
+						</el-select>
+					</div>
+				</div>
+				<!-- <div class="query-item">
           <div class="lable">类型:</div>
           <div class="search-input">
             <el-select
@@ -61,287 +36,272 @@
             </el-select>
           </div>
         </div> -->
-        <div class="query-item">
-          <div class="query-item">
-            <div class="lable">开始日期:</div>
-            <div class="search-input">
-              <el-date-picker
-                v-model="value1"
-                @change="BeginChange(value1)"
-                type="date"
-                value-format="YYYY-MM-DD"
-                placeholder="选择日期"
-                popper-class="date-select"
-              >
-              </el-date-picker>
-            </div>
-          </div>
-          <div class="query-item">
-            <div class="lable">结束日期:</div>
-            <div class="search-input">
-              <el-date-picker
-                v-model="value2"
-                @change="EndChange(value2)"
-                type="date"
-                value-format="YYYY-MM-DD"
-                placeholder="选择日期"
-                popper-class="date-select"
-              >
-              </el-date-picker>
-              <div class="unit svg-icon svg-icon-gray">
-                <svg-icon :svgid="''" />
-              </div>
-            </div>
-          </div>
-        </div>
-      </div>
-      <div class="query-actions" style="margin-right: 1500px">
-        <button class="btn green" @click="onClickSearch">查询</button>
-      </div>
-    </div>
-    <div>
-      <ComTable :data="tableData" height="85vh"></ComTable>
-    </div>
-    <div>
-      <el-dialog
-        title="故障诊断"
-        v-model="dialogVisible"
-        width="1400px"
-        top="10vh"
-        custom-class="modal hide-header"
-        :close-on-click-modal="false"
-        :before-close="onClickDialogClose"
-      >
-        <fault-diagnosis :data="rowitem"/>
-      </el-dialog>
-    </div>
-  </div>
+				<div class="query-item">
+					<div class="query-item">
+						<div class="lable">开始日期:</div>
+						<div class="search-input">
+							<el-date-picker v-model="value1" @change="BeginChange(value1)" type="date"
+								value-format="YYYY-MM-DD" placeholder="选择日期" popper-class="date-select">
+							</el-date-picker>
+						</div>
+					</div>
+					<div class="query-item">
+						<div class="lable">结束日期:</div>
+						<div class="search-input">
+							<el-date-picker v-model="value2" @change="EndChange(value2)" type="date"
+								value-format="YYYY-MM-DD" placeholder="选择日期" popper-class="date-select">
+							</el-date-picker>
+							<div class="unit svg-icon svg-icon-gray">
+								<svg-icon :svgid="''" />
+							</div>
+						</div>
+					</div>
+				</div>
+			</div>
+			<div class="query-actions" style="margin-right: 1500px">
+				<button class="btn green" @click="onClickSearch">查询</button>
+			</div>
+		</div>
+		<div>
+			<ComTable :data="tableData" height="85vh"></ComTable>
+		</div>
+		<div>
+			<el-dialog title="故障诊断" v-model="dialogVisible" width="1400px" top="5vh" custom-class="modal hide-header"
+				:close-on-click-modal="false" :before-close="onClickDialogClose">
+				<fault-diagnosis :data="rowitem" />
+			</el-dialog>
+		</div>
+	</div>
 </template>
 
 <script>
-import ComTable from "@com/coms/table/table.vue";
-import FaultDiagnosis from "./components/fault-diagnosis.vue";
+	import ComTable from "@com/coms/table/table.vue";
+	import FaultDiagnosis from "./components/fault-diagnosis.vue";
 
-export default {
-  components: { ComTable, FaultDiagnosis },
-  data() {
-    const that = this;
-    return {
-      value1: "",
-      value2: "",
-      wpId: "",
-      wpArray: [],
-      rowitem: "",
-      wpName: "",
-      wtId: "",
-      type: "2",
-      dialogVisible: false,
-      tableData: {
-        column: [
-          {
-            name: "场站",
-            field: "wpName",
-            is_num: true,
-            is_light: false,
-          },
-          {
-            name: "机组",
-            field: "windTurbineId",
-            is_num: false,
-            is_light: false,
-          },
-          {
-            name: "开始时刻",
-            field: "stopTime",
-            is_num: false,
-            is_light: false,
-          },
-          {
-            name: "结束时刻",
-            field: "startTime",
-            is_num: false,
-            is_light: false,
-          },
-          {
-            name: "停机小时数(h)",
-            field: "stopHours",
-            is_num: false,
-            is_light: false,
-          },
-          {
-            name: "停机类型",
-            field: "warnDesc",
-            is_num: false,
-            is_light: false,
-          },
-          {
-            name: "损失电量(kWh)",
-            field: "lossPower",
-            is_num: false,
-            is_light: false,
-          },
-          {
-            name: "操作",
-            field: "",
-            is_num: false,
-            is_light: false,
-            template() {
-              return "<el-button type='text' style='cursor: pointer;'>回溯</el-button>";
-            },
-             click(e, row) {
-              that.onClickOption(row);
-            },
-          },
-        ],
-        data: [],
-      },
-    };
-  },
-  created() {
-    this.value1 = new Date(new Date().getTime() - 3600 * 1000 * 24).formatDate(
-      "yyyy-MM-dd"
-    );
-    this.value2 = this.getTime(2);
-    this.getWp();
-  },
-  methods: {
-    getTime(val) {
-      //时间戳处理,val=1是默认开始时间(当前月第一天),val=2是默认结束时间(今天)
-      var date = new Date();
-      var year = date.getFullYear(),
-        month = date.getMonth() + 1,
-        day = date.getDate();
-      month >= 1 && month <= 9 ? (month = "0" + month) : "";
-      day >= 0 && day <= 9 ? (day = "0" + day) : "";
-      var begin = year + "-" + month + "-01";
-      var end = year + "-" + month + "-" + day;
-      if (val == 1) {
-        return begin;
-      } else if (val == 2) {
-        return end;
-      }
-    },
-    // 获取风场
-    getWp(reGetWp) {
-      let that = this;
-      that.API.requestData({
-        baseURL: "http://10.155.32.4:9001",
-        subUrl: "benchmarking/wplist",
-        success(res) {
-          that.wpArray = res.data;
-          that.wpId = res.data[0].id;
-          that.wpName = res.data[0].wpName;
-          that.getWt(that.wpId, reGetWp);
-          that.requestSafeList();
-        },
-      });
-    },
+	export default {
+		components: {
+			ComTable,
+			FaultDiagnosis
+		},
+		data() {
+			const that = this;
+			return {
+				value1: "",
+				value2: "",
+				wpId: "",
+				wpArray: [],
+				rowitem: "",
+				wpName: "",
+				wtId: "",
+				type: "2",
+				dialogVisible: false,
+				tableData: {
+					column: [{
+							name: "场站",
+							field: "wpName",
+							is_num: true,
+							is_light: false,
+						},
+						{
+							name: "机组",
+							field: "windTurbineId",
+							is_num: false,
+							is_light: false,
+						},
+						{
+							name: "开始时刻",
+							field: "stopTime",
+							is_num: false,
+							is_light: false,
+						},
+						{
+							name: "结束时刻",
+							field: "startTime",
+							is_num: false,
+							is_light: false,
+						},
+						{
+							name: "停机小时数(h)",
+							field: "stopHours",
+							is_num: false,
+							is_light: false,
+						},
+						{
+							name: "停机类型",
+							field: "warnDesc",
+							is_num: false,
+							is_light: false,
+						},
+						{
+							name: "损失电量(kWh)",
+							field: "lossPower",
+							is_num: false,
+							is_light: false,
+						},
+						{
+							name: "操作",
+							field: "",
+							is_num: false,
+							is_light: false,
+							template() {
+								return "<el-button type='text' style='cursor: pointer;'>回溯</el-button>";
+							},
+							click(e, row) {
+								that.onClickOption(row);
+							},
+						},
+					],
+					data: [],
+				},
+			};
+		},
+		created() {
+			this.value1 = new Date(new Date().getTime() - 3600 * 1000 * 24).formatDate(
+				"yyyy-MM-dd"
+			);
+			this.value2 = this.getTime(2);
+			this.getWp();
+		},
+		methods: {
+			getTime(val) {
+				//时间戳处理,val=1是默认开始时间(当前月第一天),val=2是默认结束时间(今天)
+				var date = new Date();
+				var year = date.getFullYear(),
+					month = date.getMonth() + 1,
+					day = date.getDate();
+				month >= 1 && month <= 9 ? (month = "0" + month) : "";
+				day >= 0 && day <= 9 ? (day = "0" + day) : "";
+				var begin = year + "-" + month + "-01";
+				var end = year + "-" + month + "-" + day;
+				if (val == 1) {
+					return begin;
+				} else if (val == 2) {
+					return end;
+				}
+			},
+			// 获取风场
+			getWp(reGetWp) {
+				let that = this;
+				that.API.requestData({
+					baseURL: "http://10.155.32.4:9001",
+					subUrl: "benchmarking/wplist",
+					success(res) {
+						that.wpArray = res.data;
+						that.wpId = res.data[0].id;
+						that.wpName = res.data[0].wpName;
+						that.getWt(that.wpId, reGetWp);
+						that.requestSafeList();
+					},
+				});
+			},
 
-    // 获取风机
-    getWt(wpid, reGetWp) {
-      let that = this;
-      if (that.wpId) {
-        that.API.requestData({
-          method: "GET",
-          baseURL: "http://10.155.32.4:9001",
-          subUrl: "benchmarking/wtList",
-          data: {
-            wpid,
-          },
-          success(res) {
-            that.wtArray = res.data;
-            // that.wtId = res.data[0].id;
-          },
-        });
-      }
-    },
-    BeginChange(vl) {
-      this.value1 = vl;
-    },
-    EndChange(vl) {
-      this.value2 = vl;
-    },
-    typeChange(vl) {
-      this.type = vl;
-    },
-    // 搜索按钮
-    onClickSearch() {
-      this.requestSafeList();
-    },
-    // 获取停机事件
-    requestSafeList() {
-      let that = this;
+			// 获取风机
+			getWt(wpid, reGetWp) {
+				let that = this;
+				if (that.wpId) {
+					that.API.requestData({
+						method: "GET",
+						baseURL: "http://10.155.32.4:9001",
+						subUrl: "benchmarking/wtList",
+						data: {
+							wpid,
+						},
+						success(res) {
+							that.wtArray = res.data;
+							// that.wtId = res.data[0].id;
+						},
+					});
+				}
+			},
+			BeginChange(vl) {
+				this.value1 = vl;
+			},
+			EndChange(vl) {
+				this.value2 = vl;
+			},
+			typeChange(vl) {
+				this.type = vl;
+			},
+			// 搜索按钮
+			onClickSearch() {
+				this.requestSafeList();
+			},
+			// 获取停机事件
+			requestSafeList() {
+				let that = this;
 
-      let data = {
-        tablepar: {
-          pageNum: 1,
-          pageSize: 1000,
-        },
-        beginDate: that.value1,
-        endDate: that.value2,
-        wpId: that.wpId,
-      };
+				let data = {
+					tablepar: {
+						pageNum: 1,
+						pageSize: 1000,
+					},
+					beginDate: that.value1,
+					endDate: that.value2,
+					wpId: that.wpId,
+				};
 
-      if (that.wtId != "") data.wtId = that.wtId;
-      if (that.type != "") data.type = that.type;
+				if (that.wtId != "") data.wtId = that.wtId;
+				if (that.type != "") data.type = that.type;
 
-      this.API.requestData({
-        method: "POST",
-        subUrl: "/event/getShutdownevent",
-        data,
-        success(res) {
-          if (res.code == 200) {
-            that.tableData.data = [];
-            if (res.data.list.length) {
-              let data = res.data.list;
-              for (var i = 0; i < data.length; i++) {
-                let obj = {
-                  wpName: data[i].wpName,
-                  windTurbineId: data[i].windTurbineId,
-                  stopTime: new Date(data[i].stopTime).formatDate(
-                    "yyyy-MM-dd hh:mm:ss"
-                  ),
+				this.API.requestData({
+					method: "POST",
+					subUrl: "/event/getShutdownevent",
+					data,
+					success(res) {
+						if (res.code == 200) {
+							that.tableData.data = [];
+							if (res.data.list.length) {
+								let data = res.data.list;
+								for (var i = 0; i < data.length; i++) {
+									let obj = {
+										wpName: data[i].wpName,
+										windTurbineId: data[i].windTurbineId,
+										stopTime: new Date(data[i].stopTime).formatDate(
+											"yyyy-MM-dd hh:mm:ss"
+										),
 
-                  stopHours: data[i].stopHours,
-                  statusName: data[i].statusName,
-                  warnDesc: data[i].warnDesc,
-                  lossPower: data[i].lossPower,
-                  handleWay: data[i].handleWay,
-                };
-                if (data[i].startTime)
-                  obj.startTime = new Date(data[i].startTime).formatDate(
-                    "yyyy-MM-dd hh:mm:ss"
-                  );
-                that.tableData.data.push(obj);
-              }
-            }
-          }
-        },
-      });
-    },
-    // 回放按钮
-    onClickOption(row) {
-      this.rowitem = row
-      this.dialogVisible = true;
-    },
-    // 关闭弹窗
-    onClickDialogClose() {
-      this.dialogVisible = false;
-    },
-  },
-};
+										stopHours: data[i].stopHours,
+										statusName: data[i].statusName,
+										warnDesc: data[i].warnDesc,
+										lossPower: data[i].lossPower,
+										handleWay: data[i].handleWay,
+									};
+									if (data[i].startTime)
+										obj.startTime = new Date(data[i].startTime).formatDate(
+											"yyyy-MM-dd hh:mm:ss"
+										);
+									that.tableData.data.push(obj);
+								}
+							}
+						}
+					},
+				});
+			},
+			// 回放按钮
+			onClickOption(row) {
+				this.rowitem = row
+				this.dialogVisible = true;
+			},
+			// 关闭弹窗
+			onClickDialogClose() {
+				this.dialogVisible = false;
+			},
+		},
+	};
 </script>
 
 <style lang="less" scope>
-@titleGray: #9ca5a8;
-@rowGray: #606769;
-@darkBack: #536268;
-.knowledge-2 {
-  .el-select {
-    width: 200px;
-  }
-  .el-input {
-    width: 200px;
-  }
-}
+	@titleGray: #9ca5a8;
+	@rowGray: #606769;
+	@darkBack: #536268;
+
+	.knowledge-2 {
+		.el-select {
+			width: 200px;
+		}
+
+		.el-input {
+			width: 200px;
+		}
+	}
 </style>