mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-student.git
synced 2025-12-07 01:46:46 +08:00
feat:增加面授课去考试及部分字段传值
This commit is contained in:
@@ -236,7 +236,7 @@
|
||||
name="third"
|
||||
:disabed="dayjs().isBefore(dayjs(data.planDto?.beginTime))"
|
||||
>
|
||||
<div class="work" v-if="data.examinationDto?.examinationTestName">
|
||||
<div class="work" v-if="data.examinationDto?.id">
|
||||
<div>
|
||||
<div class="question">
|
||||
{{ data.examinationDto?.examinationName }}
|
||||
@@ -244,8 +244,7 @@
|
||||
<div style="margin-top: 16px; display: flex">
|
||||
<div
|
||||
class="tag1"
|
||||
v-if="data.examinationDto?.examinationFlag"
|
||||
>
|
||||
v-if="data.examinationDto?.examinationFlag">
|
||||
必修
|
||||
</div>
|
||||
<div class="tag3" style="margin-left: 11px">考试</div>
|
||||
@@ -260,8 +259,7 @@
|
||||
: '',
|
||||
}"
|
||||
class="submit"
|
||||
@click="toExamItem(data.examinationDto)"
|
||||
>
|
||||
@click="toExamItem(data.examinationDto)">
|
||||
去考试
|
||||
</div>
|
||||
</div>
|
||||
@@ -481,6 +479,7 @@ function toSurvery() {
|
||||
}
|
||||
|
||||
function toWork() {
|
||||
console.log(data)
|
||||
if (data.value.planDto.beginTime) {
|
||||
let date1 = new Date(data.value.planDto.beginTime).getTime();
|
||||
let date2 = new Date().getTime();
|
||||
@@ -510,11 +509,28 @@ function toExamItem(obj) {
|
||||
ElMessage.warning("未到开始时间,请耐心等待!");
|
||||
}
|
||||
}
|
||||
console.log("obj", obj.examinationTestId);
|
||||
window.open(
|
||||
window.location.protocol + import.meta.env.VITE_BOE_EXAM_DETAIL_URL + obj.examinationTestId,
|
||||
"_top"
|
||||
); //测评
|
||||
console.log("obj", obj, obj.examType);
|
||||
// 判断内部还是外部考试
|
||||
if(obj.examType==2){
|
||||
router.push({
|
||||
path: '/externalexamination',
|
||||
query: {
|
||||
courseId: obj.id,
|
||||
type: 3,
|
||||
exname: obj.examinationName, // 考试名称
|
||||
},
|
||||
});
|
||||
}else{
|
||||
window.open(
|
||||
window.location.protocol + import.meta.env.VITE_BOE_EXAM_DETAIL_URL + obj.examinationTestId,
|
||||
"_top"
|
||||
);
|
||||
}
|
||||
// window.open(
|
||||
// window.location.protocol + import.meta.env.VITE_BOE_EXAM_DETAIL_URL + obj.examinationTestId,
|
||||
// "_top"
|
||||
// );
|
||||
//测评
|
||||
// router.push({ path: import.meta.env.VITE_BOE_EXAM_DETAIL_URL+ obj.examinationTestId });
|
||||
}
|
||||
|
||||
|
||||
@@ -487,8 +487,8 @@ const {
|
||||
} = useRoute();
|
||||
const { data } =
|
||||
taskId && taskId !== "undefined"
|
||||
? useRequest(TASK_WORK_DETAIL, { workId, taskId })
|
||||
: useRequest(TASK_WORK_DETAIL, { workId });
|
||||
? useRequest(TASK_WORK_DETAIL, { workId, taskId, type })
|
||||
: useRequest(TASK_WORK_DETAIL, { workId, type });
|
||||
|
||||
console.log("data==----->", data);
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
import {useTaskPage} from "@/api/useCommon";
|
||||
|
||||
const {
|
||||
query: {courseId, pName, sName, chapterOrStageId, infoId, id, exname},
|
||||
query: {courseId, pName, sName, chapterOrStageId, infoId, id, exname, type},
|
||||
} = useRoute();
|
||||
const {nextPage,prevPage,hasPrev, hasNext} = useTaskPage()
|
||||
const router = useRouter();
|
||||
@@ -95,7 +95,7 @@
|
||||
})
|
||||
|
||||
//获取基本信息
|
||||
request(EXTERNALEXAM, {externalId:courseId}).then(res=>{
|
||||
request(EXTERNALEXAM, {externalId:courseId, type}).then(res=>{
|
||||
console.log(res)
|
||||
state.datainfo = res.data
|
||||
}).catch(err=>{
|
||||
|
||||
Reference in New Issue
Block a user