Merge remote-tracking branch 'origin/develop' into develop

This commit is contained in:
yuping
2023-03-17 14:57:12 +08:00
13 changed files with 314 additions and 80 deletions

View File

@@ -208,6 +208,7 @@ import {
PROJECT_DETAIL,
SubmitExternalExam,
UPDATE_CURRENT_TASK,
checkStudentExist,
} from "@/api/api";
import { useRoute, useRouter } from "vue-router";
import store from "@/store";
@@ -224,12 +225,27 @@ const router = useRouter();
const { commit, dispatch, state } = useStore();
const data = computed(() => state.projectInfo);
useRequest(PROJECT_PROCESS, { projectId: projectId, type }, (e) => {
if (e.code === 6) {
console.log("eee", e);
router.push({
path: "/notpath",
});
}
useRequest(
checkStudentExist,
{
targetId: projectId,
type: type,
},
(res) => {
console.log("判断任务是否删除", res);
if (res.code === 7) {
router.push({
path: "/loseefficacy",
});
} else {
if (e.code === 6) {
router.push({
path: "/notpath",
});
}
}
}
);
});
watch(data, () => {
if (data.value.code === 6) {