Commit 6c9982b2 authored by 张伯涛's avatar 张伯涛

bug修改

parent 68fddf63
<template> <template>
<page-layout> <page-layout>
<el-tabs class="tab-box" v-model="activeName" @tab-click="handleClick"> <el-tabs v-model="activeName" class="tab-box" @tab-click="handleClick">
<el-tab-pane label="课程" name="first"> <el-tab-pane label="课程" name="first">
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="6"> <el-col :span="6">
<RankStatistics></RankStatistics> <RankStatistics />
</el-col> </el-col>
<el-col :span="18"> <el-col :span="18">
<typeStatistics></typeStatistics> <typeStatistics />
</el-col> </el-col>
</el-row> </el-row>
...@@ -18,8 +18,8 @@ ...@@ -18,8 +18,8 @@
</div> </div>
</div> </div>
<el-form <el-form
style="margin-top: 20px;"
ref="queryForm" ref="queryForm"
style="margin-top: 20px;"
:model="queryClassesParams" :model="queryClassesParams"
:inline="true" :inline="true"
label-width="70px" label-width="70px"
...@@ -29,22 +29,20 @@ ...@@ -29,22 +29,20 @@
v-model="queryClassesParams.lessonName" v-model="queryClassesParams.lessonName"
placeholder="请输入" placeholder="请输入"
:maxlength="30" :maxlength="30"
></el-input> />
</el-form-item> </el-form-item>
<el-form-item prop="name"> <el-form-item prop="name">
<el-button <el-button
type="primary" type="primary"
size="mini" size="mini"
@click="handleQuery('classes')"
class="search-btn" class="search-btn"
>查询</el-button @click="handleQuery('classes')"
> >查询</el-button>
<el-button <el-button
size="mini" size="mini"
@click="resetQuery('classes')"
class="reset-btn" class="reset-btn"
>重置</el-button @click="resetQuery('classes')"
> >重置</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table <el-table
...@@ -92,11 +90,10 @@ ...@@ -92,11 +90,10 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('totalNumber', scope.row)"
href="javascript:;" href="javascript:;"
@click="openTable('totalNumber', scope.row)"
> >
{{ scope.row.totalNumber }}</a {{ scope.row.totalNumber }}</a>
>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -107,11 +104,10 @@ ...@@ -107,11 +104,10 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('notstartedNumber', scope.row)"
href="javascript:;" href="javascript:;"
@click="openTable('notstartedNumber', scope.row)"
> >
{{ scope.row.notstartedNumber }}</a {{ scope.row.notstartedNumber }}</a>
>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -123,11 +119,10 @@ ...@@ -123,11 +119,10 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('learningNumber', scope.row)"
href="javascript:;" href="javascript:;"
@click="openTable('learningNumber', scope.row)"
> >
{{ scope.row.learningNumber }}</a {{ scope.row.learningNumber }}</a>
>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -138,11 +133,10 @@ ...@@ -138,11 +133,10 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('completedNumber', scope.row)"
href="javascript:;" href="javascript:;"
@click="openTable('completedNumber', scope.row)"
> >
{{ scope.row.completedNumber }}</a {{ scope.row.completedNumber }}</a>
>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -153,15 +147,14 @@ ...@@ -153,15 +147,14 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('examineNumber', scope.row)"
href="javascript:;" href="javascript:;"
@click="openTable('examineNumber', scope.row)"
> >
{{ scope.row.examineNumber }}</a {{ scope.row.examineNumber }}</a>
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="pagination-list" v-show="classesTotal > 0"> <div v-show="classesTotal > 0" class="pagination-list">
<pagination <pagination
:total="classesTotal" :total="classesTotal"
:background="false" :background="false"
...@@ -181,8 +174,8 @@ ...@@ -181,8 +174,8 @@
</div> </div>
</div> </div>
<el-form <el-form
style="margin-top: 20px;"
ref="queryForm" ref="queryForm"
style="margin-top: 20px;"
:model="queryGroupParams" :model="queryGroupParams"
:inline="true" :inline="true"
label-width="70px" label-width="70px"
...@@ -192,22 +185,20 @@ ...@@ -192,22 +185,20 @@
v-model="queryGroupParams.name" v-model="queryGroupParams.name"
placeholder="请输入" placeholder="请输入"
:maxlength="30" :maxlength="30"
></el-input> />
</el-form-item> </el-form-item>
<el-form-item prop="name"> <el-form-item prop="name">
<el-button <el-button
type="primary" type="primary"
size="mini" size="mini"
@click="handleQuery('group')"
class="search-btn" class="search-btn"
>查询</el-button @click="handleQuery('group')"
> >查询</el-button>
<el-button <el-button
size="mini" size="mini"
@click="resetQuery('group')"
class="reset-btn" class="reset-btn"
>重置</el-button @click="resetQuery('group')"
> >重置</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table <el-table
...@@ -232,8 +223,7 @@ ...@@ -232,8 +223,7 @@
show-overflow-tooltip show-overflow-tooltip
min-width="130" min-width="130"
align="center" align="center"
> />
</el-table-column>
<el-table-column <el-table-column
label="小组人数" label="小组人数"
show-overflow-tooltip show-overflow-tooltip
...@@ -243,10 +233,9 @@ ...@@ -243,10 +233,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('personCount', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.personCount }}</a @click="openTable('personCount', scope.row)"
> >{{ scope.row.personCount }}</a>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -258,10 +247,9 @@ ...@@ -258,10 +247,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('courseCount', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.courseCount }}</a @click="openTable('courseCount', scope.row)"
> >{{ scope.row.courseCount }}</a>
</template> </template>
</el-table-column> </el-table-column>
...@@ -273,10 +261,9 @@ ...@@ -273,10 +261,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('gstatusCount1', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.statusCount1 }}</a @click="openTable('gstatusCount1', scope.row)"
> >{{ scope.row.statusCount1 }}</a>
</template> </template>
</el-table-column> </el-table-column>
...@@ -288,10 +275,9 @@ ...@@ -288,10 +275,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('gstatusCount2', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.statusCount2 }}</a @click="openTable('gstatusCount2', scope.row)"
> >{{ scope.row.statusCount2 }}</a>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -302,14 +288,13 @@ ...@@ -302,14 +288,13 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('gstatusCount3', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.statusCount3 }}</a @click="openTable('gstatusCount3', scope.row)"
> >{{ scope.row.statusCount3 }}</a>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="pagination-list" v-show="groupTotal > 0"> <div v-show="groupTotal > 0" class="pagination-list">
<pagination <pagination
:total="groupTotal" :total="groupTotal"
:background="false" :background="false"
...@@ -329,8 +314,8 @@ ...@@ -329,8 +314,8 @@
</div> </div>
</div> </div>
<el-form <el-form
style="margin-top: 20px;"
ref="queryForm" ref="queryForm"
style="margin-top: 20px;"
:model="queryUserParams" :model="queryUserParams"
:inline="true" :inline="true"
> >
...@@ -339,29 +324,27 @@ ...@@ -339,29 +324,27 @@
v-model="queryUserParams.name" v-model="queryUserParams.name"
:maxlength="30" :maxlength="30"
placeholder="请输入" placeholder="请输入"
></el-input> />
</el-form-item> </el-form-item>
<el-form-item label="小组:" prop="groupName"> <el-form-item label="小组:" prop="groupName">
<el-input <el-input
v-model="queryUserParams.groupName" v-model="queryUserParams.groupName"
:maxlength="30" :maxlength="30"
placeholder="请输入" placeholder="请输入"
></el-input> />
</el-form-item> </el-form-item>
<el-form-item prop="name"> <el-form-item prop="name">
<el-button <el-button
type="primary" type="primary"
size="mini" size="mini"
@click="handleQuery('user')"
class="search-btn" class="search-btn"
>查询</el-button @click="handleQuery('user')"
> >查询</el-button>
<el-button <el-button
size="mini" size="mini"
@click="resetQuery('user')"
class="reset-btn" class="reset-btn"
>重置</el-button @click="resetQuery('user')"
> >重置</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table class="list-table" :loading="loading" :data="tableUserData"> <el-table class="list-table" :loading="loading" :data="tableUserData">
...@@ -381,21 +364,21 @@ ...@@ -381,21 +364,21 @@
prop="name" prop="name"
min-width="130" min-width="130"
align="center" align="center"
></el-table-column> />
<el-table-column <el-table-column
label="手机号" label="手机号"
prop="phone" prop="phone"
show-overflow-tooltip show-overflow-tooltip
min-width="130" min-width="130"
align="center" align="center"
></el-table-column> />
<el-table-column <el-table-column
label="小组" label="小组"
prop="groupName" prop="groupName"
show-overflow-tooltip show-overflow-tooltip
min-width="130" min-width="130"
align="center" align="center"
></el-table-column> />
<el-table-column <el-table-column
label="计划课程总数" label="计划课程总数"
show-overflow-tooltip show-overflow-tooltip
...@@ -405,10 +388,9 @@ ...@@ -405,10 +388,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('total', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.total }}</a @click="openTableStudent('total', scope.row)"
> >{{ scope.row.total }}</a>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -419,10 +401,9 @@ ...@@ -419,10 +401,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('learning', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.learning }}</a @click="openTableStudent('learning', scope.row)"
> >{{ scope.row.learning }}</a>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -433,10 +414,9 @@ ...@@ -433,10 +414,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('finish', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.finish }}</a @click="openTableStudent('finish', scope.row)"
> >{{ scope.row.finish }}</a>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -447,10 +427,9 @@ ...@@ -447,10 +427,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('notStart', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.notStart }}</a @click="openTableStudent('notStart', scope.row)"
> >{{ scope.row.notStart }}</a>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -461,10 +440,9 @@ ...@@ -461,10 +440,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('examedNumber', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.examedNumber }}</a @click="openTableStudent('examedNumber', scope.row)"
> >{{ scope.row.examedNumber }}</a>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -475,14 +453,13 @@ ...@@ -475,14 +453,13 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('notExamedNumber', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.notExamedNumber }}</a @click="openTableStudent('notExamedNumber', scope.row)"
> >{{ scope.row.notExamedNumber }}</a>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="pagination-list" v-show="userTotal > 0"> <div v-show="userTotal > 0" class="pagination-list">
<pagination <pagination
:total="userTotal" :total="userTotal"
:background="false" :background="false"
...@@ -502,8 +479,8 @@ ...@@ -502,8 +479,8 @@
</div> </div>
</div> </div>
<el-form <el-form
style="margin-top: 20px;"
ref="queryForm" ref="queryForm"
style="margin-top: 20px;"
:model="queryCheckParams" :model="queryCheckParams"
:inline="true" :inline="true"
label-width="70px" label-width="70px"
...@@ -513,22 +490,20 @@ ...@@ -513,22 +490,20 @@
v-model="queryCheckParams.lessonName" v-model="queryCheckParams.lessonName"
placeholder="请输入" placeholder="请输入"
:maxlength="30" :maxlength="30"
></el-input> />
</el-form-item> </el-form-item>
<el-form-item prop="name"> <el-form-item prop="name">
<el-button <el-button
type="primary" type="primary"
size="mini" size="mini"
@click="handleQuery('check')"
class="search-btn" class="search-btn"
>查询</el-button @click="handleQuery('check')"
> >查询</el-button>
<el-button <el-button
size="mini" size="mini"
@click="resetQuery('user')"
class="reset-btn" class="reset-btn"
>重置</el-button @click="resetQuery('user')"
> >重置</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table <el-table
...@@ -553,8 +528,7 @@ ...@@ -553,8 +528,7 @@
label="课程名称" label="课程名称"
min-width="130" min-width="130"
align="left" align="left"
> />
</el-table-column>
<el-table-column <el-table-column
label="试题数" label="试题数"
show-overflow-tooltip show-overflow-tooltip
...@@ -584,10 +558,9 @@ ...@@ -584,10 +558,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('assessorsCount', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.assessorsCount }}</a @click="openTable('assessorsCount', scope.row)"
> >{{ scope.row.assessorsCount }}</a>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -629,10 +602,9 @@ ...@@ -629,10 +602,9 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('statusCount1', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.statusCount1 }}</a @click="openTable('statusCount1', scope.row)"
> >{{ scope.row.statusCount1 }}</a>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -644,14 +616,13 @@ ...@@ -644,14 +616,13 @@
<template slot-scope="scope"> <template slot-scope="scope">
<a <a
class="link-item" class="link-item"
@click="openTable('statusCount2', scope.row)"
href="javascript:;" href="javascript:;"
>{{ scope.row.statusCount2 }}</a @click="openTable('statusCount2', scope.row)"
> >{{ scope.row.statusCount2 }}</a>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="pagination-list" v-show="checkTotal > 0"> <div v-show="checkTotal > 0" class="pagination-list">
<pagination <pagination
:total="checkTotal" :total="checkTotal"
:background="false" :background="false"
...@@ -664,12 +635,14 @@ ...@@ -664,12 +635,14 @@
</div> </div>
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
<tableDialog :dialog-manager="dialogManager"></tableDialog> <tableDialog :dialog-manager="dialogManager" />
<student_table-dialog :dialog-manager="dialogManagerStudent" />
</page-layout> </page-layout>
</template> </template>
<script> <script>
import RankStatistics from '../components/rankStatistics' import RankStatistics from '../components/rankStatistics'
import _tableDialog from './_tableDialog' import _tableDialog from './_tableDialog'
import student_tableDialog from './student_tableDialog.vue'
import typeStatistics from '../components/typeStatistics' import typeStatistics from '../components/typeStatistics'
import request from '@/utils/request' import request from '@/utils/request'
export default { export default {
...@@ -677,11 +650,20 @@ export default { ...@@ -677,11 +650,20 @@ export default {
components: { components: {
RankStatistics, RankStatistics,
tableDialog: _tableDialog, tableDialog: _tableDialog,
student_tableDialog,
typeStatistics typeStatistics
}, },
data() { data() {
return { return {
// 学员的抽屉
dialogManagerStudent: {
dialogVisible: false,
query: [],
params: {},
tableColumn: [],
url: ''
},
dialogManager: { dialogManager: {
dialogVisible: false, dialogVisible: false,
query: [], query: [],
...@@ -717,6 +699,20 @@ export default { ...@@ -717,6 +699,20 @@ export default {
} }
}, },
computed: {}, computed: {},
created() {
this.activeName = 'first'
this.queryClassesParams.page = 1
this.loadClassesData()
// this.activeName = 'second'
// this.handleClick()
// this.activeName = 'third'
// this.handleClick()
// this.activeName = 'forth'
// this.queryClassesParams.page = 1
// this.loadCheckData()
},
methods: { methods: {
handleQuery(type) { handleQuery(type) {
switch (type) { switch (type) {
...@@ -879,6 +875,152 @@ export default { ...@@ -879,6 +875,152 @@ export default {
this.loading = false this.loading = false
}) })
}, },
openTableStudent(type, row) {
this.dialogManagerStudent.lessonId = row.lessonId
this.dialogManagerStudent.userId = row.businessId
switch (type) {
// 计划课程总数
case 'total':
this.dialogManagerStudent.url = 'plannedCourseNum'
this.dialogManagerStudent.query = [
{
name: '学员',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '计划课程总数',
value: row.total + '门',
class: 'red'
}
]
this.dialogManagerStudent.tableColumn = [
{ label: '学习类型', prop: 'learningType' },
{ label: '课程名称', prop: 'lessonName' },
{ label: '课程讲师', prop: 'lessonTeaName' },
{ label: '剩余有效天数', prop: 'availableTrialTime' },
{ label: '学习状态', prop: 'learningState' }
]
break
// 学习中课程数
case 'learning':
this.dialogManagerStudent.url = 'learningCourseNum'
this.dialogManagerStudent.query = [
{
name: '学员',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '学习中课程数',
value: row.learning + '门',
class: 'red'
}
]
this.dialogManagerStudent.tableColumn = [
{ label: '学习类型', prop: 'learningType' },
{ label: '课程名称', prop: 'lessonName' },
{ label: '课程讲师', prop: 'lessonTeaName' },
{ label: '剩余有效天数', prop: 'availableTrialTime' },
{ label: '学习进度', prop: 'learningProgress' }
]
break
// 已学完课程数
case 'finish':
this.dialogManagerStudent.url = 'learnedCourseNum'
this.dialogManagerStudent.query = [
{
name: '学员',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '已学完课程数',
value: row.finish + '门',
class: 'red'
}
]
this.dialogManagerStudent.tableColumn = [
{ label: '学习类型', prop: 'learningType' },
{ label: '课程名称', prop: 'lessonName' },
{ label: '课程讲师', prop: 'lessonTeaName' },
{ label: '课时', prop: 'classHour' },
{ label: '完成日期', prop: 'completionDate' }
]
break
// 未开始课程数
case 'notStart':
this.dialogManagerStudent.url = 'noStartedCourseNum'
this.dialogManagerStudent.query = [
{
name: '学员',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '未开始课程数',
value: row.notStart + '门',
class: 'red'
}
]
this.dialogManagerStudent.tableColumn = [
{ label: '学习类型', prop: 'learningType' },
{ label: '课程名称', prop: 'lessonName' },
{ label: '课程讲师', prop: 'lessonTeaName' },
{ label: '课时', prop: 'classHour' },
{ label: '完成日期', prop: 'completionDate' }
]
break
// 参与考核课程数
case 'examedNumber':
this.dialogManagerStudent.url = 'beAssessingCourseNum'
this.dialogManagerStudent.query = [
{
name: '学员',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '参与考核课程数',
value: row.examedNumber + '门',
class: 'red'
}
]
this.dialogManagerStudent.tableColumn = [
{ label: '课程名称', prop: 'lessonName' },
{ label: '满分/及格线', prop: 'fullAndPass' },
{ label: '课程平均分', prop: 'averageGrade' },
{ label: '考核提交时间', prop: 'assessmentCompletionTime' },
{ label: '考核成绩(分)', prop: 'lessonScore' }
]
break
// 未考核课程数
case 'notExamedNumber':
this.dialogManagerStudent.url = 'noAssessedCourseNum'
this.dialogManagerStudent.query = [
{
name: '学员',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '未考核课程数',
value: row.notExamedNumber + '门',
class: 'red'
}
]
this.dialogManagerStudent.tableColumn = [
{ label: '课程名称', prop: 'lessonName' },
{ label: '满分/及格线', prop: 'fullAndPass' },
{ label: '课程平均分', prop: 'averageGrade' },
{ label: '最高分', prop: 'maxScore' },
{ label: '最低分', prop: 'minScore' }
]
break
}
this.dialogManagerStudent.dialogVisible = true
},
openTable(type, row) { openTable(type, row) {
switch (type) { switch (type) {
case 'assessorsCount': case 'assessorsCount':
...@@ -1070,7 +1212,7 @@ export default { ...@@ -1070,7 +1212,7 @@ export default {
{ label: '考核成绩(分)', prop: 'score' } { label: '考核成绩(分)', prop: 'score' }
] ]
break break
//‘组内人数分页查询 // ‘组内人数分页查询
case 'personCount': case 'personCount':
this.dialogManager.url = 'pcgroup/groupDetailsAll' this.dialogManager.url = 'pcgroup/groupDetailsAll'
this.dialogManager.params.groupId = row.businessId this.dialogManager.params.groupId = row.businessId
...@@ -1094,7 +1236,7 @@ export default { ...@@ -1094,7 +1236,7 @@ export default {
{ label: '状态', prop: 'flag' } { label: '状态', prop: 'flag' }
] ]
break break
//必修课程数分页查询 // 必修课程数分页查询
case 'courseCount': case 'courseCount':
this.dialogManager.url = 'pcgroup/groupCourseAll' this.dialogManager.url = 'pcgroup/groupCourseAll'
this.dialogManager.params.groupId = row.businessId this.dialogManager.params.groupId = row.businessId
...@@ -1118,7 +1260,7 @@ export default { ...@@ -1118,7 +1260,7 @@ export default {
{ label: '剩余有效天数', prop: 'effectiveDays' } { label: '剩余有效天数', prop: 'effectiveDays' }
] ]
break break
//已完成课程数分页 // 已完成课程数分页
case 'gstatusCount1': case 'gstatusCount1':
this.dialogManager.url = 'pcgroup/courseCompletedAll' this.dialogManager.url = 'pcgroup/courseCompletedAll'
this.dialogManager.params.groupId = row.businessId this.dialogManager.params.groupId = row.businessId
...@@ -1142,7 +1284,7 @@ export default { ...@@ -1142,7 +1284,7 @@ export default {
{ label: '完成日期', prop: 'completeDate' } { label: '完成日期', prop: 'completeDate' }
] ]
break break
//未完成必修课人次 // 未完成必修课人次
case 'gstatusCount2': case 'gstatusCount2':
this.dialogManager.url = 'pcgroup/courseIncompleteAll' this.dialogManager.url = 'pcgroup/courseIncompleteAll'
this.dialogManager.params.groupId = row.businessId this.dialogManager.params.groupId = row.businessId
...@@ -1189,174 +1331,10 @@ export default { ...@@ -1189,174 +1331,10 @@ export default {
{ label: '绩效成绩(分)', prop: 'score' } { label: '绩效成绩(分)', prop: 'score' }
] ]
break break
case 'total':
this.dialogManager.url = 'studentstatistics/information'
this.dialogManager.params.businessId = row.businessId
this.dialogManager.params.total = true
this.dialogManager.query = [
{
name: '学员:',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '计划课程总数:',
value: row.total + '门',
class: 'red'
}
]
this.dialogManager.tableColumn = [
{ label: '学习类型', prop: 'classType' },
{ label: '课程名称', prop: 'className' },
{ label: '课程讲师', prop: 'classTeacher' },
{ label: '剩余有效天数', prop: 'days' },
{ label: '学习状态 ', prop: 'status' }
]
break
//学习中课程数
case 'learning':
this.dialogManager.url = 'studentstatistics/information'
this.dialogManager.params.businessId = row.businessId
this.dialogManager.params.learning = true
this.dialogManager.query = [
{
name: '学员:',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '学习中课程数',
value: row.learningCourseNum + '门',
class: 'red'
}
]
this.dialogManager.tableColumn = [
{ label: '学习类型', prop: 'classType' },
{ label: '课程名称', prop: 'className' },
{ label: '课程讲师', prop: 'classTeacher' },
{ label: '剩余有效天数', prop: 'days' },
{ label: '学习状态 ', prop: 'status' }
]
break
//已学完课程数
case 'finish':
this.dialogManager.url = 'studentstatistics/information'
this.dialogManager.params.businessId = row.businessId
this.dialogManager.params.finish = true
this.dialogManager.query = [
{
name: '学员:',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '已学完课程数',
value: row.finish + '门',
class: 'red'
}
]
this.dialogManager.tableColumn = [
{ label: '学习类型', prop: 'classType' },
{ label: '课程名称', prop: 'className' },
{ label: '课程讲师', prop: 'classTeacher' },
{ label: '课时', prop: 'classHour' },
{ label: '完成日期', prop: 'finishDate' }
]
break
//未开始课程数
case 'notStart':
this.dialogManager.url = 'studentstatistics/information'
this.dialogManager.params.businessId = row.businessId
this.dialogManager.params.notStart = true
this.dialogManager.query = [
{
name: '学员:',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '未开始课程数',
value: row.notStart + '门',
class: 'red'
}
]
this.dialogManager.tableColumn = [
{ label: '学习类型', prop: 'classType' },
{ label: '课程名称', prop: 'className' },
{ label: '课程讲师', prop: 'classTeacher' },
{ label: '剩余有效天数', prop: 'days' },
{ label: '学习状态 ', prop: 'status' }
]
break
//参与考核课程数
case 'examedNumber':
this.dialogManager.url = 'studentstatistics/information'
this.dialogManager.params.businessId = row.businessId
this.dialogManager.params.examedNumber = true
this.dialogManager.query = [
{
name: '学员:',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '参与考核课程数',
value: row.examedNumber + '门',
class: 'red'
}
]
this.dialogManager.tableColumn = [
{ label: '课程名称', prop: 'className' },
{ label: '满分/及格线', prop: 'standard' },
{ label: '课程平均分', prop: 'courseAverage' },
{ label: '考核提交时间', prop: 'submissionTime' },
{ label: '考核成绩(分)', prop: 'score' }
]
break
//未考核课程数
case 'notExamedNumber':
this.dialogManager.url = 'studentstatistics/information'
this.dialogManager.params.businessId = row.businessId
this.dialogManager.params.notExamedNumber = true
this.dialogManager.query = [
{
name: '学员:',
value: row.name + '-' + row.phone,
class: ''
},
{
name: '未考核课程数',
value: row.notExamedNumber + '门',
class: 'red'
}
]
this.dialogManager.tableColumn = [
{ label: '课程名称', prop: 'className' },
{ label: '满分/及格线', prop: 'standard' },
{ label: '课程平均分', prop: 'courseAverage' },
{ label: '考核提交时间', prop: 'submissionTime' },
{ label: '考核成绩(分)', prop: 'score' }
]
break
} }
this.dialogManager.dialogVisible = true this.dialogManager.dialogVisible = true
} }
},
created() {
this.activeName = 'first'
this.queryClassesParams.page = 1
this.loadClassesData()
// this.activeName = 'second'
// this.handleClick()
// this.activeName = 'third'
// this.handleClick()
// this.activeName = 'forth'
// this.queryClassesParams.page = 1
// this.loadCheckData()
} }
} }
</script> </script>
......
<template>
<el-drawer
title="统计明细"
:visible.sync="dialogManager.dialogVisible"
direction="rtl"
size="60%"
:before-close="
() => {
dialogManager.dialogVisible = false
}
"
>
<el-row class="search-form">
<el-col :span="12" :key="k" v-for="(i, k) in dialogManager.query">
<div class="search-form-item">
<div class="item-label">{{ i.name }}:</div>
<div class="item-content" :class="i.class">
{{ i.value }}
</div>
</div>
</el-col>
</el-row>
<div style="padding: 20px;">
<el-table :data="tableData" v-loading="loading" style="width: 100%">
<el-table-column type="index" width="70" label="序号" align="center">
<template slot-scope="scope">
<span>{{ scope.$index + 1 }}</span>
</template>
</el-table-column>
<el-table-column
v-for="(item, key) in dialogManager.tableColumn"
:key="key"
:prop="item.prop"
:label="item.label"
min-width="120"
align="center"
>
</el-table-column>
</el-table>
<div class="pagination-list" v-show="total > 0">
<pagination
:total="total"
:background="false"
layout="total, sizes, prev, pager, next, jumper"
:page.sync="queryParams.page"
:limit.sync="queryParams.rows"
@pagination="loadData"
/>
</div>
</div>
</el-drawer>
</template>
<script>
import page from '@/mixins/page'
import request from '@/utils/request'
export default {
props: {
dialogManager: {}
},
data() {
return {
tableData: [],
queryParams: {
page: 1,
rows: 20
}
}
},
mixins: [page],
methods: {
loadData() {
if (!this.dialogManager.url) {
return
}
this.loading = true
request({
url: '/blesson/pagingStatisticsDetail',
method: 'get',
params: {
...this.queryParams,
...{
lessonId: this.dialogManager.lessonId, //课程id
userId: this.dialogManager.userId, //用户id
viewType: 1, // 视图类型(0:课程;1:学员)
statisticalType: this.dialogManager.url
}
},
headers: {
// 'Content-Type': 'application/json'
'Content-Type': 'application/x-www-form-urlencode'
}
})
.then(res => {
console.log('cehhsdd')
this.tableData = res.data.records
console.log(this.tableData)
console.log(this.dialogManager.tableColumn)
this.total = res.data.total
this.loading = false
})
.catch(error => {
if (error.msg) {
this.$message.error(error.msg)
}
this.loading = false
})
}
},
watch: {
'dialogManager.dialogVisible'(val) {
if (val) {
this.loadData()
}
}
}
}
</script>
<style></style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment