limiao 4 vuotta sitten
vanhempi
commit
1e27a22f19
2 muutettua tiedostoa jossa 43 lisäystä ja 7 poistoa
  1. 1 1
      common/store.js
  2. 42 6
      pages/index/Index.vue

+ 1 - 1
common/store.js

@@ -5,7 +5,7 @@ Vue.use(Vuex)
 
 const store = new Vuex.Store({
     state: {
-		wholeSituationBackStageIp:'192.168.1.104',
+		wholeSituationBackStageIp:'10.155.32.125',
 		wholeSituationBackStagePort:'8082',
 		windpowerstationNameToId:{
            "宁夏新能源公司":"0","麻黄山风电场":"MHS_FDC","牛首山风电场":"NSS_FDC","青山风电场":"SBQ_FDC","石板泉风电场":"QS_FDC","香山风电场":"QS_FDC"

+ 42 - 6
pages/index/Index.vue

@@ -176,7 +176,7 @@
 					</view>
 					<view class="progressBarText">月计划发电量进度条</view>
 					<view class="progressBarRight">
-						<view class="progressBarRightText">1000kwh</view>
+						<view class="progressBarRightText">10000kwh</view>
 					</view>
 				</view>
 				<view class="cu-progress round radius striped active">
@@ -191,7 +191,7 @@
 					</view>
 					<view class="progressBarText">年计划发电量进度条</view>
 					<view class="progressBarRight">
-						<view class="progressBarRightText">10000kwh</view>
+						<view class="progressBarRightText">100000kwh</view>
 					</view>
 				</view>
 				<view class="cu-progress round radius striped active">
@@ -750,6 +750,24 @@
 				this.pushWindPowerStationNameToSessionStorage("宁夏新能源公司");
 				this.address = this.getWindPowerStationNameToSessionStorage();
 			}
+			if(this.address=="宁夏新能源公司"){
+							this.FDC="0";
+						}
+						if(this.address=="麻黄山风电场"){
+							this.FDC="MHS_FDC";
+						}
+						if(this.address=="牛首山风电场"){
+							this.FDC="NSS_FDC";
+						}
+						if(this.address=="石板泉风电场"){
+							this.FDC="SBQ_FDC";
+						}
+						if(this.address=="青山风电场"){
+							this.FDC="QS_FDC";
+						}
+						if(this.address=="香山风电场"){
+							this.FDC="XS_FDC";
+						}
 			this.windPowerStationId = uni.getStorageSync('windPowerStationId');
 		},
 		onLoad: function() {
@@ -787,6 +805,24 @@
 		onShow(){
 			this.windPowerStationId = uni.getStorageSync('windPowerStationId');
 			this.address = this.getWindPowerStationNameToSessionStorage();
+			if(this.address=="宁夏新能源公司"){
+				this.FDC="0";
+			}
+			if(this.address=="麻黄山风电场"){
+				this.FDC="MHS_FDC";
+			}
+			if(this.address=="牛首山风电场"){
+				this.FDC="NSS_FDC";
+			}
+			if(this.address=="石板泉风电场"){
+				this.FDC="SBQ_FDC";
+			}
+			if(this.address=="青山风电场"){
+				this.FDC="QS_FDC";
+			}
+			if(this.address=="香山风电场"){
+				this.FDC="XS_FDC";
+			}
 		},
 		methods: {
 			openDrawer: function() {
@@ -936,10 +972,10 @@
 							this.socketTask_index_electricQuantity.onMessage(res => {
 								//console.log("收到服务器内容:" + res.data);
 								_this.windpowerstationdetail.index_electricQuantity =JSON.parse(res.data)[_this.FDC];
-								_this.monthOlive=(_this.windpowerstationdetail.index_electricQuantity.yfdl/1000)*100+"%";
-								_this.monthAngrey=(1-_this.windpowerstationdetail.index_electricQuantity.yfdl/1000)*100+"%";
-								_this.yearOlive=(_this.windpowerstationdetail.index_electricQuantity.nfdl/10000)*100+"%";
-								_this.yearAngrey=(1-_this.windpowerstationdetail.index_electricQuantity.nfdl/10000)*100+"%";
+								_this.monthOlive=(_this.windpowerstationdetail.index_electricQuantity.yfdl/10000)*100+"%";
+								_this.monthAngrey=(1-_this.windpowerstationdetail.index_electricQuantity.yfdl/10000)*100+"%";
+								_this.yearOlive=(_this.windpowerstationdetail.index_electricQuantity.nfdl/100000)*100+"%";
+								_this.yearAngrey=(1-_this.windpowerstationdetail.index_electricQuantity.nfdl/100000)*100+"%";
 			
 							});
 						});