diff --git a/src/views/modules/monitoring/audit-log.vue b/src/views/modules/monitoring/audit-log.vue index 6128853..50dc2cf 100644 --- a/src/views/modules/monitoring/audit-log.vue +++ b/src/views/modules/monitoring/audit-log.vue @@ -11,14 +11,31 @@ 查询 - - + + - + + + 查看 + - - - + + + @@ -26,37 +43,37 @@ export default { data() { return { + logs: [ // 这里可以根据需要从后台获取真实数据 + { id: 1, message: "日志1", timestamp: "2024-01-05 10:30:00" }, + { id: 2, message: "日志2", timestamp: "2024-01-05 11:15:00" }, + { id: 3, message: "日志3", timestamp: "2024-01-06 11:15:00" }, + { id: 4, message: "日志4", timestamp: "2024-01-07 11:15:00" }, + { id: 5, message: "日志5", timestamp: "2024-01-08 11:15:00" }, + { id: 6, message: "日志6", timestamp: "2024-01-09 11:15:00" }, + ], + currentPage:1, // 初始页 + pagesize:3, // 初始每页的数据 accounts: [ { id: 1, name: "子账号1" }, { id: 2, name: "子账号2" }, // 添加更多子账号 ], selectedAccount: null, - logs: [ // 这里可以根据需要从后台获取真实数据 - { id: 1, message: "日志1", timestamp: "2024-01-05 10:30:00" }, - { id: 2, message: "日志2", timestamp: "2024-01-05 11:15:00" }, - ], - chartOptions: { - title: { - text: '柱状图示例' - }, - tooltip: {}, - xAxis: { - data: ['类别1', '类别2', '类别3', '类别4', '类别5'] - }, - yAxis: {}, - series: [{ - name: '数量', - type: 'bar', - data: [5, 20, 36, 10, 10] - }] - } + }; }, mounted() { this.renderChart() }, methods: { + // handleSizeChange: function (size) { + // this.pagesize = size; + // console.log(this.pagesize) //每页下拉显示数据 + // }, + // handleCurrentChange: function(currentPage){ + // this.currentPage = currentPage; + // console.log(this.currentPage) //点击第几页 + // }, fetchLogs() { // 模拟从后端获取日志数据的过程 // 这里可以使用axios或其他HTTP库发送请求 @@ -72,6 +89,7 @@ // // 更多日志数据 // ] // }; + // 模拟异步请求 setTimeout(() => { @@ -79,10 +97,14 @@ this.logs = response.data; }, 1000); }, + renderChart() { const myChart = echarts.init(this.$refs.myChart) myChart.setOption(this.chartOptions) - } + } , + readlogs(){ + + } } }; diff --git a/src/views/modules/monitoring/chart-test.vue b/src/views/modules/monitoring/chart-test.vue index 4e1c60a..256b14d 100644 --- a/src/views/modules/monitoring/chart-test.vue +++ b/src/views/modules/monitoring/chart-test.vue @@ -1,38 +1,143 @@ - + + diff --git a/src/views/modules/monitoring/chart-test2.vue b/src/views/modules/monitoring/chart-test2.vue index 5fcf09d..db08d0c 100644 --- a/src/views/modules/monitoring/chart-test2.vue +++ b/src/views/modules/monitoring/chart-test2.vue @@ -4,25 +4,25 @@
运行设备数量
-
{{total}}
+
{{total}}
设备总量
-
1000
+
1000
覆盖地区
-
320
+
320
上报数量
-
100
+
100
@@ -30,7 +30,7 @@
覆盖地区
-
+
@@ -44,27 +44,99 @@ -
流量上报
+
流量上报
+ + + +
设备运行
+
+
+
+ + +
设备信息
+ + + + + + + + +
+
+ +
+ + + + + + \ No newline at end of file