# add log history table

This commit is contained in:
xianfuxing 2018-08-13 21:18:05 +08:00
parent 24f1b02e20
commit 27db1ba5d4
3 changed files with 50 additions and 0 deletions

View File

@ -35,3 +35,12 @@ export function fetchDeviceLogStatistic(query) {
params: query
})
}
// log statistic history api
export function fetchLogStatisticHistory(query) {
return request({
url: '/api/counter/logs/statistic/history/',
method: 'get',
params: query
})
}

View File

@ -0,0 +1,35 @@
<template>
<div>
<el-table
v-loading="listLoading"
:data="deviceList"
style="width: 100%">
<el-table-column
prop="id"
label="序号"
min-width="80">
</el-table-column>
<el-table-column
prop="date"
label="日期"
min-width="100">
</el-table-column>
<el-table-column
prop="increment"
label="数量"
min-width="100">
</el-table-column>
</el-table>
</div>
</template>
<script>
export default {
name: 'LogHistoryTable'
}
</script>
<style rel="stylesheet/scss" lang="scss">
</style>

View File

@ -15,6 +15,10 @@
<line-chart :chart-data="lineChartData"></line-chart>
</el-row>
<el-row>
<log-history-table></log-history-table>
</el-row>
<!-- <el-row :gutter="32">
<el-col :xs="24" :sm="24" :lg="8">
<div class="chart-wrapper">
@ -52,6 +56,7 @@
import GithubCorner from '@/components/GithubCorner'
import PanelGroup from './components/PanelGroup'
import LineChart from './components/LineChart'
import LogHistoryTable from './components/LogHistoryTable'
import RaddarChart from './components/RaddarChart'
import PieChart from './components/PieChart'
import BarChart from './components/BarChart'
@ -85,6 +90,7 @@ export default {
GithubCorner,
PanelGroup,
LineChart,
LogHistoryTable,
RaddarChart,
PieChart,
BarChart,