|
|
@@ -13,7 +13,7 @@
|
|
|
</el-col>
|
|
|
<el-col :span="8">
|
|
|
<div class="cell cell-row1">
|
|
|
- <div class="cell-title">账户余额</div>
|
|
|
+ <div class="cell-title">本月充值</div>
|
|
|
<div class="cell-time">截止时间为2022/06/22 17:20:20</div>
|
|
|
<div class="cell-bottom">
|
|
|
<div class="cell-bottom-amount">5869.00</div>
|
|
|
@@ -23,7 +23,7 @@
|
|
|
</el-col>
|
|
|
<el-col :span="8">
|
|
|
<div class="cell cell-row1">
|
|
|
- <div class="cell-title">账户余额</div>
|
|
|
+ <div class="cell-title">本月消费</div>
|
|
|
<div class="cell-time">截止时间为2022/06/22 17:20:20</div>
|
|
|
<div class="cell-bottom">
|
|
|
<div class="cell-bottom-amount">5869.00</div>
|
|
|
@@ -35,12 +35,17 @@
|
|
|
<el-row>
|
|
|
<el-col :span="8">
|
|
|
<div class="cell">
|
|
|
- <el-card class="box-card">
|
|
|
+ <el-card class="box-card" style="position: relative;">
|
|
|
<div slot="header" class="clearfix">
|
|
|
<img src="../../icons/images/index/zoushi.png" alt="">
|
|
|
<span>用电消费走势图</span>
|
|
|
</div>
|
|
|
- <div id="main-line" class="line-echart"></div>
|
|
|
+ <el-select v-model="value" placeholder="请选择" class="select-year">
|
|
|
+ <el-option v-for="item in options" :key="item.value" :label="item.label"
|
|
|
+ :value="item.value">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ <div id="main-echart" class="line-echart"></div>
|
|
|
</el-card>
|
|
|
</div>
|
|
|
</el-col>
|
|
|
@@ -51,9 +56,19 @@
|
|
|
<img src="../../icons/images/index/yujing.png" alt="">
|
|
|
<span>超时预警</span>
|
|
|
</div>
|
|
|
- <div v-for="o in 4" :key="o" class="text item">
|
|
|
- {{'列表内容 ' + o }}
|
|
|
- </div>
|
|
|
+ <el-table :data="yujing_tableData" height="350" stripe :cell-style="cell_style"
|
|
|
+ :header-cell-style="header_cell_style" style="width: 100%">
|
|
|
+ <el-table-column prop="deviceId" label="设备号" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="warningTime" label="告警时间" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="serviceTime" label="使用时长" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="contact" label="联系方式" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="operator" label="操作人" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
</el-card>
|
|
|
</div>
|
|
|
</el-col>
|
|
|
@@ -66,9 +81,13 @@
|
|
|
<img src="../../icons/images/index/yewu.png" alt="">
|
|
|
<span>实时业务信息</span>
|
|
|
</div>
|
|
|
- <div v-for="o in 4" :key="o" class="text item">
|
|
|
- {{'列表内容 ' + o }}
|
|
|
- </div>
|
|
|
+ <el-table :data="yewu_tableData" height="350" stripe :cell-style="handle_cell_style"
|
|
|
+ :header-cell-style="header_cell_style" style="width: 100%" :show-header="false">
|
|
|
+ <el-table-column prop="desc" label="说明" align="left">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="dataTime" label="时间" align="right">
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
</el-card>
|
|
|
</div>
|
|
|
</el-col>
|
|
|
@@ -86,9 +105,21 @@
|
|
|
<div class="card-desc">A/B=已开机/总设备</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div v-for="o in 4" :key="o" class="text item">
|
|
|
- {{'列表内容 ' + o }}
|
|
|
- </div>
|
|
|
+ <el-table :data="zhuangtai_tableData" height="350" stripe :cell-style="cell_style"
|
|
|
+ :header-cell-style="header_cell_style" style="width: 100%">
|
|
|
+ <el-table-column prop="floor" label="楼层" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="scienceBuilding" label="科技楼" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="teachBuilding" label="教学楼" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="adminBuilding" label="行政楼" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="stuCenter" label="大学生活动中心" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="library" label="图书馆" align="center">
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
</el-card>
|
|
|
</div>
|
|
|
</el-col>
|
|
|
@@ -111,50 +142,188 @@
|
|
|
} from 'echarts/charts';
|
|
|
|
|
|
import {
|
|
|
- UniversalTransition
|
|
|
- } from 'echarts/features';
|
|
|
-
|
|
|
- import {
|
|
|
CanvasRenderer
|
|
|
} from 'echarts/renderers';
|
|
|
|
|
|
echarts.use([
|
|
|
- TitleComponent,
|
|
|
- ToolboxComponent,
|
|
|
- TooltipComponent,
|
|
|
- GridComponent,
|
|
|
- LegendComponent,
|
|
|
- LineChart,
|
|
|
- CanvasRenderer,
|
|
|
- UniversalTransition
|
|
|
+ TitleComponent, ToolboxComponent, TooltipComponent, GridComponent, LegendComponent, LineChart,
|
|
|
+ CanvasRenderer
|
|
|
]);
|
|
|
|
|
|
export default {
|
|
|
- mounted() {
|
|
|
- this.initCharts();
|
|
|
- },
|
|
|
- methods: {
|
|
|
- initCharts() {
|
|
|
- // 基于准备好的dom,初始化echarts实例
|
|
|
- var myChart = echarts.init(document.getElementById('main-line'));
|
|
|
- // 绘制图表
|
|
|
- this.setOption(myChart)
|
|
|
- },
|
|
|
- setOption(myChart) {
|
|
|
- myChart.setOption({
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ // 表格单元格样式
|
|
|
+ cell_style: {
|
|
|
+ color: '#1A202B',
|
|
|
+ 'font-size': '16px',
|
|
|
+ 'font-family': 'Microsoft YaHei-3970(82674968)'
|
|
|
+ },
|
|
|
+ // 表格头部样式
|
|
|
+ header_cell_style: {
|
|
|
+ background: '#E6ECFE',
|
|
|
+ color: '#1A202B',
|
|
|
+ 'font-size': '18px',
|
|
|
+ 'font-family': 'Microsoft YaHei-3970(82674968)'
|
|
|
+ },
|
|
|
+ options: [{
|
|
|
+ value: '0',
|
|
|
+ label: '2022年'
|
|
|
+ }, {
|
|
|
+ value: '1',
|
|
|
+ label: '2021年'
|
|
|
+ }],
|
|
|
+ value: '0', // 下拉列表的值
|
|
|
+ // 预警表格数据
|
|
|
+ yujing_tableData: [{
|
|
|
+ deviceId: '1.5P挂机01',
|
|
|
+ warningTime: '2022-06-23 17:15:15',
|
|
|
+ operator: '朱秀平',
|
|
|
+ serviceTime: '05:25:26',
|
|
|
+ contact: '13688955689'
|
|
|
+ }, {
|
|
|
+ deviceId: '1.5P挂机01',
|
|
|
+ warningTime: '2022-06-23 17:15:15',
|
|
|
+ operator: '朱秀平',
|
|
|
+ serviceTime: '05:25:26',
|
|
|
+ contact: '13688955689'
|
|
|
+ }, {
|
|
|
+ deviceId: '1.5P挂机01',
|
|
|
+ warningTime: '2022-06-23 17:15:15',
|
|
|
+ operator: '朱秀平',
|
|
|
+ serviceTime: '05:25:26',
|
|
|
+ contact: '13688955689'
|
|
|
+ }, {
|
|
|
+ deviceId: '1.5P挂机01',
|
|
|
+ warningTime: '2022-06-23 17:15:15',
|
|
|
+ operator: '朱秀平',
|
|
|
+ serviceTime: '05:25:26',
|
|
|
+ contact: '13688955689'
|
|
|
+ }, {
|
|
|
+ deviceId: '1.5P挂机01',
|
|
|
+ warningTime: '2022-06-23 17:15:15',
|
|
|
+ operator: '朱秀平',
|
|
|
+ serviceTime: '05:25:26',
|
|
|
+ contact: '13688955689'
|
|
|
+ }, {
|
|
|
+ deviceId: '1.5P挂机01',
|
|
|
+ warningTime: '2022-06-23 17:15:15',
|
|
|
+ operator: '朱秀平',
|
|
|
+ serviceTime: '05:25:26',
|
|
|
+ contact: '13688955689'
|
|
|
+ }, {
|
|
|
+ deviceId: '1.5P挂机01',
|
|
|
+ warningTime: '2022-06-23 17:15:15',
|
|
|
+ operator: '朱秀平',
|
|
|
+ serviceTime: '05:25:26',
|
|
|
+ contact: '13688955689'
|
|
|
+ }],
|
|
|
+ // 业务表格数据
|
|
|
+ yewu_tableData: [{
|
|
|
+ desc: '朱秀平电费充值',
|
|
|
+ dataTime: '2022-06-23 17:15:15'
|
|
|
+ }, {
|
|
|
+ desc: '朱秀平电费充值',
|
|
|
+ dataTime: '2022-06-23 17:15:15'
|
|
|
+ }, {
|
|
|
+ desc: '朱秀平电费充值',
|
|
|
+ dataTime: '2022-06-23 17:15:15'
|
|
|
+ }, {
|
|
|
+ desc: '朱秀平电费充值',
|
|
|
+ dataTime: '2022-06-23 17:15:15'
|
|
|
+ }, {
|
|
|
+ desc: '朱秀平电费充值',
|
|
|
+ dataTime: '2022-06-23 17:15:15'
|
|
|
+ }, {
|
|
|
+ desc: '朱秀平电费充值',
|
|
|
+ dataTime: '2022-06-23 17:15:15'
|
|
|
+ }, {
|
|
|
+ desc: '朱秀平电费充值',
|
|
|
+ dataTime: '2022-06-23 17:15:15'
|
|
|
+ }, {
|
|
|
+ desc: '朱秀平电费充值',
|
|
|
+ dataTime: '2022-06-23 17:15:15'
|
|
|
+ }],
|
|
|
+ // 状态表格数据
|
|
|
+ zhuangtai_tableData: [{
|
|
|
+ floor: '1F',
|
|
|
+ scienceBuilding: '26/56',
|
|
|
+ teachBuilding: '26/56',
|
|
|
+ adminBuilding: '26/56',
|
|
|
+ stuCenter: '26/56',
|
|
|
+ library: '26/56'
|
|
|
+ }, {
|
|
|
+ floor: '1F',
|
|
|
+ scienceBuilding: '26/56',
|
|
|
+ teachBuilding: '26/56',
|
|
|
+ adminBuilding: '26/56',
|
|
|
+ stuCenter: '26/56',
|
|
|
+ library: '26/56'
|
|
|
+ }, {
|
|
|
+ floor: '1F',
|
|
|
+ scienceBuilding: '26/56',
|
|
|
+ teachBuilding: '26/56',
|
|
|
+ adminBuilding: '26/56',
|
|
|
+ stuCenter: '26/56',
|
|
|
+ library: '26/56'
|
|
|
+ }, {
|
|
|
+ floor: '1F',
|
|
|
+ scienceBuilding: '26/56',
|
|
|
+ teachBuilding: '26/56',
|
|
|
+ adminBuilding: '26/56',
|
|
|
+ stuCenter: '26/56',
|
|
|
+ library: '26/56'
|
|
|
+ }, {
|
|
|
+ floor: '1F',
|
|
|
+ scienceBuilding: '26/56',
|
|
|
+ teachBuilding: '26/56',
|
|
|
+ adminBuilding: '26/56',
|
|
|
+ stuCenter: '26/56',
|
|
|
+ library: '26/56'
|
|
|
+ }, {
|
|
|
+ floor: '1F',
|
|
|
+ scienceBuilding: '26/56',
|
|
|
+ teachBuilding: '26/56',
|
|
|
+ adminBuilding: '26/56',
|
|
|
+ stuCenter: '26/56',
|
|
|
+ library: '26/56'
|
|
|
+ }, {
|
|
|
+ floor: '1F',
|
|
|
+ scienceBuilding: '26/56',
|
|
|
+ teachBuilding: '26/56',
|
|
|
+ adminBuilding: '26/56',
|
|
|
+ stuCenter: '26/56',
|
|
|
+ library: '26/56'
|
|
|
+ }, {
|
|
|
+ floor: '1F',
|
|
|
+ scienceBuilding: '26/56',
|
|
|
+ teachBuilding: '26/56',
|
|
|
+ adminBuilding: '26/56',
|
|
|
+ stuCenter: '26/56',
|
|
|
+ library: '26/56'
|
|
|
+ }, {
|
|
|
+ floor: '1F',
|
|
|
+ scienceBuilding: '26/56',
|
|
|
+ teachBuilding: '26/56',
|
|
|
+ adminBuilding: '26/56',
|
|
|
+ stuCenter: '26/56',
|
|
|
+ library: '26/56'
|
|
|
+ }],
|
|
|
+ // 折线图数据
|
|
|
+ option: {
|
|
|
tooltip: {
|
|
|
trigger: 'axis'
|
|
|
},
|
|
|
legend: {
|
|
|
y: 'bottom',
|
|
|
x: 'center',
|
|
|
- data: ['Email', 'Union Ads', 'Video Ads', 'Direct']
|
|
|
+ data: ['1.5P', '2P', '3P', '天花机']
|
|
|
},
|
|
|
grid: {
|
|
|
top: '10%',
|
|
|
left: '3%',
|
|
|
- right: '4%',
|
|
|
- bottom: '6%',
|
|
|
+ right: '3%',
|
|
|
+ bottom: '8%',
|
|
|
containLabel: true
|
|
|
},
|
|
|
toolbox: {
|
|
|
@@ -175,31 +344,67 @@
|
|
|
type: 'value'
|
|
|
},
|
|
|
series: [{
|
|
|
- name: 'Email',
|
|
|
+ name: '1.5P',
|
|
|
type: 'line',
|
|
|
stack: 'Total',
|
|
|
data: [120, 132, 101, 134, 90, 230, 210]
|
|
|
},
|
|
|
{
|
|
|
- name: 'Union Ads',
|
|
|
+ name: '2P',
|
|
|
type: 'line',
|
|
|
stack: 'Total',
|
|
|
data: [220, 182, 191, 234, 290, 330, 310]
|
|
|
},
|
|
|
{
|
|
|
- name: 'Video Ads',
|
|
|
+ name: '3P',
|
|
|
type: 'line',
|
|
|
stack: 'Total',
|
|
|
data: [150, 232, 201, 154, 190, 330, 410]
|
|
|
},
|
|
|
{
|
|
|
- name: 'Search Engine',
|
|
|
+ name: '天花机',
|
|
|
type: 'line',
|
|
|
stack: 'Total',
|
|
|
data: [820, 932, 901, 934, 1290, 1330, 1320]
|
|
|
}
|
|
|
]
|
|
|
- });
|
|
|
+ },
|
|
|
+
|
|
|
+ }
|
|
|
+ },
|
|
|
+ mounted() {
|
|
|
+ this.initCharts();
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ /**
|
|
|
+ * 初始化折线图
|
|
|
+ */
|
|
|
+ initCharts() {
|
|
|
+ // 基于准备好的dom,初始化echarts实例
|
|
|
+ var myChart = echarts.init(document.getElementById('main-echart'));
|
|
|
+ // 绘制图表
|
|
|
+ this.setOption(myChart)
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * 向折线图赋值,开始展示数据
|
|
|
+ * @param {Object} myChart
|
|
|
+ */
|
|
|
+ setOption(myChart) {
|
|
|
+ myChart.setOption(this.option);
|
|
|
+ },
|
|
|
+ // 表格某些列样式改变
|
|
|
+ handle_cell_style({
|
|
|
+ row,
|
|
|
+ column,
|
|
|
+ rowIndex,
|
|
|
+ columnIndex
|
|
|
+ }) {
|
|
|
+ if (columnIndex === 1) {
|
|
|
+ // 指定列号
|
|
|
+ return "font-size:14px; color:#808080"
|
|
|
+ } else {
|
|
|
+ return "font-size:18px; color:#292B34"
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
@@ -325,6 +530,14 @@
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ .select-year {
|
|
|
+ position: absolute;
|
|
|
+ right: 20px;
|
|
|
+ top: 68px;
|
|
|
+ width: 100px;
|
|
|
+ z-index: 9999;
|
|
|
+ }
|
|
|
+
|
|
|
.line-echart {
|
|
|
width: 450px;
|
|
|
height: 350px;
|