|
@@ -10,38 +10,33 @@
|
|
<div class="left-div">
|
|
<div class="left-div">
|
|
<div class="row-div">
|
|
<div class="row-div">
|
|
<div class="total-div">
|
|
<div class="total-div">
|
|
- <span style="width: 85px; height: 85px; display: block;">
|
|
|
|
- <v-icon
|
|
|
|
- name="users"
|
|
|
|
- style="height: 50px; width: 50px;"
|
|
|
|
- /> </span
|
|
|
|
- ><span style="display: block; margin-left: 10px;">
|
|
|
|
- <span
|
|
|
|
- style="display: block; font-weight: bold; font-size: 40px;"
|
|
|
|
- >{{ totalStudent }}</span
|
|
|
|
- >
|
|
|
|
- <span style="display: block;">注册学生</span>
|
|
|
|
|
|
+ <span style="width: 85px;height: 85px;display:block;">
|
|
|
|
+ <v-icon name="users" style="height: 50px;width: 50px;" /> </span
|
|
|
|
+ ><span style="display:block;margin-left: 10px;">
|
|
|
|
+ <span style="display:block;font-weight:bold;font-size:40px">{{
|
|
|
|
+ totalStudent
|
|
|
|
+ }}</span>
|
|
|
|
+ <span style="display:block;">注册学生</span>
|
|
</span>
|
|
</span>
|
|
</div>
|
|
</div>
|
|
<div class="online-div">
|
|
<div class="online-div">
|
|
- <span style="width: 85px; height: 85px; display: block;">
|
|
|
|
|
|
+ <span style="width: 85px;height: 85px;display:block;">
|
|
<v-icon
|
|
<v-icon
|
|
name="user-check"
|
|
name="user-check"
|
|
- style="height: 50px; width: 50px;"
|
|
|
|
|
|
+ style="height: 50px;width: 50px;"
|
|
/> </span
|
|
/> </span
|
|
- ><span style="display: block; margin-left: 10px;">
|
|
|
|
- <span
|
|
|
|
- style="display: block; font-weight: bold; font-size: 40px;"
|
|
|
|
- >{{ totalOnlineStudent }}</span
|
|
|
|
- >
|
|
|
|
- <span style="display: block;">在线学生</span>
|
|
|
|
|
|
+ ><span style="display:block;margin-left: 10px;">
|
|
|
|
+ <span style="display:block;font-weight:bold;font-size:40px">{{
|
|
|
|
+ totalOnlineStudent
|
|
|
|
+ }}</span>
|
|
|
|
+ <span style="display:block;">在线学生</span>
|
|
</span>
|
|
</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="tb-div">
|
|
<div class="tb-div">
|
|
<div class="row-div">
|
|
<div class="row-div">
|
|
- <span style="float: left;"> 学校在线学生</span
|
|
|
|
- ><span style="float: right;"
|
|
|
|
|
|
+ <span style="float:left;"> 学校在线学生</span
|
|
|
|
+ ><span style="float:right;"
|
|
><el-button
|
|
><el-button
|
|
size="small"
|
|
size="small"
|
|
type="primary"
|
|
type="primary"
|
|
@@ -51,7 +46,7 @@
|
|
详情
|
|
详情
|
|
</el-button></span
|
|
</el-button></span
|
|
>
|
|
>
|
|
- <span style="float: right; margin-right: 10px;"
|
|
|
|
|
|
+ <span style="float:right;margin-right: 10px;"
|
|
><el-button
|
|
><el-button
|
|
size="small"
|
|
size="small"
|
|
type="primary"
|
|
type="primary"
|
|
@@ -105,7 +100,7 @@
|
|
<div class="right-div">
|
|
<div class="right-div">
|
|
<div class="row-div">近5日在线学生</div>
|
|
<div class="row-div">近5日在线学生</div>
|
|
<div class="row-div">
|
|
<div class="row-div">
|
|
- <v-charts style="width: 500px;" :options="lastNdayData"></v-charts>
|
|
|
|
|
|
+ <v-charts style="width:500px;" :options="lastNdayData"></v-charts>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@@ -118,32 +113,32 @@ import { mapState } from "vuex";
|
|
import ECharts from "vue-echarts/components/ECharts";
|
|
import ECharts from "vue-echarts/components/ECharts";
|
|
export default {
|
|
export default {
|
|
components: {
|
|
components: {
|
|
- "v-charts": ECharts,
|
|
|
|
|
|
+ "v-charts": ECharts
|
|
},
|
|
},
|
|
name: "ExamStudentOnline",
|
|
name: "ExamStudentOnline",
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
lastNdayData: {
|
|
lastNdayData: {
|
|
tooltip: {
|
|
tooltip: {
|
|
- trigger: "axis",
|
|
|
|
|
|
+ trigger: "axis"
|
|
},
|
|
},
|
|
xAxis: {
|
|
xAxis: {
|
|
axisLabel: {
|
|
axisLabel: {
|
|
interval: 0,
|
|
interval: 0,
|
|
- rotate: 20,
|
|
|
|
|
|
+ rotate: 20
|
|
},
|
|
},
|
|
type: "category",
|
|
type: "category",
|
|
- data: [],
|
|
|
|
|
|
+ data: []
|
|
},
|
|
},
|
|
yAxis: {
|
|
yAxis: {
|
|
- type: "value",
|
|
|
|
|
|
+ type: "value"
|
|
},
|
|
},
|
|
series: [
|
|
series: [
|
|
{
|
|
{
|
|
data: [],
|
|
data: [],
|
|
- type: "line",
|
|
|
|
- },
|
|
|
|
- ],
|
|
|
|
|
|
+ type: "line"
|
|
|
|
+ }
|
|
|
|
+ ]
|
|
},
|
|
},
|
|
totalStudent: 0,
|
|
totalStudent: 0,
|
|
totalOnlineStudent: 0,
|
|
totalOnlineStudent: 0,
|
|
@@ -152,19 +147,19 @@ export default {
|
|
tableData: [],
|
|
tableData: [],
|
|
currentPage: 1,
|
|
currentPage: 1,
|
|
pageSize: 10,
|
|
pageSize: 10,
|
|
- total: 10,
|
|
|
|
|
|
+ total: 10
|
|
};
|
|
};
|
|
},
|
|
},
|
|
computed: {
|
|
computed: {
|
|
- ...mapState({ user: (state) => state.user }),
|
|
|
|
|
|
+ ...mapState({ user: state => state.user }),
|
|
isSuperAdmin() {
|
|
isSuperAdmin() {
|
|
- return this.user.roleList.some((role) => role.roleCode == "SUPER_ADMIN");
|
|
|
|
- },
|
|
|
|
|
|
+ return this.user.roleList.some(role => role.roleCode == "SUPER_ADMIN");
|
|
|
|
+ }
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
toInfoPage() {
|
|
toInfoPage() {
|
|
this.$router.push({
|
|
this.$router.push({
|
|
- path: "/reports/online-detail",
|
|
|
|
|
|
+ path: "/reports/online-detail"
|
|
});
|
|
});
|
|
},
|
|
},
|
|
refresh() {
|
|
refresh() {
|
|
@@ -197,12 +192,12 @@ export default {
|
|
this.pageSize;
|
|
this.pageSize;
|
|
this.$httpWithMsg
|
|
this.$httpWithMsg
|
|
.get(url)
|
|
.get(url)
|
|
- .then((response) => {
|
|
|
|
|
|
+ .then(response => {
|
|
this.tableData = response.data.list;
|
|
this.tableData = response.data.list;
|
|
this.total = response.data.total;
|
|
this.total = response.data.total;
|
|
this.loading = false;
|
|
this.loading = false;
|
|
|
|
|
|
- this.$nextTick(function () {
|
|
|
|
|
|
+ this.$nextTick(function() {
|
|
this.paginationShow = true;
|
|
this.paginationShow = true;
|
|
});
|
|
});
|
|
})
|
|
})
|
|
@@ -210,34 +205,34 @@ export default {
|
|
},
|
|
},
|
|
async searchTotalStudent() {
|
|
async searchTotalStudent() {
|
|
var url = REPORTS_API + "/studentTotalCount/getSumTotalCount";
|
|
var url = REPORTS_API + "/studentTotalCount/getSumTotalCount";
|
|
- this.$httpWithMsg.get(url).then((response) => {
|
|
|
|
|
|
+ this.$httpWithMsg.get(url).then(response => {
|
|
this.totalStudent = response.data;
|
|
this.totalStudent = response.data;
|
|
});
|
|
});
|
|
},
|
|
},
|
|
async searchTotalOnlineStudent() {
|
|
async searchTotalOnlineStudent() {
|
|
var url = REPORTS_API + "/studentCount/getSumOnlineCount";
|
|
var url = REPORTS_API + "/studentCount/getSumOnlineCount";
|
|
- this.$httpWithMsg.get(url).then((response) => {
|
|
|
|
|
|
+ this.$httpWithMsg.get(url).then(response => {
|
|
this.totalOnlineStudent = response.data;
|
|
this.totalOnlineStudent = response.data;
|
|
});
|
|
});
|
|
},
|
|
},
|
|
async searchLastNDayData() {
|
|
async searchLastNDayData() {
|
|
var url =
|
|
var url =
|
|
REPORTS_API + "/studentCumulativeCount/getLastNdayOnlineCount?nday=5";
|
|
REPORTS_API + "/studentCumulativeCount/getLastNdayOnlineCount?nday=5";
|
|
- this.$httpWithMsg.get(url).then((response) => {
|
|
|
|
|
|
+ this.$httpWithMsg.get(url).then(response => {
|
|
let xdata = [];
|
|
let xdata = [];
|
|
- response.data.forEach((e) => {
|
|
|
|
|
|
+ response.data.forEach(e => {
|
|
xdata.push(e.reportDay);
|
|
xdata.push(e.reportDay);
|
|
});
|
|
});
|
|
this.lastNdayData.xAxis.data = xdata;
|
|
this.lastNdayData.xAxis.data = xdata;
|
|
let ydata = [];
|
|
let ydata = [];
|
|
- response.data.forEach((e) => {
|
|
|
|
|
|
+ response.data.forEach(e => {
|
|
ydata.push(e.totalCount);
|
|
ydata.push(e.totalCount);
|
|
});
|
|
});
|
|
this.lastNdayData.series = [
|
|
this.lastNdayData.series = [
|
|
{
|
|
{
|
|
data: ydata,
|
|
data: ydata,
|
|
- type: "line",
|
|
|
|
- },
|
|
|
|
|
|
+ type: "line"
|
|
|
|
+ }
|
|
];
|
|
];
|
|
});
|
|
});
|
|
},
|
|
},
|
|
@@ -246,12 +241,12 @@ export default {
|
|
this.searchLastNDayData();
|
|
this.searchLastNDayData();
|
|
this.searchTotalOnlineStudent();
|
|
this.searchTotalOnlineStudent();
|
|
this.searchForm();
|
|
this.searchForm();
|
|
- },
|
|
|
|
|
|
+ }
|
|
},
|
|
},
|
|
//初始化查询
|
|
//初始化查询
|
|
created() {
|
|
created() {
|
|
this.init();
|
|
this.init();
|
|
- },
|
|
|
|
|
|
+ }
|
|
};
|
|
};
|
|
</script>
|
|
</script>
|
|
|
|
|