mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/student-h5.git
synced 2025-12-06 09:26:46 +08:00
Merge branch 'dev0731'
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="faceteach">
|
||||
<ReturnHead text="课程详情" :gohome="true"></ReturnHead>
|
||||
<TitleHead :text="'【面授课】' + data.planDto?.name"></TitleHead>
|
||||
<ReturnHead text="课程详情1" :gohome="true"></ReturnHead>
|
||||
<TitleHead :text="'【面授课】1' + data.planDto?.name"></TitleHead>
|
||||
<div class="main">
|
||||
<div class="title">
|
||||
<div class="titlemain">
|
||||
@@ -108,12 +108,12 @@
|
||||
<div class="talk">面授课讲师</div>
|
||||
<div class="box" style="width: 80px; right: 0px"></div>
|
||||
</div>
|
||||
<div class="teachermain">
|
||||
<img class="teacherAvatar" :src="teacherInfo?.avatar"/>
|
||||
<div class="teachermain" v-for="item in teacherItem">
|
||||
<img class="teacherAvatar" :src="item?.avatar" />
|
||||
<div style="flex: 1; margin-left: 11px; margin-right: 13px">
|
||||
<div class="teacherName">{{ data.planDto?.teacher }}</div>
|
||||
<div class="teacherName">{{ item?.realName }}</div>
|
||||
<div class="teacherIntro">
|
||||
{{ data.planDto?.bandDesc }}
|
||||
{{ useOrgName(item?.orgNamePath) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -126,7 +126,7 @@
|
||||
style="width: 17px; height: 17px"
|
||||
src="../../assets/image/faceteach/livelecturer.png"
|
||||
/>
|
||||
<div class="talk">课程详情</div>
|
||||
<div class="talk">课程详情1</div>
|
||||
<div class="box"></div>
|
||||
</div>
|
||||
<div class="detailMain">
|
||||
@@ -346,16 +346,17 @@
|
||||
<script setup>
|
||||
import TitleHead from "@/components/TitleHead.vue";
|
||||
import ReturnHead from "@/components/ReturnHead.vue";
|
||||
import {computed, onBeforeMount, ref} from "vue";
|
||||
import {computed, onBeforeMount, ref,watch} from "vue";
|
||||
import FileTypeImg from "@/components/FileTypeImg.vue";
|
||||
import {request, useRequest} from "@/api/request";
|
||||
import {request, useRequest,boeRequest} from "@/api/request";
|
||||
import {STU_OFFCOURSE_DETAIL, TASK_OFFCOURSE_NOTASK_SIGN,} from "@/api/api";
|
||||
import {useRoute, useRouter} from "vue-router";
|
||||
import {useUserInfo} from "@/api/utils";
|
||||
import {ElMessage} from "element-plus";
|
||||
import dayjs from "dayjs";
|
||||
import isBetween from "dayjs/plugin/isBetween";
|
||||
|
||||
import { GET_USER_INFO_OLDURL} from "@/api/ThirdApi";
|
||||
import { useOrgName } from "@/hooks/useOrgName.js";
|
||||
const router = useRouter();
|
||||
onBeforeMount(() => dayjs.extend(isBetween));
|
||||
const returnclick = () => {
|
||||
@@ -366,7 +367,29 @@ const {
|
||||
} = useRoute();
|
||||
|
||||
const { data } = useRequest(STU_OFFCOURSE_DETAIL, { courseId,usePermission:true });
|
||||
|
||||
const teacherItem = ref([])
|
||||
watch(() => data.value, (val) => {
|
||||
const teacherIds = val?.planDto?.offteachers?.map(item=>item.teacherId)
|
||||
const teacherLists = []
|
||||
teacherIds.map(item=>{
|
||||
teacherLists.push(boeRequest(GET_USER_INFO_OLDURL,{ userId: item }))
|
||||
})
|
||||
Promise.all(teacherLists).then(responses => {
|
||||
responses.map((arr)=>{
|
||||
const userInfo = arr.result;
|
||||
userInfo.avatar = userInfo?.avatar
|
||||
? userInfo?.avatar.includes('upload')
|
||||
? userInfo?.avatar
|
||||
: '/upload' + userInfo?.avatar
|
||||
: '/800e23f7-b58c-4192-820d-0c6a2b7544cc.png';
|
||||
const index = teacherIds.indexOf(userInfo.userId)
|
||||
userInfo.realName = val.planDto.offteachers[index]?.teacherName
|
||||
teacherItem.value.push(userInfo)
|
||||
})
|
||||
}).catch(error => {
|
||||
console.log(error)
|
||||
})
|
||||
});
|
||||
const teacherInfo = useUserInfo(computed(() => data.value?.planDto?.teacherId));
|
||||
const isAllowSign = computed(() => dayjs().isBetween(dayjs(data.value.planDto?.beginTime).subtract(data.value.planDto?.beforeStart || 0, "minute"), dayjs(data.value.planDto?.afterStart ? data.value.planDto?.beginTime : data.value.planDto?.endTime).add(data.value.planDto?.afterStart || 0, "minute")));
|
||||
|
||||
|
||||
@@ -49,12 +49,12 @@
|
||||
<div class="talk">面授课讲师</div>
|
||||
<div class="box" style="width: 80px; right: 0px"></div>
|
||||
</div>
|
||||
<div class="teachermain">
|
||||
<img class="teacherAvatar" :src="teacherInfo?.avatar" />
|
||||
<div class="teachermain" v-for="item in teacherItem">
|
||||
<img class="teacherAvatar" :src="item?.avatar" />
|
||||
<div style="flex: 1; margin-left: 11px; margin-right: 13px">
|
||||
<div class="teacherName">{{ data.planDto?.teacher }}</div>
|
||||
<div class="teacherName">{{ item?.realName }}</div>
|
||||
<div class="teacherIntro">
|
||||
{{ data.planDto?.bandDesc }}
|
||||
{{ useOrgName(item?.orgNamePath) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -147,15 +147,16 @@
|
||||
|
||||
<script setup>
|
||||
import ReturnHead from "@/components/ReturnHead.vue";
|
||||
import {computed, ref,} from "vue";
|
||||
import {computed, ref,watch} from "vue";
|
||||
import FileTypeImg from "@/components/FileTypeImg.vue";
|
||||
import {request, useRequest} from "@/api/request";
|
||||
import {request, useRequest,boeRequest} from "@/api/request";
|
||||
import {FACETEACH_SIGNUP, STU_OFFCOURSE_DETAIL} from "@/api/api";
|
||||
import {useRoute, useRouter} from "vue-router";
|
||||
import {useUserInfo} from "@/api/utils";
|
||||
import {ElLoading, ElMessage} from "element-plus";
|
||||
import dayjs from "dayjs";
|
||||
|
||||
import { GET_USER_INFO_OLDURL} from "@/api/ThirdApi";
|
||||
import { useOrgName } from "@/hooks/useOrgName.js";
|
||||
const router = useRouter();
|
||||
const returnclick = () => {
|
||||
router.back();
|
||||
@@ -176,6 +177,29 @@ const closeLoading = () => {
|
||||
loading.value.close();
|
||||
};
|
||||
const { data } = useRequest(STU_OFFCOURSE_DETAIL, { courseId }, () => closeLoading());
|
||||
const teacherItem = ref([])
|
||||
watch(() => data.value, (val) => {
|
||||
const teacherIds = val?.planDto?.offteachers?.map(item=>item.teacherId)
|
||||
const teacherLists = []
|
||||
teacherIds.map(item=>{
|
||||
teacherLists.push(boeRequest(GET_USER_INFO_OLDURL,{ userId: item }))
|
||||
})
|
||||
Promise.all(teacherLists).then(responses => {
|
||||
responses.map((arr)=>{
|
||||
const userInfo = arr.result;
|
||||
userInfo.avatar = userInfo?.avatar
|
||||
? userInfo?.avatar.includes('upload')
|
||||
? userInfo?.avatar
|
||||
: '/upload' + userInfo?.avatar
|
||||
: '/800e23f7-b58c-4192-820d-0c6a2b7544cc.png';
|
||||
const index = teacherIds.indexOf(userInfo.userId)
|
||||
userInfo.realName = val.planDto.offteachers[index]?.teacherName
|
||||
teacherItem.value.push(userInfo)
|
||||
})
|
||||
}).catch(error => {
|
||||
console.log(error)
|
||||
})
|
||||
});
|
||||
const teacherInfo = useUserInfo(computed(() => data.value?.planDto?.teacherId));
|
||||
|
||||
const activeName = ref("first");
|
||||
|
||||
@@ -54,12 +54,12 @@
|
||||
<div class="talk">面授课讲师</div>
|
||||
<div class="box" style="width: 80px; right: 0px"></div>
|
||||
</div>
|
||||
<div class="teachermain">
|
||||
<img class="teacherAvatar" :src="teacherInfo?.avatar" />
|
||||
<div class="teachermain" v-for="item in teacherItem">
|
||||
<img class="teacherAvatar" :src="item?.avatar" />
|
||||
<div style="flex: 1; margin-left: 11px; margin-right: 13px">
|
||||
<div class="teacherName">{{ data.planDto?.teacher }}</div>
|
||||
<div class="teacherName">{{ item?.realName }}</div>
|
||||
<div class="teacherIntro">
|
||||
{{ data.planDto?.bandDesc }}
|
||||
{{ useOrgName(item?.orgNamePath) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -153,15 +153,16 @@
|
||||
|
||||
<script setup>
|
||||
import ReturnHead from "@/components/ReturnHead.vue";
|
||||
import {computed, ref} from "vue";
|
||||
import {computed, ref,watch} from "vue";
|
||||
import FileTypeImg from "@/components/FileTypeImg.vue";
|
||||
import {request, useRequest} from "@/api/request";
|
||||
import {request, useRequest,boeRequest} from "@/api/request";
|
||||
import {FACETEACH_SIGNUP, STU_OFFCOURSE_DETAIL} from "@/api/api";
|
||||
import {useRoute, useRouter} from "vue-router";
|
||||
import {useUserInfo} from "@/api/utils";
|
||||
import {ElLoading, ElMessage} from "element-plus";
|
||||
import dayjs from "dayjs";
|
||||
|
||||
import { GET_USER_INFO_OLDURL} from "@/api/ThirdApi";
|
||||
import { useOrgName } from "@/hooks/useOrgName.js";
|
||||
const router = useRouter();
|
||||
const returnclick = () => {
|
||||
router.back();
|
||||
@@ -180,7 +181,29 @@ const openLoading = () => {
|
||||
openLoading();
|
||||
const closeLoading = () => loading.value.close();
|
||||
const { data } = useRequest(STU_OFFCOURSE_DETAIL, { courseId }, () => closeLoading());
|
||||
|
||||
const teacherItem = ref([])
|
||||
watch(() => data.value, (val) => {
|
||||
const teacherIds = val?.planDto?.offteachers?.map(item=>item.teacherId)
|
||||
const teacherLists = []
|
||||
teacherIds.map(item=>{
|
||||
teacherLists.push(boeRequest(GET_USER_INFO_OLDURL,{ userId: item }))
|
||||
})
|
||||
Promise.all(teacherLists).then(responses => {
|
||||
responses.map((arr)=>{
|
||||
const userInfo = arr.result;
|
||||
userInfo.avatar = userInfo?.avatar
|
||||
? userInfo?.avatar.includes('upload')
|
||||
? userInfo?.avatar
|
||||
: '/upload' + userInfo?.avatar
|
||||
: '/800e23f7-b58c-4192-820d-0c6a2b7544cc.png';
|
||||
const index = teacherIds.indexOf(userInfo.userId)
|
||||
userInfo.realName = val.planDto.offteachers[index]?.teacherName
|
||||
teacherItem.value.push(userInfo)
|
||||
})
|
||||
}).catch(error => {
|
||||
console.log(error)
|
||||
})
|
||||
});
|
||||
const teacherInfo = useUserInfo(computed(() => data.value?.planDto?.teacherId));
|
||||
const activeName = ref("first");
|
||||
|
||||
|
||||
@@ -81,12 +81,12 @@
|
||||
<div class="talk">面授课讲师</div>
|
||||
<div class="box" style="width: 80px; right: 0px"></div>
|
||||
</div>
|
||||
<div class="teachermain">
|
||||
<img class="teacherAvatar" :src="teacherInfo?.avatar" />
|
||||
<div class="teachermain" v-for="item in teacherItem">
|
||||
<img class="teacherAvatar" :src="item?.avatar" />
|
||||
<div style="flex: 1; margin-left: 11px; margin-right: 13px">
|
||||
<div class="teacherName">{{ data.planDto?.teacher }}</div>
|
||||
<div class="teacherName">{{ item?.realName }}</div>
|
||||
<div class="teacherIntro">
|
||||
{{ data.planDto?.bandDesc }}
|
||||
{{ useOrgName(item?.orgNamePath) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -183,9 +183,9 @@
|
||||
|
||||
<script setup>
|
||||
import ReturnHead from "@/components/ReturnHead.vue";
|
||||
import {computed, onBeforeMount, ref,} from "vue";
|
||||
import {computed, onBeforeMount, ref,watch} from "vue";
|
||||
import FileTypeImg from "@/components/FileTypeImg.vue";
|
||||
import {request, useRequest} from "@/api/request";
|
||||
import {request, useRequest,boeRequest} from "@/api/request";
|
||||
import {FACETEACH_SIGNUP, STU_OFFCOURSE_DETAIL} from "@/api/api";
|
||||
import {useRoute, useRouter} from "vue-router";
|
||||
import {useUserInfo} from "@/api/utils";
|
||||
@@ -193,7 +193,8 @@ import {ElLoading, ElMessage} from "element-plus";
|
||||
import CommentReply from "@/components/CommentReply.vue";
|
||||
import dayjs from "dayjs";
|
||||
import isBetween from "dayjs/plugin/isBetween";
|
||||
|
||||
import { GET_USER_INFO_OLDURL} from "@/api/ThirdApi";
|
||||
import { useOrgName } from "@/hooks/useOrgName.js";
|
||||
const router = useRouter();
|
||||
const returnclick = () => {
|
||||
router.back();
|
||||
@@ -215,6 +216,29 @@ const closeLoading = () => {
|
||||
loading.value.close();
|
||||
};
|
||||
const { data } = useRequest(STU_OFFCOURSE_DETAIL, { courseId }, () => closeLoading());
|
||||
const teacherItem = ref([])
|
||||
watch(() => data.value, (val) => {
|
||||
const teacherIds = val?.planDto?.offteachers?.map(item=>item.teacherId)
|
||||
const teacherLists = []
|
||||
teacherIds.map(item=>{
|
||||
teacherLists.push(boeRequest(GET_USER_INFO_OLDURL,{ userId: item }))
|
||||
})
|
||||
Promise.all(teacherLists).then(responses => {
|
||||
responses.map((arr)=>{
|
||||
const userInfo = arr.result;
|
||||
userInfo.avatar = userInfo?.avatar
|
||||
? userInfo?.avatar.includes('upload')
|
||||
? userInfo?.avatar
|
||||
: '/upload' + userInfo?.avatar
|
||||
: '/800e23f7-b58c-4192-820d-0c6a2b7544cc.png';
|
||||
const index = teacherIds.indexOf(userInfo.userId)
|
||||
userInfo.realName = val.planDto.offteachers[index]?.teacherName
|
||||
teacherItem.value.push(userInfo)
|
||||
})
|
||||
}).catch(error => {
|
||||
console.log(error)
|
||||
})
|
||||
});
|
||||
const isAllowSign = computed(() => dayjs().isBetween(dayjs(data.value?.planDto?.beginTime).subtract(data.value?.planDto?.beforeStart || 0, "minute"), dayjs(data.value?.planDto?.afterStart ? data.value?.planDto?.beginTime : data.value?.planDto?.endTime).add(data.value?.planDto?.afterStart || 0, "minute")));
|
||||
const teacherInfo = useUserInfo(computed(() => data.value?.planDto?.teacherId));
|
||||
const activeName = ref("first");
|
||||
|
||||
@@ -7,15 +7,30 @@
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
-->
|
||||
<template>
|
||||
<el-result icon="success" title="二维码已失效">
|
||||
<el-result icon="success" :title="title">
|
||||
<template #extra>
|
||||
<el-button type="primary" @click="toIndex">返回首页</el-button>
|
||||
</template>
|
||||
</el-result>
|
||||
</template>
|
||||
<script setup>
|
||||
import { toRefs,ref, onMounted } from "vue";
|
||||
import { useRoute } from "vue-router";
|
||||
|
||||
function toIndex() {
|
||||
window.location.href =
|
||||
window.location.protocol + import.meta.env.VITE_BOE_HOME;
|
||||
}
|
||||
const title = ref("二维码已失效");
|
||||
|
||||
onMounted(() => {
|
||||
// 接收跳转请求的query参数
|
||||
let route = useRoute();
|
||||
console.log("gx route.query.msg data",route.query.msg);
|
||||
console.log("gx route data",route);
|
||||
if (route.query.msg) {
|
||||
title.value = route.query.msg;
|
||||
}
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
35
src/views/nottask/LoseEfficacyProject.vue
Normal file
35
src/views/nottask/LoseEfficacyProject.vue
Normal file
@@ -0,0 +1,35 @@
|
||||
<!--
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2023-03-01 20:41:06
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2023-03-17 10:15:42
|
||||
* @FilePath: /stu_h5/src/views/nottask/LoseEfficacyProject.vue----只给项目用
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
-->
|
||||
<template>
|
||||
<el-result icon="success" :title="title">
|
||||
<template #extra>
|
||||
<el-button type="primary" @click="toIndex">返回首页</el-button>
|
||||
</template>
|
||||
</el-result>
|
||||
</template>
|
||||
<script setup>
|
||||
import { toRefs,ref, onMounted } from "vue";
|
||||
import { useRoute } from "vue-router";
|
||||
|
||||
function toIndex() {
|
||||
window.location.href =
|
||||
window.location.protocol + import.meta.env.VITE_BOE_HOME;
|
||||
}
|
||||
const title = ref("二维码已失效"); //搜索内容
|
||||
|
||||
onMounted(() => {
|
||||
// 接收跳转请求的query参数
|
||||
let route = useRoute();
|
||||
console.log("gx route.query.msg data",route.query.msg);
|
||||
console.log("gx route data",route);
|
||||
if (route.query.msg) {
|
||||
title.value = route.query.msg;
|
||||
}
|
||||
});
|
||||
</script>
|
||||
@@ -164,11 +164,41 @@
|
||||
<!-- <div class="goclass" @click="toFinish(el, item.stageName, item.id)" :style="{ background: el.statusName !== '已结束' &&(el.statusName || data.unlockMode === 1) ? '#2478ff' : '#999' }">
|
||||
{{el.statusName || (data.unlockMode === 1 ? TASK_TYPES.toName[el.type] : "未解锁")}}
|
||||
</div> -->
|
||||
<div v-if="data.unlockMode === 1" class="goclass" @click="toFinish(el, item.stageName, item.id, item.studyModel)" :style="{ background: (el.statusName !== '已结束' && (el.statusName || item.studyModel==0)) ? '#2478ff' : '#999' }">
|
||||
{{ el.statusName || (item.studyModel==0 ? TASK_TYPES.toName[el.type] : '未解锁')}}
|
||||
<div
|
||||
v-if="data.unlockMode === 1"
|
||||
class="goclass"
|
||||
@click="
|
||||
toFinish(el, item.stageName, item.id, item.studyModel)
|
||||
"
|
||||
:style="{
|
||||
background:
|
||||
el.statusName !== '已结束' &&
|
||||
(el.statusName || item.studyModel == 0)
|
||||
? '#2478ff'
|
||||
: '#999',
|
||||
}"
|
||||
>
|
||||
{{
|
||||
el.statusName ||
|
||||
(item.studyModel == 0
|
||||
? TASK_TYPES.toName[el.type]
|
||||
: "未解锁")
|
||||
}}
|
||||
</div>
|
||||
<div v-else class="goclass" @click="toFinish(el, item.stageName, item.id, item.studyModel)" :style="{ background: (el.statusName !== '已结束' && el.statusName) ? '#2478ff' : '#999' }">
|
||||
{{ el.statusName || '未解锁' }}
|
||||
<div
|
||||
v-else
|
||||
class="goclass"
|
||||
@click="
|
||||
toFinish(el, item.stageName, item.id, item.studyModel)
|
||||
"
|
||||
:style="{
|
||||
background:
|
||||
el.statusName !== '已结束' && el.statusName
|
||||
? '#2478ff'
|
||||
: '#999',
|
||||
}"
|
||||
>
|
||||
{{ el.statusName || "未解锁" }}
|
||||
</div>
|
||||
<!-- <template #dropdown v-if="el.type===2 && el.targetId?.split(',')?.length > 1">
|
||||
<el-dropdown-menu>
|
||||
@@ -176,8 +206,6 @@
|
||||
</el-dropdown-menu>
|
||||
</template> -->
|
||||
</el-dropdown>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -202,23 +230,82 @@
|
||||
</div> -->
|
||||
</div>
|
||||
<!-- 开课列表弹框 -->
|
||||
<el-dialog title="" top="120px" v-model="openCourseVisible" :show-close="false"
|
||||
style="display:flex;justify-content:center;align-items:center;min-height: 320px;padding:0;border-radius: 4px;"
|
||||
width="80%">
|
||||
<div style="display: flex;justify-content:space-between;align-items:center;margin-bottom: 22px;width: 100%;">
|
||||
<div style="width:88px;color:#333333;font-size: 16px;font-weight: 600;">开课列表</div>
|
||||
<el-dialog
|
||||
title=""
|
||||
top="120px"
|
||||
v-model="openCourseVisible"
|
||||
:show-close="false"
|
||||
style="
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
min-height: 320px;
|
||||
padding: 0;
|
||||
border-radius: 4px;
|
||||
"
|
||||
width="80%"
|
||||
>
|
||||
<div
|
||||
style="
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 22px;
|
||||
width: 100%;
|
||||
"
|
||||
>
|
||||
<div
|
||||
style="width: 88px; color: #333333; font-size: 16px; font-weight: 600"
|
||||
>
|
||||
开课列表
|
||||
</div>
|
||||
<div
|
||||
@click="openCourseVisible = false"
|
||||
style="font-size: 12px;cursor:pointer;">X</div>
|
||||
style="font-size: 12px; cursor: pointer"
|
||||
>
|
||||
X
|
||||
</div>
|
||||
</div>
|
||||
<div style="width: 100%;min-height:210px;margin-top: 12px;">
|
||||
<div
|
||||
v-for="item,key in openCourseList"
|
||||
style="width: 100%;display: flex;justify-content: space-between;align-items: center;margin-bottom: 12px;background: rgb(247, 251, 253);height: 40px;padding: 5px;border-radius: 5px;">
|
||||
<div style="overflow: hidden;white-space: nowrap;text-overflow: ellipsis;width: 200px;">{{ item }}</div>
|
||||
<div
|
||||
<div style="width: 100%; min-height: 210px; margin-top: 12px">
|
||||
<div
|
||||
v-for="(item, key) in openCourseList"
|
||||
style="
|
||||
width: 100%;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 12px;
|
||||
background: rgb(247, 251, 253);
|
||||
height: 40px;
|
||||
padding: 5px;
|
||||
border-radius: 5px;
|
||||
"
|
||||
>
|
||||
<div
|
||||
style="
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
width: 200px;
|
||||
"
|
||||
>
|
||||
{{ item }}
|
||||
</div>
|
||||
<div
|
||||
@click="toOffcoursePlanPage(openCourseIdList[key])"
|
||||
style="width:60px;height:30px;text-align:center;line-height:30px;background:#0078fc;border-radius:5px;color:#fff;cursor: pointer;">去上课</div>
|
||||
style="
|
||||
width: 60px;
|
||||
height: 30px;
|
||||
text-align: center;
|
||||
line-height: 30px;
|
||||
background: #0078fc;
|
||||
border-radius: 5px;
|
||||
color: #fff;
|
||||
cursor: pointer;
|
||||
"
|
||||
>
|
||||
去上课
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-dialog>
|
||||
@@ -237,7 +324,7 @@ import {
|
||||
UPDATE_CURRENT_TASK,
|
||||
checkStudentExist,
|
||||
EvaluationToLearn,
|
||||
QueryEvaluationTaskStatusOne
|
||||
QueryEvaluationTaskStatusOne,
|
||||
} from "@/api/api";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import store from "@/store";
|
||||
@@ -266,7 +353,10 @@ useRequest(PROJECT_PROCESS, { projectId: projectId, type }, (e) => {
|
||||
console.log("判断任务是否删除", res);
|
||||
if (res.code === 7) {
|
||||
router.push({
|
||||
path: "/loseefficacy",
|
||||
path: "/loseEfficacyProject",
|
||||
query: {
|
||||
msg: res.message,
|
||||
},
|
||||
});
|
||||
} else {
|
||||
if (res.code === 6) {
|
||||
@@ -377,7 +467,13 @@ const types = ref({
|
||||
},
|
||||
path: {
|
||||
1: window.location.protocol + import.meta.env.VITE_BOE_ONLINE_CLASS_URL, //在线
|
||||
2: ({ targetId }) => window.open(`${location.protocol}//${location.host}${import.meta.env.VITE_BASE_API}/stu/project/redirectDetail?courseId=${targetId}`, "_top"),
|
||||
2: ({ targetId }) =>
|
||||
window.open(
|
||||
`${location.protocol}//${location.host}${
|
||||
import.meta.env.VITE_BASE_API
|
||||
}/stu/project/redirectDetail?courseId=${targetId}`,
|
||||
"_top"
|
||||
),
|
||||
3: window.location.protocol + import.meta.env.VITE_BOE_CASS_DETAIL_URL, //案例
|
||||
4: "/homeworkpage",
|
||||
5: window.location.protocol + import.meta.env.VITE_BOE_EXAM_DETAIL_URL, //考试
|
||||
@@ -453,24 +549,28 @@ function judgeTaskIsEnd(type, endTimes, status) {
|
||||
return isEnd;
|
||||
}
|
||||
|
||||
function toFinish(d, sName, chapterOrStageId,studyModel) {
|
||||
function toFinish(d, sName, chapterOrStageId, studyModel) {
|
||||
if (studyModel != 0 && !d.statusName) {
|
||||
ElMessage.warning("当前未解锁")
|
||||
return
|
||||
ElMessage.warning("当前未解锁");
|
||||
return;
|
||||
}
|
||||
if(d.statusName == '未解锁'|| d.statusName == ''||!d.hasOwnProperty('statusName')){
|
||||
ElMessage.warning("当前未解锁")
|
||||
return
|
||||
if (
|
||||
d.statusName == "未解锁" ||
|
||||
d.statusName == "" ||
|
||||
!d.hasOwnProperty("statusName")
|
||||
) {
|
||||
ElMessage.warning("当前未解锁");
|
||||
return;
|
||||
}
|
||||
if (d.type === 2) {
|
||||
if(!d.targetId){
|
||||
return ElMessage.error("还未添加开课,请联系管理员!")
|
||||
if (!d.targetId) {
|
||||
return ElMessage.error("还未添加开课,请联系管理员!");
|
||||
}
|
||||
if(d.targetId.split(',').length>1){
|
||||
openCourseList.value = d.targetName?.split(',');
|
||||
openCourseIdList.value = d.targetId?.split(',');
|
||||
if (d.targetId.split(",").length > 1) {
|
||||
openCourseList.value = d.targetName?.split(",");
|
||||
openCourseIdList.value = d.targetId?.split(",");
|
||||
openCourseVisible.value = true;
|
||||
return
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (judgeTaskIsEnd(d.type, data.value.endTime, data.value.status)) {
|
||||
@@ -572,66 +672,72 @@ function toFinish(d, sName, chapterOrStageId,studyModel) {
|
||||
// 肯定没有完成测评
|
||||
// 调用接口 跳转页面
|
||||
request(EvaluationToLearn, {
|
||||
"businessType": "project",
|
||||
"chapterId": chapterOrStageId,
|
||||
"courseId": d.courseId,
|
||||
"quizKid": d.targetId,
|
||||
"routerOrProjectId": projectId,
|
||||
"studentId": userInfo.value.id,
|
||||
"studentName": userInfo.value.realName
|
||||
}).then(res => {
|
||||
console.log(res)
|
||||
if (res.code == 200) {
|
||||
let jumpUrl = res.data.quizUrl
|
||||
// 此处写跳转url
|
||||
window.open(jumpUrl, '_top')
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
businessType: "project",
|
||||
chapterId: chapterOrStageId,
|
||||
courseId: d.courseId,
|
||||
quizKid: d.targetId,
|
||||
routerOrProjectId: projectId,
|
||||
studentId: userInfo.value.id,
|
||||
studentName: userInfo.value.realName,
|
||||
})
|
||||
return
|
||||
.then((res) => {
|
||||
console.log(res);
|
||||
if (res.code == 200) {
|
||||
let jumpUrl = res.data.quizUrl;
|
||||
// 此处写跳转url
|
||||
window.open(jumpUrl, "_top");
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
return;
|
||||
} else {
|
||||
// 进行中 或者 已完成
|
||||
// 调用接口 判断当前测评状态 跳转页面
|
||||
console.log('我是查询测评跳转链接所传递得参数', {
|
||||
"quizTaskId": d.quizTaskId
|
||||
})
|
||||
console.log("我是查询测评跳转链接所传递得参数", {
|
||||
quizTaskId: d.quizTaskId,
|
||||
});
|
||||
request(QueryEvaluationTaskStatusOne, {
|
||||
"quizTaskId": d.quizTaskId
|
||||
}).then(res => {
|
||||
console.log(res)
|
||||
if (res.code == 200) {
|
||||
if (res.data.complete_status == 2) {
|
||||
ElMessage.error("您已完成测评")
|
||||
return
|
||||
} else {
|
||||
// 重新查询跳转
|
||||
// 调用接口 跳转页面
|
||||
request(EvaluationToLearn, {
|
||||
"businessType": "project",
|
||||
"chapterId": chapterOrStageId,
|
||||
"courseId": d.courseId,
|
||||
"quizKid": d.targetId,
|
||||
"routerOrProjectId": projectId,
|
||||
"studentId": userInfo.value.id,
|
||||
"studentName": userInfo.value.realName
|
||||
}).then(res => {
|
||||
console.log(res)
|
||||
if (res.code == 200) {
|
||||
let jumpUrl = res.data.quizUrl
|
||||
// 此处写跳转url
|
||||
window.open(jumpUrl, '_top')
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
})
|
||||
return
|
||||
}
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
quizTaskId: d.quizTaskId,
|
||||
})
|
||||
return
|
||||
.then((res) => {
|
||||
console.log(res);
|
||||
if (res.code == 200) {
|
||||
if (res.data.complete_status == 2) {
|
||||
ElMessage.error("您已完成测评");
|
||||
return;
|
||||
} else {
|
||||
// 重新查询跳转
|
||||
// 调用接口 跳转页面
|
||||
request(EvaluationToLearn, {
|
||||
businessType: "project",
|
||||
chapterId: chapterOrStageId,
|
||||
courseId: d.courseId,
|
||||
quizKid: d.targetId,
|
||||
routerOrProjectId: projectId,
|
||||
studentId: userInfo.value.id,
|
||||
studentName: userInfo.value.realName,
|
||||
})
|
||||
.then((res) => {
|
||||
console.log(res);
|
||||
if (res.code == 200) {
|
||||
let jumpUrl = res.data.quizUrl;
|
||||
// 此处写跳转url
|
||||
window.open(jumpUrl, "_top");
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
return;
|
||||
}
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -708,8 +814,13 @@ function toFinish(d, sName, chapterOrStageId,studyModel) {
|
||||
// }
|
||||
}
|
||||
|
||||
function toOffcoursePlanPage(id){
|
||||
window.open(`${location.protocol}//${location.host}${import.meta.env.VITE_BASE_API}/stu/project/redirectDetail?courseId=${id}`, '_top')
|
||||
function toOffcoursePlanPage(id) {
|
||||
window.open(
|
||||
`${location.protocol}//${location.host}${
|
||||
import.meta.env.VITE_BASE_API
|
||||
}/stu/project/redirectDetail?courseId=${id}`,
|
||||
"_top"
|
||||
);
|
||||
}
|
||||
|
||||
function whiteTypes(type) {
|
||||
@@ -730,10 +841,10 @@ const queryAllStatus = (data) => {
|
||||
|
||||
<style lang="scss">
|
||||
.projectdetails {
|
||||
.el-dialog__body{
|
||||
.el-dialog__body {
|
||||
width: 80%;
|
||||
}
|
||||
.el-dialog__header{
|
||||
.el-dialog__header {
|
||||
display: none;
|
||||
}
|
||||
width: 100%;
|
||||
|
||||
Reference in New Issue
Block a user