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