diff --git a/src/router/index.js b/src/router/index.js
index f103d84b2..59471c241 100644
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -172,7 +172,6 @@ const StudentManage = () => import('@/views/organization/classManage/studentMana
const DurationView = () => import('@/views/organization/classManage/durationView');
const GradeList = () => import('@/views/organization/examManage/gradeList');
const GradeStatistics = () => import('@/views/organization/examManage/gradeStatistics');
-const StudentGradeStatis = () => import('@/views/organization/studentStatistics/studentGradeStatis');
const StudentStatistics = () => import('@/views/organization/studentStatistics/index');
const CreateRule = () => import('@/views/organization/ruleManage/createRule');
const TotalGrade = () => import('@/views/organization/ruleManage/totalGrade');
@@ -665,11 +664,6 @@ export const publicAsyncRoute = [
component: StudentStatistics,
hidden: true
},
- {
- path: 'studentGradeStatis',
- component: StudentGradeStatis,
- hidden: true
- },
{
path: 'createRule',
component: CreateRule,
diff --git a/src/views/organization/classManage/studentManage/index.vue b/src/views/organization/classManage/studentManage/index.vue
index 4ff635e2c..2fafdd24e 100644
--- a/src/views/organization/classManage/studentManage/index.vue
+++ b/src/views/organization/classManage/studentManage/index.vue
@@ -11,6 +11,7 @@
style="width:80%;margin: 0 auto;"
/>
+
@@ -19,11 +20,13 @@ import { queryDeptInfoPaging, deleteDepartUserRelation, importCompanyMember } fr
import CreateStudent from './createStudent';
import XLSX from 'xlsx';
import { convertSheetToList } from '@/jmapNew/theme/parser/util.js';
+import StudentGradeStatis from '../../studentStatistics/studentGradeStatis'
export default {
name: 'StudentManage',
components: {
- CreateStudent
+ CreateStudent,
+ StudentGradeStatis
},
data() {
return {
@@ -208,14 +211,7 @@ export default {
XLSX.writeFile(wb, '学生信息模板' + '.xlsx');
},
gradeStatistic(index,row){
- this.$router.push({ path: '/info/studentGradeStatis',
- query: {
- username: row.name,
- departmentId: row.departmentId,
- userId: row.userId,
- orgRole: row.orgRole
- }
- });
+ this.$refs.studentGradeStatis.doShow(row);
},
removeStudent(index, row) {
const _that = this;
diff --git a/src/views/organization/studentStatistics/gradeStatistic.vue b/src/views/organization/studentStatistics/gradeStatistic.vue
index 8db1358c2..1c5f1fbd0 100644
--- a/src/views/organization/studentStatistics/gradeStatistic.vue
+++ b/src/views/organization/studentStatistics/gradeStatistic.vue
@@ -6,6 +6,25 @@ import * as echarts from 'echarts';
import { getStuGradeStatistic } from '@/api/management/userexam';
export default {
name: 'GradeStatistics',
+ props:{
+ creatorId:{
+ type:String,
+ require:true
+ },
+ orgId:{
+ type:Number,
+ require:true
+ },
+ userId:{
+ type:Number,
+ require:true
+ },
+ },
+ watch:{
+ 'orgId':function(){
+ this.loadData()
+ }
+ },
data() {
return {
myChart2:null,
@@ -48,7 +67,6 @@ export default {
},
async mounted() {
this.initChart()
- this.loadData()
},
methods: {
initChart(){
@@ -84,8 +102,12 @@ export default {
}
option && this.myChart2 && this.myChart2.setOption(option);
},
+ doShow(){
+ this.loadData();
+ },
loadData(){
- let data={creatorId:'',orgId:'',userId:''}
+ let data={creatorId:this.creatorId,orgId:this.orgId,userId:this.userId}
+ debugger
getStuGradeStatistic(data).then(res=>{
const results = resp.data;
if (results) {
diff --git a/src/views/organization/studentStatistics/index.vue b/src/views/organization/studentStatistics/index.vue
index 7de972361..ede846c24 100644
--- a/src/views/organization/studentStatistics/index.vue
+++ b/src/views/organization/studentStatistics/index.vue
@@ -8,7 +8,7 @@
-
+
@@ -29,6 +29,8 @@ export default {
data() {
return {
myChart3:null,
+ creatorId:'',
+ orgId:'',
title:{
show:true,
text:'仿真时长统计',
@@ -44,6 +46,12 @@ export default {
async mounted() {
this.initChart()
this.loadData();
+ this.orgId=parseInt(this.$store.state.user.companyId);
+ },
+ computed:{
+ userId(){
+ return parseInt(this.$store.state.user.id);
+ }
},
methods: {
initChart(){
diff --git a/src/views/organization/studentStatistics/studentGradeStatis.vue b/src/views/organization/studentStatistics/studentGradeStatis.vue
index 6d9771333..02fef7ae1 100644
--- a/src/views/organization/studentStatistics/studentGradeStatis.vue
+++ b/src/views/organization/studentStatistics/studentGradeStatis.vue
@@ -1,11 +1,17 @@
-
-
{{ studentName+'统计信息' }}
-
返回
+
-
+
-
+