3
0

2 کامیت‌ها 5907af299e ... b2cd5489a2

نویسنده SHA1 پیام تاریخ
  wangjiawen b2cd5489a2 Merge branch 'master' of http://49.4.49.126:3000/Gyee_web/sisMobilePhone 4 سال پیش
  wangjiawen 432d7e56aa 气象8-15天,气象40天轨道定向 4 سال پیش

+ 1 - 1
components/drawer/threeLineDrawer.vue

@@ -10,7 +10,7 @@
 					</view>
 					
 					<view v-for="(item,index) in drawerList" :class="[changeGary==index?'statusMonitoring':'item']" :key="index" @click="clickChangeColor(index)">
-						<div @click="goToIndex(item)">
+						<div @click="goToIndex(item);closeDrawer();">
 							{{item.name}}
 							</div>
 					

+ 62 - 154
components/monitor/MatrixMonitor.vue

@@ -177,18 +177,10 @@
 		data: function() {
 			return {
 				address: '',
+				userid:'',
+				permissionsInformation:[],
 				badge: 22,
-				drawerList: [{
-					name: '首页'
-				}, {
-					name: '状态监视'
-				}, {
-					name: '矩阵监视'
-				}, {
-					name: '风场监视'
-				}, {
-					name: '人员监视'
-				}],
+				drawerList: [],
 				plusDrawerList: [],
 				windStationName: '',
 				modalWindStationName: '',
@@ -1192,53 +1184,19 @@
 		// 	this.windStationListHeight=(this.windStation.length*50+40)+"px"
 		// },
 		onShow() {
-			this.windPowerStationId = uni.getStorageSync('windPowerStationId');
-			this.address = this.getWindPowerStationNameToSessionStorage();
-			if (this.address == '宁夏新能源公司') {
-				this.FDC = 'MHS_FDC';
-			}
-			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';
-			}
-			if (this.address == '河北能源集团') {
-				this.FDC = 'CL_FDC';
-			}
-			if (this.address == '崇礼风电场') {
-				this.FDC = 'CL_FDC';
-			}
-			if (this.address == '康保风电场') {
-				this.FDC = 'KB_FDC';
-			}
-			if (this.address == '代县风电场') {
-				this.FDC = 'DX_FDC';
-			}
+			this.address = this.dataprocessing.getWindPowerStationName();
+			this.FDC = this.dataprocessing.getWindPowerStationId();
+			this.windPowerStationId = this.dataprocessing.getWindPowerStationId();
+
 		},
 		created: function() {
 			this.viewUserid();
-			this.address = this.getWindPowerStationNameToSessionStorage();
+			this.monitoringAuthority();
 
-			this.windPowerStationId = uni.getStorageSync('windPowerStationId');
-			this.FDC = uni.getStorageSync('windPowerStationId');
+			this.address = this.dataprocessing.getWindPowerStationName();
+			this.FDC = this.dataprocessing.getWindPowerStationId();
+			this.windPowerStationId = this.dataprocessing.getWindPowerStationId();
 
-			if (this.address == '宁夏新能源公司') {
-				this.FDC = 'MHS_FDC';
-			}
-			if (this.address == '河北能源集团') {
-				this.FDC = 'CL_FDC';
-			}
-			uni.setStorageSync('windPowerStationId', this.FDC);
 			this.$nextTick(function() {
 				//this.getWeatherDataToday();
 				//this.getWeatherData7();
@@ -1248,66 +1206,9 @@
 			this.cWidth40 = uni.upx2px(5000);
 			this.cHeight40 = uni.upx2px(350);
 
-			if (this.address == '宁夏新能源公司') {
-				this.windStation = ['麻黄山风电场', '牛首山风电场', '石板泉风电场', '青山风电场', '香山风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'MHS_FDC';
-				// this.getWeatherDataToday();
-			}
-			if (this.address == '麻黄山风电场') {
-				this.windStation = ['麻黄山风电场', '牛首山风电场', '石板泉风电场', '青山风电场', '香山风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'MHS_FDC';
-				// this.getWeatherDataToday();
-			}
-			if (this.address == '牛首山风电场') {
-				this.windStation = ['牛首山风电场', '麻黄山风电场', '石板泉风电场', '青山风电场', '香山风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'NSS_FDC';
-				// this.getWeatherDataToday();
-			}
-			if (this.address == '石板泉风电场') {
-				this.windStation = ['石板泉风电场', '麻黄山风电场', '牛首山风电场', '青山风电场', '香山风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'SBQ_FDC';
-				// this.getWeatherDataToday();
-			}
-			if (this.address == '香山风电场') {
-				this.windStation = ['香山风电场', '麻黄山风电场', '牛首山风电场', '石板泉风电场', '青山风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'XS_FDC';
-				// this.getWeatherDataToday();
-			}
-			if (this.address == '青山风电场') {
-				this.windStation = ['青山风电场', '麻黄山风电场', '牛首山风电场', '石板泉风电场', '香山风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'QS_FDC';
-				// this.getWeatherDataToday();
-			}
-			if (this.address == '河北能源集团') {
-				this.windStation = ['崇礼风电场', '康保风电场', '代县风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'QS_FDC';
-				// this.getWeatherDataToday();
-			}
-			if (this.address == '崇礼风电场') {
-				this.windStation = ['崇礼风电场', '康保风电场', '代县风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'QS_FDC';
-				// this.getWeatherDataToday();
-			}
-			if (this.address == '康保风电场') {
-				this.windStation = ['康保风电场', '崇礼风电场', '代县风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'QS_FDC';
-				// this.getWeatherDataToday();
-			}
-			if (this.address == '代县风电场') {
-				this.windStation = ['代县风电场', '康保风电场', '崇礼风电场'];
-				this.windStationName = this.windStation[0].replace('风电场', '');
-				// this.windPowerStationId = 'QS_FDC';
-				// this.getWeatherDataToday();
-			}
+			this.windStation = this.dataprocessing.getWindPowerStationNameByNames(this.address);
+			this.windStationName = this.windStation[0].replace('风电场', '');
+
 			this.windStationListHeight = this.windStation.length * 50 + 40 + 'px';
 			this.spopupWrapperHeight = this.windStation.length * 50 + 90 + 'px';
 			this.windowWidth = uni.getSystemInfoSync().windowWidth;
@@ -1356,6 +1257,37 @@
 					},
 				})
 			},
+			monitoringAuthority: function() {
+				let _this = this;
+				_this.userid = uni.getStorageSync('userid')
+				uni.request({
+					url: 'http://' + this.backStageIp + ':' + this.backStagePort +
+						'/GyeepermissionController/GyeePermissionList?userid=' + _this.userid,
+					data: {},
+					method: 'GET',
+					success: function(res) {
+						console.log(res);
+						for (let i = 0; i < res.data.data.length; i++) {
+							if (res.data.data[i].describes == "监视") {
+								var b = {};
+								_this.$set(b, "gyeePermissionList", res.data.data[i].gyeePermissionList);
+								_this.permissionsInformation.push(b);
+								console.log(_this.permissionsInformation);
+								for (let k = 0; k < _this.permissionsInformation[0].gyeePermissionList.length; k++) {
+									if (_this.permissionsInformation[0].gyeePermissionList[k].parent == 1) {
+										var c = {};
+										var d = {};
+										_this.$set(c, "name", _this.permissionsInformation[0].gyeePermissionList[k].permisssionname);
+										_this.$set(c, "remark1", _this.permissionsInformation[0].gyeePermissionList[k].remark1);
+										_this.drawerList.push(c);
+									}
+								}
+								console.log(_this.drawerList)
+							}
+						}
+					}
+				})
+			},
 			pushWindPowerStationNameToSessionStorage(windpowerstationName) {
 				uni.setStorageSync('windpowerstationName', windpowerstationName);
 				//sessionStorage.setItem('windpowerstationName', windpowerstationName);
@@ -1391,45 +1323,21 @@
 				this.modalName = null;
 			},
 			choiceWindStation: function(item, index) {
-	this.choiceIndex = index;
-	this.windStationName = item.replace('风电场', '');
-	this.modalWindStationName = item.replace('风电场', '');
-	this.address = item;
-	this.pushWindPowerStationNameToSessionStorage(item);
-	let _this = this;
-	setTimeout(function() {
-		// _this.hideModal();
-		_this.showCenterVisible = false;
-		_this.choiceIndex = -1;
-		_this.cardCur = index;
-	}, 1000);
-	if (this.windStationName == '麻黄山') {
-	
-		this.FDC = 'MHS_FDC';
-		
-	}
-	if (this.windStationName == '牛首山') {
-		this.FDC = 'NSS_FDC';
-	}
-	if (this.windStationName == '石板泉') {
-		this.FDC = 'SBQ_FDC';
-	}
-	if (this.windStationName == '青山') {
-		this.FDC = 'QS_FDC';
-	}
-	if (this.windStationName == '香山') {
-		this.FDC = 'XS_FDC';
-	}
-	if (this.windStationName == '崇礼') {
-		this.FDC = 'CL_FDC';
-	}
-	if (this.windStationName == '康保') {
-		this.FDC = 'KB_FDC';
-	}
-	if (this.windStationName == '代县') {
-		this.FDC = 'YMG_FDC';
-	}
+				this.choiceIndex = index;
+				this.windStationName = item.replace('风电场', '');
+				this.modalWindStationName = item.replace('风电场', '');
+				this.address = item;
+				this.pushWindPowerStationNameToSessionStorage(item);
+				let _this = this;
+				setTimeout(function() {
+					// _this.hideModal();
+					_this.showCenterVisible = false;
+					_this.choiceIndex = -1;
+					_this.cardCur = index;
+				}, 1000);
+				this.FDC =this.dataprocessing.getWindPowerStationNameById(item);
 				
+				this.dataprocessing.putWindPowerStationId(this.FDC);
 			},
 			getWindMotorStatusCard: function() {
 				this.jieRu = 0;
@@ -1561,10 +1469,10 @@
 				this.cardCur = e.detail.current;
 				for (let i = 0; i < this.windStation.length; i++) {
 					if (this.cardCur == i) {
-						
+
 						if (this.windStation[i].search('风电场') != -1) {
-							
-							this.address=this.windStation[i];
+
+							this.address = this.windStation[i];
 							this.windStationName = this.windStation[i].replace('风电场', '');
 						} else {
 							this.windStationName = this.windStation[i];

+ 67 - 24
components/weatherProphethomepage/WeatherProphethomepage.vue

@@ -407,19 +407,23 @@
 							</view>
 						</view>
 
-						<scroll-view scroll-x scroll-with-animation :scroll-left=scrollposition class="scrollUcharts" @scroll="uChartsScrollEvent"
+						<scroll-view scroll-x scroll-with-animation :scroll-left=scrollposition class="scrollUcharts" @touchstart="topblock" @scroll="uChartsScrollEvent"
 						 :scroll-into-view="'uCharts-'+mainCur">
-							<view class="qiun-charts">
+							<view class="qiun-charts" >
 								<canvas canvas-id="canvasLineA" id="canvasLineA" class="charts"></canvas>
 							</view>
 						</scroll-view>
+
 					</view>
 				</view>
 				<div>
-					<scroll-view scroll-y scroll-with-animation :scroll-top=scrollposition class="scrollList" :style="{'height': scrollHeight }"
-					 @scroll="listScrollEvent">
+
+					<scroll-view scroll-y scroll-with-animation :scroll-top=scrollpositiontmp class="scrollList" :style="{'height': scrollHeight }"  @touchstart="bottomblock"
+					 @scroll="listScrollEvent">					
 						<weatherCalendarCardList8_15 ref="weatherCalendarCardList8_15"></weatherCalendarCardList8_15>
+					
 					</scroll-view>
+
 				</div>
 			</view>
 			<!-- 40天气象卡片 -->
@@ -439,18 +443,22 @@
 								 @click="realFeelSwitch40()">体感温度</div>
 							</view>
 						</view>
-						<scroll-view scroll-x scroll-with-animation :scroll-left=scrollposition_uCharts class="scrollUcharts40" @scroll="uChartsScrollEvent40"
-						 :scroll-into-view="'uCharts-'+mainCur40">
-							<view class="qiun-charts40">
-								<canvas canvas-id="canvasLineA40" id="canvasLineA40" class="charts40"></canvas>
-							</view>
-						</scroll-view>
+						<view @tap="topblock_40">
+							<scroll-view scroll-x scroll-with-animation :scroll-left=scrollposition_uCharts class="scrollUcharts40" @touchstart="topblock_40" @scroll="uChartsScrollEvent40"
+							 :scroll-into-view="'uCharts-'+mainCur40">
+								<view class="qiun-charts40">
+									<canvas canvas-id="canvasLineA40" id="canvasLineA40" class="charts40"></canvas>
+								</view>
+							</scroll-view>
+						</view>
 					</view>
 				</view>
-				<scroll-view scroll-y scroll-with-animation :scroll-top=scrollposition_list class="scrollList40" :style="{'height': scrollListHeight40 }"
-				 @scroll="listScrollEvent40">
-					<weatherCalendarCardList40 ref="weatherCalendarCardList40"></weatherCalendarCardList40>
-				</scroll-view>
+				<view @tap="topbottom_40">
+					<scroll-view scroll-y scroll-with-animation :scroll-top=scrollposition_list class="scrollList40" :style="{'height': scrollListHeight40 }"
+					 @scroll="listScrollEvent40" @touchstart="bottomblock_40" >
+						<weatherCalendarCardList40 ref="weatherCalendarCardList40"></weatherCalendarCardList40>
+					</scroll-view>
+				</view>
 			</view>
 		</scroll-view>
 		<view class="DrawerClose" :class="modalName == 'viewModal' ? 'show' : ''" @tap="hideModal"><text class="cuIcon-pullright"></text></view>
@@ -665,6 +673,7 @@
 				cardHeight: "",
 				isToday: false,
 				scrollposition: 0,
+				scrollpositiontmp: 0,
 				weatherProphetDataAll_8_15: [],
 				weatherProphetData_8_15: [],
 				socket: "",
@@ -803,7 +812,8 @@
 				nightmarginleft7: '',
 				socketTask7: '',
 				userCanviewthewindfarm:[],
-				permissionsInformation:[]
+				permissionsInformation:[],
+				timer:null
 			}
 		},
 		created: function() {
@@ -961,7 +971,16 @@
 						for(let j=0;j<res.data.data.length;j++){
 							var a = {};
 							_this.$set(a,"name",res.data.data[j].describes);
-							_this.$set(a,"windId",res.data.data[j].name);
+							
+							if (res.data.data[j].describes == '宁夏新能源公司') {
+								_this.$set(a,"windId",'MHS_FDC');
+							}else if(res.data.data[j].describes == '河北能源集团')
+							{
+								_this.$set(a,"windId",'CL_FDC');
+							}else{
+								_this.$set(a,"windId",res.data.data[j].name);
+							}
+							
 							_this.plusDrawerList.push(a);
 						}
 					},
@@ -1032,7 +1051,7 @@
 					_this.cardCur = index;
 				}, 1000);
 				
-				this.FDC =this.dataprocessing.getWindPowerStationNameById(item);
+				this.FDC =this.dataprocessing.getWindPowerStationNameByWeatherId(item);
 
 				this.dataprocessing.putWindPowerStationId(this.FDC);
 				//uni.setStorageSync('windPowerStationId',this.FDC);
@@ -1618,15 +1637,35 @@
 					}
 				});
 			},
+			topblock(){
+				this.block = "top";
+			},
+			bottomblock(){
+				this.block = "bottom";
+			},
+			topblock_40(){
+				this.block_40 = "top";
+			},
+			bottomblock_40(){
+				this.block_40 = "bottom";
+			},
 			uChartsScrollEvent(e) {
-				this.scrollposition = e.detail.scrollLeft;
+				//this.topblock();
+               if(this.block=="top"){
+				   this.scrollpositiontmp = e.detail.scrollLeft;
+			   }
+			   
 				// let scrollposition2 = scrollposition*0.98;
 			},
 			listScrollEvent(e) {
-				this.scrollposition = e.detail.scrollTop;
+				//this.bottomblock();
+				if(this.block=="bottom"){
+				   this.scrollposition = e.detail.scrollTop;
+				}
 			},
 			uChartsScrollEvent40(e) {
-				this.scrollposition_uCharts = e.detail.scrollLeft;
+				if(this.block_40=="top"){
+				// this.scrollposition_uCharts = e.detail.scrollLeft;
 				if (e.detail.scrollLeft < 237) {
 					this.scrollposition_list = 0;
 				} else if (e.detail.scrollLeft < 487 && e.detail.scrollLeft > 237) {
@@ -1644,9 +1683,11 @@
 				} else if (e.detail.scrollLeft > 1737) {
 					this.scrollposition_list = 656;
 				}
+				}
 			},
 			listScrollEvent40(e) {
-				this.scrollposition_list = e.detail.scrollTop;
+				if(this.block_40=="bottom"){
+				// this.scrollposition_list = e.detail.scrollTop;
 				if (e.detail.scrollTop < 104) {
 					this.scrollposition_uCharts = 0;
 				} else if (e.detail.scrollTop < 208 && e.detail.scrollTop > 104) {
@@ -1662,6 +1703,7 @@
 				} else if (e.detail.scrollTop < 656 && e.detail.scrollTop > 624) {
 					this.scrollposition_uCharts = 1487;
 				}
+				}
 			},
 			changeTap: function(item) {
 				this.weatherInformation = JSON.parse(item); //vue json转object
@@ -2068,7 +2110,8 @@
 	}
 
 	.scrollList {
-		height: 380px;
+		height: 750upx;
+		margin-top: 40upx ;
 	}
 
 	.cardContenter40 {
@@ -2331,12 +2374,12 @@
 		border-right-color: #19B5BC;
 	}
 
-	.scrollList {
+/* 	.scrollList {
 		// height:20%;
 		height: 130px;
 		width: 95%;
 		margin: 0px auto;
-	}
+	} */
 
 	.dayButtonWhite {
 		height: 25px;

+ 5 - 2
components/weatherProphethomepage/weatherDetail/Detail.vue

@@ -211,8 +211,11 @@
 		created: function() {
 			//this.pushWindPowerStationNameToSessionStorage("麻黄山");
 
-			this.address = this.getWindPowerStationNameToSessionStorage();
-			this.windPowerStationId=uni.getStorageSync('windPowerStationId');
+			this.address = this.dataprocessing.getWindPowerStationName();
+			this.FDC=this.dataprocessing.getWindPowerStationId();
+			this.windPowerStationId =this.dataprocessing.getWindPowerStationId();
+			
+			
 			this.getWeatherData();
 			this.windowWidth=uni.getSystemInfoSync().windowWidth;
 			this.windowHeight=uni.getSystemInfoSync().windowHeight;

+ 3 - 2
pages/forecast/Forecast.vue

@@ -299,8 +299,9 @@ export default {
 	},
 	mounted() {
 		//document.querySelector('body').setAttribute('style', 'background-color:#000000');
-	},
-	created: function() {
+	},onShow(){
+		this.leftbar();
+	},created: function() {
 		// this.pushWindPowerStationNameToSessionStorage("麻黄山");
 		this.viewUserid();
 		this.monitoringAuthority();