diff --git a/src/api/mycourse/index.js b/src/api/mycourse/index.js index 9ec09b4..5885257 100644 --- a/src/api/mycourse/index.js +++ b/src/api/mycourse/index.js @@ -11,6 +11,7 @@ const mycourseApi = { recommendList: 'sys/recommend/listPage', // 系统推荐课程列表 recommendDetail: 'sys/recommend/detail', // 系统课程推荐详情 trainPlanList: '/myCourse/getMyTrainPlanList', // 培训计划列表 + getMyTrainPlanCourse: '/myCourse/getMyTrainPlanCourse', // 获取培训计划中的课程列表 getCourseDetail: 'myCourse/getCourseDetail', // 我的课程详情 getCourseCatalogue: 'myCourse/getCourseCatalogue', // 获取课程目录 reqCourseExam: 'testInClass/add', // 课中检测 @@ -19,10 +20,18 @@ const mycourseApi = { operationList: 'classwork/list', // 作业列表 reqOperationDetail: 'classwork/get', // 作业详情 reqOperationSubmit: 'classwork/submit', // 作业提交 - getMyCourseList: 'studyStatistics/getMyTrainPlanList', // 课程学习统计 + getMyCourseList: 'studyStatistics/getMyCourseList', // 课程学习统计 addRecord: '/testInClass/addRecord' // pdf学习完成 } +export function reqMyTrainPlanCourse (data) { + return request({ + url: mycourseApi.getMyTrainPlanCourse, + method: 'get', + params: data + }) +} + export function reqAddRecord (data) { return request({ url: mycourseApi.addRecord, diff --git a/src/views/archives/project/Index.vue b/src/views/archives/project/Index.vue index 080dd00..5fd5885 100644 --- a/src/views/archives/project/Index.vue +++ b/src/views/archives/project/Index.vue @@ -3,7 +3,7 @@
- 导出 +
@@ -16,9 +16,9 @@ 人员记录 - + @@ -37,7 +37,7 @@ export default { return { queryParam: { trainClass: '', trainWay: '', projectName: '' }, columns: [ - { title: '项目ID', width: '60px', align: 'center', dataIndex: 'id', key: 'id' }, + // { title: '项目ID', width: '60px', align: 'center', dataIndex: 'id', key: 'id' }, { title: '项目名称', width: 'auto', align: 'center', dataIndex: 'name', key: 'name' }, { title: '项目时间', width: 'auto', align: 'center', dataIndex: 'time', key: 'time' }, { title: '项目类别', width: 'auto', align: 'center', dataIndex: 'way', key: 'way' }, diff --git a/src/views/archives/project/ProjectUser.vue b/src/views/archives/project/ProjectUser.vue index d43f60c..24b641c 100644 --- a/src/views/archives/project/ProjectUser.vue +++ b/src/views/archives/project/ProjectUser.vue @@ -38,7 +38,7 @@ export default { data() { // 这里存放数据 return { - queryParam: { state: '', userName: '' }, + queryParam: {id:this.$route.query.projectId}, //state: '', userName: '' columns: [ { title: '姓名', width: '100px', align: 'center', dataIndex: 'name', key: 'name' }, { title: '单位信息', width: 'auto', align: 'center', dataIndex: 'dwOrgName', key: 'dwOrgName' }, @@ -101,7 +101,7 @@ export default { path: '/archives/project/ProjectUserCourse', query: { projectId: this.$route.query.id, userId: record.id, - queryParamState: this.queryParam.state, + queryParamState: this.queryParam.testState, queryParamUserName: this.queryParam.userName, pageNum1: this.$refs.table.localPagination.current, diff --git a/src/views/archives/project/ProjectUserAnswer.vue b/src/views/archives/project/ProjectUserAnswer.vue index fa1e941..4b33186 100644 --- a/src/views/archives/project/ProjectUserAnswer.vue +++ b/src/views/archives/project/ProjectUserAnswer.vue @@ -61,7 +61,9 @@ export default { // 答题记录 archivesProjectUserAnswerDateil(record) { + console.log('详情',record); + this.$router.push({ path: '/myreport', query: { type: 'exam', reportId: record.reportId } }) } }, diff --git a/src/views/archives/project/ProjectUserCourse.vue b/src/views/archives/project/ProjectUserCourse.vue index 58a7a7f..9caa550 100644 --- a/src/views/archives/project/ProjectUserCourse.vue +++ b/src/views/archives/project/ProjectUserCourse.vue @@ -30,7 +30,7 @@ export default { { title: '总题量', width: '80px', align: 'center', dataIndex: 'addUpExercises', key: 'addUpExercises' }, { title: '已答题量', width: '100px', align: 'center', dataIndex: 'alreadyExercises', key: 'alreadyExercises' }, { title: '答对题量', width: '90px', align: 'center', dataIndex: 'yesExercises', key: 'yesExercises' }, - { title: '答对正确率', width: '90px', align: 'center', dataIndex: 'yesTopic', key: 'yesTopic' }, + { title: '答对正确率', width: '90px', align: 'center', dataIndex: 'yesRate', key: 'yesRate' }, { title: '完成状态', width: '80px', align: 'center', dataIndex: 'finishState', key: 'finishState', customRender: (text, record, index) => { // 完成状态 0-未完成 1-已完成 @@ -61,6 +61,9 @@ export default { close() { this.$router.push({ path: '/archives/project/ProjectUser', query: { + projectId:this.$route.query.projectId, + userId:this.$route.query.userId, + queryParamState: this.$route.query.queryParamState, queryParamUserName: this.$route.query.queryParamUserName, pageNum1: this.$route.query.pageNum1, diff --git a/src/views/archives/user/Project.vue b/src/views/archives/user/Project.vue index b1e040f..564fc79 100644 --- a/src/views/archives/user/Project.vue +++ b/src/views/archives/user/Project.vue @@ -88,8 +88,17 @@ export default { queryParam: { projectName: this.$route.query.archivesUserProjectTable2projectName || '' }, columns: [ { title: '项目名称', width: 'auto', align: 'center', dataIndex: 'projectName', key: 'projectName' }, - { title: '项目时间', width: 'auto', align: 'center', dataIndex: 'projectData', key: 'projectData' }, - { title: '受训角色', width: 'auto', align: 'center', dataIndex: 'roleName', key: 'roleName' }, + { + title: '项目时间', + width: 'auto', + align: 'center', + dataIndex: 'startDate', + key: 'startDate', + customRender: (text, record, index) => { + return record.startDate + ' - ' + record.endDate + }, + }, + // { title: '受训角色', width: 'auto', align: 'center', dataIndex: 'roleName', key: 'roleName' }, { title: '培训地址', width: 'auto', align: 'center', dataIndex: 'trainAddr', key: 'trainAddr' }, { title: '签到时间', width: 'auto', align: 'center', dataIndex: 'signInTime', key: 'signInTime' }, { @@ -100,7 +109,7 @@ export default { }, { title: '操作', width: '90px', key: 'operation', align: 'center', scopedSlots: { customRender: 'action' } } ], - loadData: parameter => { return getArchivesUserTerminalTrainList(Object.assign(parameter, this.tabs2.queryParam)).then(res => { return res }) } + loadData: parameter => { return getArchivesUserTerminalTrainList(Object.assign(parameter, this.tabs2.queryParam, {personId : this.personId})).then(res => { return res }) } } } }, @@ -177,6 +186,8 @@ export default { path: '/archives/user/TerminalTrainDetail', query: { personId: this.personId, projectId: record.id, + signInTime: record.signInTime, + state: record.finishState, archivesUserName: this.$route.query.archivesUserName, archivesUserOrgId: this.$route.query.archivesUserOrgId, archivesUserPageNum: this.$route.query.archivesUserPageNum, diff --git a/src/views/archives/user/ProjectAnswer.vue b/src/views/archives/user/ProjectAnswer.vue index 88dca92..bd94d0d 100644 --- a/src/views/archives/user/ProjectAnswer.vue +++ b/src/views/archives/user/ProjectAnswer.vue @@ -19,9 +19,9 @@ export default { components: { STable, SearchCom }, data() { return { - userId: this.$route.query.userId, + personId: this.$route.query.personId, projectId: this.$route.query.projectId, - queryParam: { userId: this.$route.query.userId, projectId: this.$route.query.projectId }, + queryParam: { personId: this.$route.query.personId, projectId: this.$route.query.projectId }, columns: [ { title: '交卷时间', width: 'auto', align: 'center', dataIndex: 'handDate', key: 'handDate' }, { title: '考试时长', width: 'auto', align: 'center', dataIndex: 'testTime', key: 'testTime' }, @@ -47,7 +47,10 @@ export default { defaultActiveKey: this.$route.query.defaultActiveKey } }); + }, + trainDetail (record) { + this.$router.push({ path: '/myreport', query: { type: 'exam', reportId: record.reportId } }) } } } - \ No newline at end of file + diff --git a/src/views/archives/user/ProjectDetail.vue b/src/views/archives/user/ProjectDetail.vue index 7a287a2..077daea 100644 --- a/src/views/archives/user/ProjectDetail.vue +++ b/src/views/archives/user/ProjectDetail.vue @@ -18,7 +18,7 @@ export default { components: { STable, SearchCom }, data() { return { - queryParam: { userId: this.$route.query.userId, projectId: this.$route.query.projectId, courseName: '' }, + queryParam: { personId: this.$route.query.personId, projectId: this.$route.query.projectId, courseName: '' }, columns: [ { title: '课程名称', width: 'auto', align: 'center', dataIndex: 'courseName', key: 'courseName' }, { title: '应修学时', width: 'auto', align: 'center', dataIndex: 'mustClassHour', key: 'mustClassHour' }, @@ -26,7 +26,7 @@ export default { { title: '总题量', width: 'auto', align: 'center', dataIndex: 'addUpExercises', key: 'addUpExercises' }, { title: '已答题量', width: 'auto', align: 'center', dataIndex: 'alreadyExercises', key: 'alreadyExercises' }, { title: '答对题量', width: 'auto', align: 'center', dataIndex: 'yesExercises', key: 'yesExercises' }, - { title: '答对正确率', width: 'auto', align: 'center', dataIndex: 'yesTopic', key: 'yesTopic' }, + { title: '答对正确率', width: 'auto', align: 'center', dataIndex: 'yesRate', key: 'yesRate' }, { title: '完成状态', width: 'auto', align: 'center', dataIndex: 'finishState', key: 'finishState', customRender: (text, record, index) => { // 完成状态 0-未完成 1-已完成 @@ -46,7 +46,7 @@ export default { }, methods: { handleRefresh() { - this.queryParam.userId = this.$route.query.userId; + this.queryParam.personId = this.$route.query.personId; this.queryParam.projectId = this.$route.query.projectId; this.$refs.table.refresh(true) }, @@ -54,7 +54,7 @@ export default { close() { this.$router.push({ path: '/archives/user/Project', query: { - id: this.$route.query.userId, + id: this.$route.query.personId, archivesUserName: this.$route.query.archivesUserName, archivesUserOrgId: this.$route.query.archivesUserOrgId, archivesUserPageNum: this.$route.query.archivesUserPageNum, @@ -67,4 +67,4 @@ export default { } } } - \ No newline at end of file + diff --git a/src/views/archives/user/SelfStudy.vue b/src/views/archives/user/SelfStudy.vue index 600e3f3..589b48a 100644 --- a/src/views/archives/user/SelfStudy.vue +++ b/src/views/archives/user/SelfStudy.vue @@ -18,7 +18,7 @@ export default { components: { STable, SearchCom }, data() { return { - queryParam: { userId: this.$route.query.userId, courseName: '' }, + queryParam: { personId: this.$route.query.personId, courseName: '' }, columns: [ { title: '课程名称', width: 'auto', align: 'center', dataIndex: 'courseName', key: 'courseName' }, { title: '课时(分)', width: 'auto', align: 'center', dataIndex: 'classHour', key: 'classHour' }, @@ -36,7 +36,7 @@ export default { }, methods: { handleRefresh() { - this.queryParam.userId = this.$route.query.userId; + this.queryParam.personId = this.$route.query.personId; this.$refs.table.refresh(true) }, // 返回 按钮 diff --git a/src/views/archives/user/TerminalTrainDetail.vue b/src/views/archives/user/TerminalTrainDetail.vue index 380e000..1c349f0 100644 --- a/src/views/archives/user/TerminalTrainDetail.vue +++ b/src/views/archives/user/TerminalTrainDetail.vue @@ -29,19 +29,24 @@ import { getArchivesUserTerminalTrainDetail } from '@/api/archives/user' export default { data() { return { - queryParam: { userId: this.$route.query.userId, projectId: this.$route.query.projectId }, + queryParam: { personId: this.$route.query.personId, projectId: this.$route.query.projectId }, detailData: {} } }, created: function () { let parameter = {}; - getArchivesUserTerminalTrainDetail(Object.assign(parameter, this.queryParam)).then(res => { this.detailData = res.data }); + getArchivesUserTerminalTrainDetail(Object.assign(parameter, this.queryParam)).then(res => { + this.detailData = res.data + this.detailData.signInTime = this.$route.query.signInTime + this.detailData.state = this.$route.query.state == 1 ? '已完成' : '未完成' + }); + }, methods: { close() { this.$router.push({ path: '/archives/user/Project', query: { - id: this.$route.query.userId, + id: this.$route.query.personId, archivesUserName: this.$route.query.archivesUserName, archivesUserOrgId: this.$route.query.archivesUserOrgId, archivesUserPageNum: this.$route.query.archivesUserPageNum, @@ -60,4 +65,4 @@ export default { width: 100px; text-align: center; } - \ No newline at end of file + diff --git a/src/views/archives/user/Violation.vue b/src/views/archives/user/Violation.vue index 6073799..ae1cd93 100644 --- a/src/views/archives/user/Violation.vue +++ b/src/views/archives/user/Violation.vue @@ -19,14 +19,15 @@ export default { components: { STable, SearchCom }, data() { return { - queryParam: { userId: this.$route.query.userId, courseName: '' }, + personId: this.$route.query.id, + queryParam: { courseName: '' }, columns: [ - { title: '违章编号', width: 'auto', align: 'center', dataIndex: 'id', key: 'id' }, + { title: '违章编号', width: 'auto', align: 'center', dataIndex: 'violationCode', key: 'violationCode' }, { title: '违章时间', width: 'auto', align: 'center', dataIndex: 'time', key: 'time' }, { title: '违章内容', width: 'auto', align: 'center', dataIndex: 'content', key: 'content' }, { title: '违章课时', width: 'auto', align: 'center', dataIndex: 'courseName', key: 'courseName' }, ], - loadData: parameter => { return getArchivesUserViolationList(Object.assign(parameter, this.queryParam)).then(res => { return res }) } + loadData: parameter => { return getArchivesUserViolationList(Object.assign(parameter, this.queryParam, {personId : this.personId})).then(res => { return res }) } } }, computed: { @@ -38,7 +39,6 @@ export default { }, methods: { handleRefresh() { - this.queryParam.userId = this.userId; this.$refs.table.refresh(true) }, // 返回 按钮 @@ -53,4 +53,4 @@ export default { } } } - \ No newline at end of file + diff --git a/src/views/course/CourseAdd.vue b/src/views/course/CourseAdd.vue index 6196511..91eedd4 100644 --- a/src/views/course/CourseAdd.vue +++ b/src/views/course/CourseAdd.vue @@ -16,7 +16,7 @@ - + + + + + diff --git a/src/views/mycourse/mycourseList/MyCourseList.vue b/src/views/mycourse/mycourseList/MyCourseList.vue index f2a0276..21e9eb2 100644 --- a/src/views/mycourse/mycourseList/MyCourseList.vue +++ b/src/views/mycourse/mycourseList/MyCourseList.vue @@ -60,13 +60,22 @@