项目档案-终端培训开发

This commit is contained in:
QuAoLi 2022-03-17 16:25:43 +08:00
parent 48ae8cc3cb
commit 165d3f28a3
5 changed files with 36 additions and 17 deletions

View File

@ -88,8 +88,17 @@ export default {
queryParam: { projectName: this.$route.query.archivesUserProjectTable2projectName || '' }, queryParam: { projectName: this.$route.query.archivesUserProjectTable2projectName || '' },
columns: [ columns: [
{ title: '项目名称', width: 'auto', align: 'center', dataIndex: 'projectName', key: 'projectName' }, { 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: 'trainAddr', key: 'trainAddr' },
{ title: '签到时间', width: 'auto', align: 'center', dataIndex: 'signInTime', key: 'signInTime' }, { 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' } } { 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: { path: '/archives/user/TerminalTrainDetail', query: {
personId: this.personId, personId: this.personId,
projectId: record.id, projectId: record.id,
signInTime: record.signInTime,
state: record.finishState,
archivesUserName: this.$route.query.archivesUserName, archivesUserName: this.$route.query.archivesUserName,
archivesUserOrgId: this.$route.query.archivesUserOrgId, archivesUserOrgId: this.$route.query.archivesUserOrgId,
archivesUserPageNum: this.$route.query.archivesUserPageNum, archivesUserPageNum: this.$route.query.archivesUserPageNum,

View File

@ -19,9 +19,9 @@ export default {
components: { STable, SearchCom }, components: { STable, SearchCom },
data() { data() {
return { return {
userId: this.$route.query.userId, personId: this.$route.query.personId,
projectId: this.$route.query.projectId, 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: [ columns: [
{ title: '交卷时间', width: 'auto', align: 'center', dataIndex: 'handDate', key: 'handDate' }, { title: '交卷时间', width: 'auto', align: 'center', dataIndex: 'handDate', key: 'handDate' },
{ title: '考试时长', width: 'auto', align: 'center', dataIndex: 'testTime', key: 'testTime' }, { title: '考试时长', width: 'auto', align: 'center', dataIndex: 'testTime', key: 'testTime' },
@ -47,7 +47,10 @@ export default {
defaultActiveKey: this.$route.query.defaultActiveKey defaultActiveKey: this.$route.query.defaultActiveKey
} }
}); });
},
trainDetail (record) {
this.$router.push({ path: '/myreport', query: { type: 'exam', reportId: record.reportId } })
} }
} }
} }
</script> </script>

View File

@ -18,7 +18,7 @@ export default {
components: { STable, SearchCom }, components: { STable, SearchCom },
data() { data() {
return { 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: [ columns: [
{ title: '课程名称', width: 'auto', align: 'center', dataIndex: 'courseName', key: 'courseName' }, { title: '课程名称', width: 'auto', align: 'center', dataIndex: 'courseName', key: 'courseName' },
{ title: '应修学时', width: 'auto', align: 'center', dataIndex: 'mustClassHour', key: 'mustClassHour' }, { 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: 'addUpExercises', key: 'addUpExercises' },
{ title: '已答题量', width: 'auto', align: 'center', dataIndex: 'alreadyExercises', key: 'alreadyExercises' }, { title: '已答题量', width: 'auto', align: 'center', dataIndex: 'alreadyExercises', key: 'alreadyExercises' },
{ title: '答对题量', width: 'auto', align: 'center', dataIndex: 'yesExercises', key: 'yesExercises' }, { 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) => { title: '完成状态', width: 'auto', align: 'center', dataIndex: 'finishState', key: 'finishState', customRender: (text, record, index) => {
// 0- 1- // 0- 1-
@ -46,7 +46,7 @@ export default {
}, },
methods: { methods: {
handleRefresh() { handleRefresh() {
this.queryParam.userId = this.$route.query.userId; this.queryParam.personId = this.$route.query.personId;
this.queryParam.projectId = this.$route.query.projectId; this.queryParam.projectId = this.$route.query.projectId;
this.$refs.table.refresh(true) this.$refs.table.refresh(true)
}, },
@ -54,7 +54,7 @@ export default {
close() { close() {
this.$router.push({ this.$router.push({
path: '/archives/user/Project', query: { path: '/archives/user/Project', query: {
id: this.$route.query.userId, id: this.$route.query.personId,
archivesUserName: this.$route.query.archivesUserName, archivesUserName: this.$route.query.archivesUserName,
archivesUserOrgId: this.$route.query.archivesUserOrgId, archivesUserOrgId: this.$route.query.archivesUserOrgId,
archivesUserPageNum: this.$route.query.archivesUserPageNum, archivesUserPageNum: this.$route.query.archivesUserPageNum,
@ -67,4 +67,4 @@ export default {
} }
} }
} }
</script> </script>

View File

@ -18,7 +18,7 @@ export default {
components: { STable, SearchCom }, components: { STable, SearchCom },
data() { data() {
return { return {
queryParam: { userId: this.$route.query.userId, courseName: '' }, queryParam: { personId: this.$route.query.personId, courseName: '' },
columns: [ columns: [
{ title: '课程名称', width: 'auto', align: 'center', dataIndex: 'courseName', key: 'courseName' }, { title: '课程名称', width: 'auto', align: 'center', dataIndex: 'courseName', key: 'courseName' },
{ title: '课时(分)', width: 'auto', align: 'center', dataIndex: 'classHour', key: 'classHour' }, { title: '课时(分)', width: 'auto', align: 'center', dataIndex: 'classHour', key: 'classHour' },
@ -36,7 +36,7 @@ export default {
}, },
methods: { methods: {
handleRefresh() { handleRefresh() {
this.queryParam.userId = this.$route.query.userId; this.queryParam.personId = this.$route.query.personId;
this.$refs.table.refresh(true) this.$refs.table.refresh(true)
}, },
// //

View File

@ -29,19 +29,24 @@ import { getArchivesUserTerminalTrainDetail } from '@/api/archives/user'
export default { export default {
data() { data() {
return { return {
queryParam: { userId: this.$route.query.userId, projectId: this.$route.query.projectId }, queryParam: { personId: this.$route.query.personId, projectId: this.$route.query.projectId },
detailData: {} detailData: {}
} }
}, },
created: function () { created: function () {
let parameter = {}; 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: { methods: {
close() { close() {
this.$router.push({ this.$router.push({
path: '/archives/user/Project', query: { path: '/archives/user/Project', query: {
id: this.$route.query.userId, id: this.$route.query.personId,
archivesUserName: this.$route.query.archivesUserName, archivesUserName: this.$route.query.archivesUserName,
archivesUserOrgId: this.$route.query.archivesUserOrgId, archivesUserOrgId: this.$route.query.archivesUserOrgId,
archivesUserPageNum: this.$route.query.archivesUserPageNum, archivesUserPageNum: this.$route.query.archivesUserPageNum,
@ -60,4 +65,4 @@ export default {
width: 100px; width: 100px;
text-align: center; text-align: center;
} }
</style> </style>