diff --git a/ruoyi-ui/src/views/alarmMonitor/bound/index.vue b/ruoyi-ui/src/views/alarmMonitor/bound/index.vue
index 41b2155..72600f8 100644
--- a/ruoyi-ui/src/views/alarmMonitor/bound/index.vue
+++ b/ruoyi-ui/src/views/alarmMonitor/bound/index.vue
@@ -164,6 +164,16 @@ export default {
name: "alarm",
components: { sendMsg, dealAlarm, DeptTree, BmlHeatmap },
dicts: [],
+ props: {
+ queryParamsName: {
+ type: String,
+ default: "",
+ },
+ queryParamsDate: {
+ type: Array,
+ default: () => [],
+ },
+ },
data() {
return {
detailParams: {},
@@ -210,6 +220,21 @@ export default {
created() {
// this.userName = store.getters.user.userName;
},
+ watch: {
+ queryParamsName: {
+ handler: function (val) {
+ this.queryParams.name = val;
+ this.getList();
+ },
+ immediate: true,
+ },
+ queryParamsDate: {
+ handler: function (val) {
+ this.dateList = val;
+ },
+ immediate: true,
+ },
+ },
mounted() {
this.init();
},
@@ -243,6 +268,13 @@ export default {
this.queryParams.endTime = null;
}
this.loading = true;
+ if (this.queryParamsName) {
+ this.queryParams.name = this.queryParamsName;
+ }
+ if (this.queryParamsDate && this.queryParamsDate.length > 0) {
+ this.queryParams.startTime = this.queryParamsDate[0];
+ this.queryParams.endTime = this.queryParamsDate[1];
+ }
listAlarm(this.queryParams).then((response) => {
this.dataList = response.rows;
this.total = response.total;
@@ -275,9 +307,14 @@ export default {
this.queryParams.dealUser = null;
this.queryParams.startTime = null;
this.queryParams.endTime = null;
+ this.queryParamsName = null;
+ this.queryParamsDate = [];
+ this.getList();
},
handleQuery() {
this.queryParams.pageNum = 1;
+ this.queryParamsName = null;
+ this.queryParamsDate = [];
this.getList();
},
diff --git a/ruoyi-ui/src/views/dataAnalysis/bound/index.vue b/ruoyi-ui/src/views/dataAnalysis/bound/index.vue
index 07bfeff..409d3b1 100644
--- a/ruoyi-ui/src/views/dataAnalysis/bound/index.vue
+++ b/ruoyi-ui/src/views/dataAnalysis/bound/index.vue
@@ -41,7 +41,7 @@
- {{ scope.row.count }}
+ {{ scope.row.count }}
-
+
@@ -137,6 +137,8 @@ export default {
deviceSn: null,
},
dialogAlarmVisible: false,
+ queryParamsName: null,
+ queryParamsDate: null,
};
},
mounted() {
@@ -162,8 +164,14 @@ export default {
},
methods: {
checkRole,
- clickAlarmTag() {
+ clickAlarmTag(row) {
this.dialogAlarmVisible = true;
+ this.queryParamsName = row.name;
+ // 日期加上00:00:00
+ this.queryParamsDate = [
+ moment(this.dateList[0]).format("YYYY-MM-DD 00:00:00"),
+ moment(this.dateList[1]).format("YYYY-MM-DD 23:59:59"),
+ ];
},
dateChange() {
this.queryDebounce();