| | |
| | | </div> |
| | | </div> |
| | | <el-row :gutter="30"> |
| | | <el-col :span="12"><div class="control-table" id="ThreadsLoad">table1</div></el-col> |
| | | <el-col :span="12"><div class="control-table" id="WorkThreadsLoad">table2</div></el-col> |
| | | <el-col :span="12"> |
| | | <div class="control-table" id="ThreadsLoad">table1</div> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <div class="control-table" id="WorkThreadsLoad">table2</div> |
| | | </el-col> |
| | | </el-row> |
| | | <el-table :data="allSessionData" style="margin-top: 1rem;"> |
| | | <el-table-column prop="peer_ip" label="远端"></el-table-column> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | |
| | | import uiHeader from './UiHeader.vue' |
| | | |
| | | import echarts from 'echarts'; |
| | |
| | | url: '/zlm/index/api/getThreadsLoad' |
| | | }).then(function(res) { |
| | | if (res.data.code == 0) { |
| | | that.tableOption.xAxis.data.push(new Date().toLocaleTimeString()); |
| | | that.table1Option.xAxis.data.push(new Date().toLocaleTimeString()); |
| | | that.tableOption.xAxis.data.push(new Date().toLocaleTimeString('chinese', { |
| | | hour12: false |
| | | })); |
| | | that.table1Option.xAxis.data.push(new Date().toLocaleTimeString('chinese', { |
| | | hour12: false |
| | | })); |
| | | |
| | | for (var i = 0; i < res.data.data.length; i++) { |
| | | if (that.tableOption.series[i] === undefined) { |
| | |
| | | fontSize: 15 |
| | | } |
| | | }; |
| | | this.tableOption.dataZoom = [ |
| | | { |
| | | this.tableOption.dataZoom = [{ |
| | | show: true, |
| | | start: this.charZoomStart, |
| | | end: this.charZoomEnd |
| | | } |
| | | ]; |
| | | }]; |
| | | this.myChart = echarts.init(document.getElementById('ThreadsLoad')); |
| | | this.myChart.setOption(this.tableOption); |
| | | this.myChart.on('dataZoom', function(event) { |
| | |
| | | fontSize: 15 |
| | | } |
| | | }; |
| | | this.table1Option.dataZoom = [ |
| | | { |
| | | this.table1Option.dataZoom = [{ |
| | | show: true, |
| | | start: this.charZoomStart, |
| | | end: this.charZoomEnd |
| | | } |
| | | ]; |
| | | }]; |
| | | this.myChart1 = echarts.init(document.getElementById('WorkThreadsLoad')); |
| | | this.myChart1.setOption(this.table1Option); |
| | | this.myChart1.on('dataZoom', function(event) { |
| | |
| | | #app { |
| | | height: 100%; |
| | | } |
| | | |
| | | .control-table { |
| | | background-color: #ffffff; |
| | | height: 25rem; |
| | | } |
| | | |
| | | .table-c { |
| | | border-right: 1px solid #dcdcdc; |
| | | border-bottom: 1px solid #dcdcdc; |
| | | } |
| | | |
| | | .table-c td { |
| | | border-left: 1px solid #dcdcdc; |
| | | border-top: 1px solid #dcdcdc; |
| | | padding: 0.2rem; |
| | | } |
| | | |
| | | .el-table { |
| | | width: 99.9% !important; |
| | | } |