mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-student.git
synced 2025-12-11 20:06:49 +08:00
fix:增加项目列表
This commit is contained in:
@@ -116,7 +116,7 @@
|
||||
:style="{
|
||||
background: `${types.path[value.type] ? '#2478ff' : '#999'}`,
|
||||
}"
|
||||
@click="toFinish(value, i.chapterName)"
|
||||
@click="toFinish(value, i.chapterName, i.chapterId)"
|
||||
>
|
||||
{{
|
||||
value.status === 1
|
||||
@@ -329,7 +329,7 @@ import medal2 from "@/assets/image/medal/medal2.png";
|
||||
import medal3 from "@/assets/image/medal/medal3.png";
|
||||
import img from "@/assets/image/uploadimg.png";
|
||||
import { boeRequest, useRequest, request } from "@/api/request";
|
||||
import { ROUTER_PROCESS, LINK_DETAILS } from "@/api/api";
|
||||
import { ROUTER_PROCESS, LINK_DETAILS, STUDY_RECORD } from "@/api/api";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import { ElMessage } from "element-plus";
|
||||
import { useUserInfo } from "@/api/utils";
|
||||
@@ -345,7 +345,7 @@ const returnclick = () => {
|
||||
const { data } = useRequest(ROUTER_PROCESS, { routerId });
|
||||
console.log("data", data);
|
||||
const userInfo = computed(() => store.state.userInfo);
|
||||
|
||||
console.log("userInfo", userInfo);
|
||||
const activeName = ref("first");
|
||||
|
||||
const handleClick = (tab, event) => {
|
||||
@@ -409,14 +409,23 @@ const types = ref({
|
||||
},
|
||||
});
|
||||
|
||||
function toFinish(d, sName) {
|
||||
function toFinish(d, sName, chapterId) {
|
||||
if (!types.value.path[d.type]) {
|
||||
ElMessage.error("暂时未开放");
|
||||
return;
|
||||
}
|
||||
|
||||
if (d.type == 3 || d.type == 7) {
|
||||
request(STUDY_RECORD, {
|
||||
studentId: data.value.userInfoBo.userId,
|
||||
targetId: data.value.routerId,
|
||||
logo: 1,
|
||||
stageOrChapterId: chapterId,
|
||||
taskId: d.routerTaskId,
|
||||
});
|
||||
}
|
||||
if (typeof types.value.path[d.type] === "string") {
|
||||
// console.log("dddddd", d);
|
||||
console.log("dddddd", d);
|
||||
|
||||
types.value.path[d.type] &&
|
||||
types.value.path[d.type].startsWith("http") &&
|
||||
window.open(types.value.path[d.type] + d.targetId);
|
||||
|
||||
Reference in New Issue
Block a user