diff --git a/src/views/page/largeScreen.vue b/src/views/page/largeScreen.vue index fbfae0e..5c00770 100644 --- a/src/views/page/largeScreen.vue +++ b/src/views/page/largeScreen.vue @@ -700,7 +700,7 @@ export default { }, methods: { // 根据用户id查询对应的设备大数据信息 - dataInit(userid) { + dataInit(userid,limitUserId) { this.api.Bigdata_getAllControl(userid).then((res) => { // console.log('根据用户id查询对应的设备大数据信息', res); this.dataList = res.data.data; @@ -722,11 +722,22 @@ export default { // this.get_environmentData(el.deviceId) // this.get_readControl_getState(el.deviceId) }); - this.get_weather_echart_data(2023042214250027); - this.get_thisWeekTemperature_echart_data(2023042214250027); - this.get_environmentData(2023042214250027); - this.get_readControl_getState(2023042214250027); - this.getWeatherData(2023042214250027); + if(limitUserId == 1){ + // 丽水 + this.get_weather_echart_data(2023042214250027); + this.get_thisWeekTemperature_echart_data(2023042214250027); + this.get_environmentData(2023042214250027); + this.get_readControl_getState(2023042214250027); + this.getWeatherData(2023042214250027); + }else if(limitUserId == 2){ + // 东北 + this.get_weather_echart_data(2023112911050004); + this.get_thisWeekTemperature_echart_data(2023112911050004); + this.get_environmentData(2023112911050004); + this.get_readControl_getState(2023112911050004); + this.getWeatherData(2023112911050004); + } + } }); }, @@ -949,7 +960,7 @@ export default { // }) let userInfo = JSON.parse(localStorage.getItem("userInfo")); - this.dataInit(userInfo.userid); + //this.dataInit(userInfo.userid); this.get_sel_eqbyid(userInfo.userid); // 获取用户id权限 @@ -973,8 +984,10 @@ export default { this.limitUserId = res.data.data[0].id; if(this.limitUserId == 1){ this.drag_boxHandler(); + this.dataInit(userId,this.limitUserId); }else if(this.limitUserId == 2){ this.drag_boxHandler1(); + this.dataInit(userId,this.limitUserId); } } }) @@ -1500,6 +1513,7 @@ export default { width: 3.98rem; height: 3.08rem; overflow: hidden; + padding-top: 0.15rem; .title_child { width: 100%;