Commit f27bfd29 by liuwange1

确保参数可以

parent 14742b2d
...@@ -165,12 +165,13 @@ export default { ...@@ -165,12 +165,13 @@ export default {
alarmActiveIndex: -1, alarmActiveIndex: -1,
pageNum: 1, pageNum: 1,
isScrolling: false, isScrolling: false,
menuCode: "",
}; };
}, },
created() { created() {
// this.getBuildListData(); // this.getBuildListData();
this.initSocket(); this.initSocket();
this.getAlarmList(""); this.getAlarmList();
this.getAlarmMsgByMenu(); this.getAlarmMsgByMenu();
this.activeIndexHandler(); this.activeIndexHandler();
}, },
...@@ -231,7 +232,8 @@ export default { ...@@ -231,7 +232,8 @@ export default {
if (routerName && routerName != this.$route.name) { if (routerName && routerName != this.$route.name) {
this.$router.push({ name: routerName }); this.$router.push({ name: routerName });
this.pageNum = 1; this.pageNum = 1;
this.getAlarmList(this.navList[index].menuCode); this.menuCode = this.navList[index].menuCode;
this.getAlarmList();
} }
}, },
// touchStart(e) { // touchStart(e) {
...@@ -384,7 +386,7 @@ export default { ...@@ -384,7 +386,7 @@ export default {
}; };
}, },
// 获取报警信息列表接口 // 获取报警信息列表接口
getAlarmList(menuCode) { getAlarmList() {
let date = let date =
new Date().getFullYear() + new Date().getFullYear() +
"-" + "-" +
...@@ -396,7 +398,7 @@ export default { ...@@ -396,7 +398,7 @@ export default {
date: date, date: date,
pageNum: this.pageNum, pageNum: this.pageNum,
pageSize: 10, pageSize: 10,
menuCode: menuCode, menuCode: this.menuCode,
}) })
.then((e) => { .then((e) => {
e.data.list.forEach((item) => { e.data.list.forEach((item) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment