mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-student.git
synced 2025-12-10 19:36:48 +08:00
fix -- bug
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
<div class="pdname">
|
||||
{{ data.name }}
|
||||
<el-popover v-if="data.chapterRemark" ref="popover" popper-class="jianjie" placement="right" trigger="hover"
|
||||
:width="300" :content="data.chapterRemark">
|
||||
:width="300" :content="data.chapterRemark">
|
||||
<template #reference><span style="font-size: 16px;font-weight: 600;">关卡说明></span></template>
|
||||
</el-popover>
|
||||
</div>
|
||||
@@ -19,14 +19,15 @@
|
||||
<div class="title">
|
||||
<div class="titleL">{{ data.currentStageName }}</div>
|
||||
<div class="titleR" :style="{ display: 'flex' }">
|
||||
<img :src="data.currentChapterCnt ? circle : circle2" />
|
||||
<img :src="data.currentChapterCnt ? circle : circle2"/>
|
||||
<div class="titleRT"
|
||||
:style="(data.statusName === '已完成' || data.statusName === '进行中') ? 'color:#0060ff' : 'color:#999'">
|
||||
{{ data.statusName || (data.unlockMode === 1 ? '未开始' : '未解锁') }}
|
||||
:style="(data.statusName === '已完成' || data.statusName === '进行中') ? 'color:#0060ff' : 'color:#999'">
|
||||
{{ data.statusName || (data.unlockMode === 1 ? "未开始" : "未解锁") }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="course" v-for="(value, index) in data.taskBoList?.filter((e) => !whiteTypes(e.type))" :key="index">
|
||||
<div class="course" v-for="(value, index) in data.taskBoList?.filter((e) => !whiteTypes(e.type))"
|
||||
:key="index">
|
||||
<div style="width: 70%">
|
||||
<div v-if="value.name.length > 50" class="coursename" :title="value.name">
|
||||
<el-popover ref="popover" placement="right" trigger="hover" :width="300" :content="value.name">
|
||||
@@ -61,7 +62,8 @@
|
||||
<div>当前进度</div>
|
||||
<div class="progress">
|
||||
<div style="width: 291px">
|
||||
<el-progress :percentage="parseInt(value.currentRatio)" :show-text="false" :stroke-width="8" :color="
|
||||
<el-progress :percentage="parseInt(value.currentRatio)" :show-text="false" :stroke-width="8"
|
||||
:color="
|
||||
{
|
||||
0: 'rgba(238, 112, 108, 1)',
|
||||
1: 'rgba(255, 151, 38, 1)',
|
||||
@@ -70,7 +72,7 @@
|
||||
4: 'rgba(57, 219, 183, 1)',
|
||||
5: 'rgba(57, 219, 183, 1)',
|
||||
}[parseInt(parseInt(value.currentRatio) / 20)]
|
||||
" />
|
||||
"/>
|
||||
</div>
|
||||
<div style="font-size: 14px;font-weight: 500;color: #277aff;margin-left: 10px;" :style="{
|
||||
color: {
|
||||
@@ -88,9 +90,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="goclass"
|
||||
:style="{ background: (value.statusName !== '已结束' && (value.statusName || data.unlockMode === 1)) ? '#2478ff' : '#999' }"
|
||||
@click="toFinish(value)">
|
||||
{{ value.statusName || (data.unlockMode === 1 ? TASK_TYPES.toName[value.type] : '未解锁') }}
|
||||
:style="{ background: (value.statusName !== '已结束' && (value.statusName || data.unlockMode === 1)) ? '#2478ff' : '#999' }"
|
||||
@click="toFinish(value)">
|
||||
{{ value.statusName || (data.unlockMode === 1 ? TASK_TYPES.toName[value.type] : "未解锁") }}
|
||||
</div>
|
||||
<!-- <div :style="{ display: value.status === 1 ? 'block' : 'none' }">-->
|
||||
<!-- <div-->
|
||||
@@ -132,7 +134,7 @@
|
||||
:style="{ width: '22px', height: '26px' }"></FileTypeImg>
|
||||
<div class="sharedocname">{{ value.name }}</div>
|
||||
<div class="download">
|
||||
<img src="../../assets/image/download.png" style="width: 16px; height: 15px" />
|
||||
<img src="../../assets/image/download.png" style="width: 16px; height: 15px"/>
|
||||
<div style="margin-left: 7px" @click="downloadFile(value.response.data)">下载</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -145,13 +147,13 @@
|
||||
<div class="detailRB">
|
||||
<div class="info">
|
||||
<div class="title">
|
||||
<img style="width: 21px; height: 20px" src="../../assets/image/pathdetails/info.png" />
|
||||
<img style="width: 21px; height: 20px" src="../../assets/image/pathdetails/info.png"/>
|
||||
<div class="text" style="margin-left: 7px">个人信息</div>
|
||||
<div class="box"></div>
|
||||
</div>
|
||||
<!-- todo #路径详情 个人信息缺少img和介绍-->
|
||||
<div class="teacheritem" :style="{ 'border-bottom': '1px solid rgba(56, 125, 247, 0.2)' }">
|
||||
<img class="peopleimg" :src="userInfo?.avatar" />
|
||||
<img class="peopleimg" :src="userInfo?.avatar"/>
|
||||
<div style="margin-left: 17px">
|
||||
<div class="teacherName">
|
||||
<div style="margin-right: 5px">
|
||||
@@ -167,7 +169,7 @@
|
||||
</div>
|
||||
<div class="info" style="padding-top: 20px">
|
||||
<div class="title">
|
||||
<img style="width: 18px; height: 17px" src="../../assets/image/pathdetails/study.png" />
|
||||
<img style="width: 18px; height: 17px" src="../../assets/image/pathdetails/study.png"/>
|
||||
<div class="text" style="margin-left: 9px">学习进度</div>
|
||||
<div class="box"></div>
|
||||
</div>
|
||||
@@ -184,7 +186,7 @@
|
||||
<div class="progress">
|
||||
<div style="width: 291px">
|
||||
<el-progress
|
||||
:percentage="parseInt((data.currentChapterCnt ? data.currentChapterCnt : 0 / data.totalChapterCnt ? data.totalChapterCn : 0) * 100)"
|
||||
:percentage="parseInt((data.currentChapterCnt || 0) / (data.totalChapterCnt || 1) * 100)"
|
||||
:show-text="false" :stroke-width="8" :color="
|
||||
{
|
||||
0: 'rgba(238, 112, 108, 1)',
|
||||
@@ -193,8 +195,8 @@
|
||||
3: 'rgba(59, 94, 251, 1)',
|
||||
4: 'rgba(57, 219, 183, 1)',
|
||||
5: 'rgba(57, 219, 183, 1)',
|
||||
}[(parseInt(data.currentChapterCnt ? data.currentChapterCnt : 0 / data.totalChapterCnt ? data.totalChapterCnt : 0) * 100) / 20]
|
||||
" />
|
||||
}[parseInt((data.currentChapterCnt || 0) / (data.totalChapterCnt || 1) * 100) / 20]
|
||||
"/>
|
||||
</div>
|
||||
<div style="font-size: 14px; font-weight: 500; margin-left: 10px" :style="{
|
||||
color: {
|
||||
@@ -204,12 +206,9 @@
|
||||
3: 'rgba(59, 94, 251, 1)',
|
||||
4: 'rgba(57, 219, 183, 1)',
|
||||
5: 'rgba(57, 219, 183, 1)',
|
||||
}[parseInt(((data.currentChapterCnt ? data.currentChapterCnt : 0 / data.totalChapterCnt ? data.totalChapterCnt : 0) * 100) / 20)],
|
||||
}[parseInt((data.currentChapterCnt || 0) / (data.totalChapterCnt || 1) * 100) / 20],
|
||||
}">
|
||||
{{ parseInt((data.currentChapterCnt ? data.currentChapterCnt : 0 /
|
||||
data.totalChapterCnt ? data.totalChapterCnt : 0) > 1 ? 1 : (data.currentChapterCnt ?
|
||||
data.currentChapterCnt : 0 /
|
||||
data.totalChapterCnt ? data.totalChapterCnt : 0) * 100) }}%
|
||||
{{ parseInt((data.currentChapterCnt || 0) / (data.totalChapterCnt || 1) * 100) }}%
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -220,7 +219,7 @@
|
||||
<div class="progress">
|
||||
<div style="width: 291px">
|
||||
<el-progress
|
||||
:percentage="parseInt((data.currentReqCnt ? data.currentReqCnt : 0 / data.totalReqCnt ? data.totalReqCnt : 0) * 100)"
|
||||
:percentage="parseInt((((data.currentReqCnt || 0) / (data.totalReqCnt || 1)) * 100) / 20)"
|
||||
:show-text="false" :stroke-width="8" :color="
|
||||
{
|
||||
0: 'rgba(238, 112, 108, 1)',
|
||||
@@ -229,8 +228,8 @@
|
||||
3: 'rgba(59, 94, 251, 1)',
|
||||
4: 'rgba(57, 219, 183, 1)',
|
||||
5: 'rgba(57, 219, 183, 1)',
|
||||
}[parseInt(((data.currentReqCnt ? data.currentReqCnt : 0 / data.totalReqCnt ? data.totalReqCnt : 0) * 100) / 20)]
|
||||
" />
|
||||
}[parseInt((((data.currentReqCnt || 0) / (data.totalReqCnt || 1)) * 100) / 20)]
|
||||
"/>
|
||||
</div>
|
||||
<div style="
|
||||
font-size: 14px;
|
||||
@@ -245,11 +244,9 @@
|
||||
3: 'rgba(59, 94, 251, 1)',
|
||||
4: 'rgba(57, 219, 183, 1)',
|
||||
5: 'rgba(57, 219, 183, 1)',
|
||||
}[parseInt(((data.currentReqCnt ? data.currentReqCnt : 0 / data.totalReqCnt ? data.totalReqCnt : 0) * 100) / 20)],
|
||||
}[parseInt((((data.currentReqCnt || 0) / (data.totalReqCnt || 1)) * 100) / 20)],
|
||||
}">
|
||||
{{ parseInt((data.currentReqCnt ? data.currentReqCnt : 0 / data.totalReqCnt ? data.totalReqCnt :
|
||||
0) > 1 ? 1 : (data.currentReqCnt ? data.currentReqCnt : 0 / data.totalReqCnt ? data.totalReqCnt : 0) *
|
||||
100) }}%
|
||||
{{ parseInt((data.currentReqCnt || 0) / (data.totalReqCnt || 1) * 100) }}%
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -262,8 +259,8 @@
|
||||
<!-- 详细信息 -->
|
||||
<!-- 弹框提示信息 -->
|
||||
<el-dialog title="" top="347px" v-model="dialogVisible" :show-close="false"
|
||||
style="display:flex;justify-content:center;align-items:center;height: 283px;padding:0;border-radius: 4px;"
|
||||
width="502px">
|
||||
style="display:flex;justify-content:center;align-items:center;height: 283px;padding:0;border-radius: 4px;"
|
||||
width="502px">
|
||||
<div style="width:288px;color:#333333;font-size: 22px;font-weight: 600;">{{ dialogVisibleTip }}</div>
|
||||
<span slot="footer" style="display:inline-block;margin-top:60px;">
|
||||
<el-button @click="dialogVisible = false" style="width:140px;height:40px;margin-right: 22px;">取消</el-button>
|
||||
@@ -274,16 +271,22 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { computed, onMounted, ref } from "vue";
|
||||
import circle from '@/assets/image/pathdetails/circle.png';
|
||||
import circle2 from '@/assets/image/pathdetails/circle2.png';
|
||||
import { request } from "@/api/request";
|
||||
import { STUDY_RECORD, UPDATE_CURRENT_TASK, QueryEvaluationTaskStatusOne, EvaluationToLearn, SubmitExternalExam } from "@/api/api";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import { ElMessage } from "element-plus";
|
||||
import { ROUTER, TASK_TYPES } from "@/api/CONST";
|
||||
import {computed, onMounted, ref} from "vue";
|
||||
import circle from "@/assets/image/pathdetails/circle.png";
|
||||
import circle2 from "@/assets/image/pathdetails/circle2.png";
|
||||
import {request} from "@/api/request";
|
||||
import {
|
||||
STUDY_RECORD,
|
||||
UPDATE_CURRENT_TASK,
|
||||
QueryEvaluationTaskStatusOne,
|
||||
EvaluationToLearn,
|
||||
SubmitExternalExam
|
||||
} from "@/api/api";
|
||||
import {useRoute, useRouter} from "vue-router";
|
||||
import {ElMessage} from "element-plus";
|
||||
import {ROUTER, TASK_TYPES} from "@/api/CONST";
|
||||
import FileTypeImg from "@/components/FileTypeImg.vue";
|
||||
import { useStore } from "vuex";
|
||||
import {useStore} from "vuex";
|
||||
|
||||
const {
|
||||
query: { routerId, routerName },
|
||||
@@ -293,15 +296,15 @@ const returnclick = () => {
|
||||
router.back();
|
||||
};
|
||||
|
||||
const { commit, dispatch, state } = useStore()
|
||||
const userInfo = computed(() => state.userInfo)
|
||||
const data = computed(() => state.routerInfo)
|
||||
console.log(data)
|
||||
const { commit, dispatch, state } = useStore();
|
||||
const userInfo = computed(() => state.userInfo);
|
||||
const data = computed(() => state.routerInfo);
|
||||
console.log(data);
|
||||
const activeName = ref("first");
|
||||
|
||||
onMounted(() => {
|
||||
dispatch('getRouterInfo', { routerId })
|
||||
})
|
||||
dispatch("getRouterInfo", { routerId });
|
||||
});
|
||||
|
||||
const handleClick = (tab, event) => {
|
||||
console.log(tab, event);
|
||||
@@ -309,7 +312,7 @@ const handleClick = (tab, event) => {
|
||||
const path = { 1: "path" };
|
||||
|
||||
const dialogVisible = ref(false);
|
||||
const dialogVisibleTip = ref('');
|
||||
const dialogVisibleTip = ref("");
|
||||
|
||||
// 判断当前任务已结束及时间意义上的结束 提示用户
|
||||
function judgeTaskIsEnd(type, endTimes, status) {
|
||||
@@ -340,12 +343,12 @@ function judgeTaskIsEnd(type, endTimes, status) {
|
||||
|
||||
async function toFinish(d) {
|
||||
if (data.value.unlockMode !== 1 && !d.statusName) {
|
||||
ElMessage.warning("当前未解锁")
|
||||
return
|
||||
ElMessage.warning("当前未解锁");
|
||||
return;
|
||||
}
|
||||
if (data.value.endTime && judgeTaskIsEnd(d.type, data.value.endTime, data.value.status)) {
|
||||
ElMessage.error("当前任务已结束")
|
||||
return
|
||||
ElMessage.error("当前任务已结束");
|
||||
return;
|
||||
}
|
||||
|
||||
if (!TASK_TYPES.path[d.type]) {
|
||||
@@ -356,7 +359,7 @@ async function toFinish(d) {
|
||||
let date1 = new Date(d.endTime).getTime();
|
||||
let date2 = new Date().getTime();
|
||||
if (date1 < date2) {
|
||||
dialogVisibleTip.value = '当前面授课已结束';
|
||||
dialogVisibleTip.value = "当前面授课已结束";
|
||||
dialogVisible.value = true;
|
||||
|
||||
//return
|
||||
@@ -366,7 +369,7 @@ async function toFinish(d) {
|
||||
let date1 = new Date(d.endTime).getTime();
|
||||
let date2 = new Date().getTime();
|
||||
if (date1 < date2) {
|
||||
dialogVisibleTip.value = '当前作业已结束';
|
||||
dialogVisibleTip.value = "当前作业已结束";
|
||||
dialogVisible.value = true;
|
||||
|
||||
//return
|
||||
@@ -377,7 +380,7 @@ async function toFinish(d) {
|
||||
let date1 = new Date(d.endTime).getTime();
|
||||
let date2 = new Date().getTime();
|
||||
if (date1 < date2) {
|
||||
dialogVisibleTip.value = '当前直播已结束';
|
||||
dialogVisibleTip.value = "当前直播已结束";
|
||||
dialogVisible.value = true;
|
||||
//return
|
||||
}
|
||||
@@ -386,9 +389,9 @@ async function toFinish(d) {
|
||||
if (d.type == 5) {
|
||||
if (d.taskStatus == 1 || d.taskStatus == 2) {
|
||||
// ElMessage.error("该任务无法学习,请联系管理员进行替换。")
|
||||
dialogVisibleTip.value = '该任务无法学习,请联系管理员进行替换!';
|
||||
dialogVisibleTip.value = "该任务无法学习,请联系管理员进行替换!";
|
||||
dialogVisible.value = true;
|
||||
return
|
||||
return;
|
||||
}
|
||||
|
||||
// 此处判断外部考试跳转
|
||||
@@ -403,13 +406,13 @@ async function toFinish(d) {
|
||||
"targetId": routerId,
|
||||
"studentNo": userInfo.value.userNo
|
||||
}).then(res => {
|
||||
console.log(res)
|
||||
console.log(res);
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
})
|
||||
console.log(err);
|
||||
});
|
||||
|
||||
router.push({
|
||||
path: '/externalexamination',
|
||||
path: "/externalexamination",
|
||||
query: {
|
||||
id: d.id,
|
||||
type: ROUTER,
|
||||
@@ -421,16 +424,16 @@ async function toFinish(d) {
|
||||
exname: d.name, // 考试名称
|
||||
},
|
||||
});
|
||||
return
|
||||
return;
|
||||
}
|
||||
}
|
||||
// 评估 停用
|
||||
if (d.type == 11) {
|
||||
if (d.taskStatus == 1 || d.taskStatus == 2) {
|
||||
// ElMessage.error("该任务无法学习,请联系管理员进行替换。")
|
||||
dialogVisibleTip.value = '该任务无法学习,请联系管理员进行替换!';
|
||||
dialogVisibleTip.value = "该任务无法学习,请联系管理员进行替换!";
|
||||
dialogVisible.value = true;
|
||||
return
|
||||
return;
|
||||
}
|
||||
}
|
||||
// 其他活动 结束时间
|
||||
@@ -438,7 +441,7 @@ async function toFinish(d) {
|
||||
let date1 = new Date(d.endTime).getTime();
|
||||
let date2 = new Date().getTime();
|
||||
if (date1 < date2) {
|
||||
dialogVisibleTip.value = '当前活动已结束';
|
||||
dialogVisibleTip.value = "当前活动已结束";
|
||||
dialogVisible.value = true;
|
||||
//return
|
||||
}
|
||||
@@ -447,24 +450,24 @@ async function toFinish(d) {
|
||||
if (d.type == 1) {
|
||||
if (d.taskStatus == 1 || d.taskStatus == 2) {
|
||||
// ElMessage.error("该任务无法学习,请联系管理员进行替换。")
|
||||
dialogVisibleTip.value = '该任务无法学习,请联系管理员进行替换!';
|
||||
dialogVisibleTip.value = "该任务无法学习,请联系管理员进行替换!";
|
||||
dialogVisible.value = true;
|
||||
return
|
||||
return;
|
||||
}
|
||||
}
|
||||
// 面授课 停用
|
||||
if (d.type == 2) {
|
||||
if (d.taskStatus == 1 || d.taskStatus == 2) {
|
||||
// ElMessage.error("该任务无法学习,请联系管理员进行替换。")
|
||||
dialogVisibleTip.value = '该任务无法学习,请联系管理员进行替换!';
|
||||
dialogVisibleTip.value = "该任务无法学习,请联系管理员进行替换!";
|
||||
dialogVisible.value = true;
|
||||
return
|
||||
return;
|
||||
}
|
||||
}
|
||||
//更新学员当前任务
|
||||
await request(UPDATE_CURRENT_TASK, { id: d.id, type: ROUTER, pid: routerId, name: d.name })
|
||||
await request(UPDATE_CURRENT_TASK, { id: d.id, type: ROUTER, pid: routerId, name: d.name });
|
||||
if (d.type === 3 || d.type === 7 || (d.type === 5 && d.examType === 2)) {
|
||||
console.log(d, data.value)
|
||||
console.log(d, data.value);
|
||||
d.status !== 1 && await request(STUDY_RECORD, {
|
||||
studentId: userInfo.value.id,
|
||||
targetId: data.value.id,
|
||||
@@ -480,7 +483,7 @@ async function toFinish(d) {
|
||||
if (d.quizTaskId == null) {
|
||||
// 肯定没有完成测评
|
||||
// 调用接口 跳转页面
|
||||
console.log('我是查询测评跳转链接所传递得参数', {
|
||||
console.log("我是查询测评跳转链接所传递得参数", {
|
||||
"businessType": "learningpath",
|
||||
"chapterId": data.value.currentStageId,
|
||||
"courseId": d.courseId,
|
||||
@@ -488,7 +491,7 @@ async function toFinish(d) {
|
||||
"routerOrProjectId": routerId,
|
||||
"studentId": userInfo.value.id,
|
||||
"studentName": userInfo.value.realName
|
||||
})
|
||||
});
|
||||
request(EvaluationToLearn, {
|
||||
"businessType": "learningpath",
|
||||
"chapterId": data.value.currentStageId,
|
||||
@@ -498,34 +501,34 @@ async function toFinish(d) {
|
||||
"studentId": userInfo.value.id,
|
||||
"studentName": userInfo.value.realName
|
||||
}).then(res => {
|
||||
console.log(res)
|
||||
console.log(res);
|
||||
if (res.code == 200) {
|
||||
let jumpUrl = res.data.quizUrl
|
||||
let jumpUrl = res.data.quizUrl;
|
||||
// 此处写跳转url
|
||||
window.open(jumpUrl, '_top')
|
||||
window.open(jumpUrl, "_top");
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
})
|
||||
return
|
||||
console.log(err);
|
||||
});
|
||||
return;
|
||||
} else {
|
||||
// 进行中 或者 已完成
|
||||
// 调用接口 判断当前测评状态 跳转页面
|
||||
console.log('我是查询测评跳转链接所传递得参数', {
|
||||
console.log("我是查询测评跳转链接所传递得参数", {
|
||||
"quizTaskId": d.quizTaskId
|
||||
})
|
||||
});
|
||||
request(QueryEvaluationTaskStatusOne, {
|
||||
"quizTaskId": d.quizTaskId
|
||||
}).then(res => {
|
||||
console.log(res)
|
||||
console.log(res);
|
||||
if (res.code == 200) {
|
||||
if (res.data.complete_status == 2) {
|
||||
ElMessage.error("您已完成测评")
|
||||
return
|
||||
ElMessage.error("您已完成测评");
|
||||
return;
|
||||
} else {
|
||||
// 重新查询跳转
|
||||
// 调用接口 跳转页面
|
||||
console.log('我是查询测评跳转链接所传递得参数', {
|
||||
console.log("我是查询测评跳转链接所传递得参数", {
|
||||
"businessType": "learningpath",
|
||||
"chapterId": data.value.currentStageId,
|
||||
"courseId": d.courseId,
|
||||
@@ -533,7 +536,7 @@ async function toFinish(d) {
|
||||
"routerOrProjectId": routerId,
|
||||
"studentId": userInfo.value.id,
|
||||
"studentName": userInfo.value.realName
|
||||
})
|
||||
});
|
||||
request(EvaluationToLearn, {
|
||||
"businessType": "learningpath",
|
||||
"chapterId": data.value.currentStageId,
|
||||
@@ -543,22 +546,22 @@ async function toFinish(d) {
|
||||
"studentId": userInfo.value.id,
|
||||
"studentName": userInfo.value.realName
|
||||
}).then(res => {
|
||||
console.log(res)
|
||||
console.log(res);
|
||||
if (res.code == 200) {
|
||||
let jumpUrl = res.data.quizUrl
|
||||
let jumpUrl = res.data.quizUrl;
|
||||
// 此处写跳转url
|
||||
window.open(jumpUrl, '_top')
|
||||
window.open(jumpUrl, "_top");
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
})
|
||||
return
|
||||
console.log(err);
|
||||
});
|
||||
return;
|
||||
}
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
})
|
||||
return
|
||||
console.log(err);
|
||||
});
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -566,15 +569,15 @@ async function toFinish(d) {
|
||||
if (d.type == 13) {
|
||||
// 此处判断跳转项目详情界面
|
||||
router.push({
|
||||
path: '/projectdetails',
|
||||
path: "/projectdetails",
|
||||
query: {
|
||||
projectId: d.courseId
|
||||
},
|
||||
});
|
||||
return
|
||||
return;
|
||||
}
|
||||
const path = typeof TASK_TYPES.path[d.type] === "string" ? TASK_TYPES.path[d.type] : TASK_TYPES.path[d.type](d);
|
||||
path && path.startsWith("http") ? window.open(path + d.targetId, '_top') : path.startsWith("/") ?
|
||||
path && path.startsWith("http") ? window.open(path + d.targetId, "_top") : path.startsWith("/") ?
|
||||
router.push({
|
||||
path,
|
||||
query: {
|
||||
@@ -587,33 +590,32 @@ async function toFinish(d) {
|
||||
chapterOrStageId: data.value.currentStageId,
|
||||
btype: 2
|
||||
},
|
||||
}) : ''
|
||||
}) : "";
|
||||
|
||||
}
|
||||
|
||||
|
||||
function whiteTypes(type) {
|
||||
return import.meta.env.VITE_TASK_WHITE_TYPE.includes("-" + type + "-");
|
||||
}
|
||||
|
||||
// 共享文档下载
|
||||
function downloadFile(url) {
|
||||
console.log(import.meta.env.VITE_FILE_PATH + url)
|
||||
console.log(import.meta.env.VITE_FILE_PATH + url);
|
||||
window.open(import.meta.env.VITE_FILE_PATH + url);
|
||||
}
|
||||
|
||||
// 继续学习
|
||||
function continueLearn(taskname, datas) {
|
||||
console.log('我是当前的列表展示信息', data)
|
||||
console.log(datas)
|
||||
let jumpinfo
|
||||
console.log("我是当前的列表展示信息", data);
|
||||
console.log(datas);
|
||||
let jumpinfo;
|
||||
for (let i = 0; i < datas.length; i++) {
|
||||
if (datas[i].name == taskname) {
|
||||
jumpinfo = datas[i]
|
||||
jumpinfo = datas[i];
|
||||
}
|
||||
}
|
||||
console.log(jumpinfo)
|
||||
toFinish(jumpinfo)
|
||||
console.log(jumpinfo);
|
||||
toFinish(jumpinfo);
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user