Merge branch 'pre-manage' into 'release'

Pre manage

See merge request !9
This commit is contained in:
huangshengfa
2022-12-26 16:43:25 +08:00
11 changed files with 293 additions and 334 deletions

View File

@@ -7,6 +7,6 @@ VITE_BOE_CASS_DETAIL_URL=https://u.boe.com/pc-release/case/detail?id=
VITE_BOE_TEST_DETAIL_URL=https://u.boe.com/web/quizsummary?detailId= VITE_BOE_TEST_DETAIL_URL=https://u.boe.com/web/quizsummary?detailId=
VITE_BOE_TEST_OUT_DETAIL_URL=https://u.boe.com/api/b1/tale/do-quiz?quizKid= VITE_BOE_TEST_OUT_DETAIL_URL=https://u.boe.com/api/b1/tale/do-quiz?quizKid=
VITE_BOE_EXAM_DETAIL_URL=https://u.boe.com/pc-release/exam/test?id= VITE_BOE_EXAM_DETAIL_URL=https://u.boe.com/pc-release/exam/test?id=
VITE_BOE_PATH_DETAIL_URL=http://u.boe.com/pc/forward?to=/fe-student-release VITE_BOE_PATH_DETAIL_URL=http://u.boe.com/pc-release/forward?to=/fe-student-release
VITE_BOE_API_URL=https://u.boe.com VITE_BOE_API_URL=https://u.boe.com

View File

@@ -36,7 +36,7 @@ import {useStore} from "vuex";
import { onMounted } from "vue"; import { onMounted } from "vue";
import router from "@/router"; import router from "@/router";
console.log("版本1.0.6------------"); console.log("版本1.0.7------------");
const store = useStore(); const store = useStore();
onMounted(() => { onMounted(() => {
getUserInfo(); getUserInfo();
@@ -66,6 +66,7 @@ function getUserInfo() {
width: 100%; width: 100%;
min-height: 100%; min-height: 100%;
background-color: rgba(242, 245, 247, 1); background-color: rgba(242, 245, 247, 1);
// background-color: #ccc; // background-color: #ccc;
#nav { #nav {
width: 220px; width: 220px;

View File

@@ -94,7 +94,7 @@ export async function request(_url, params) {
}).then(resp => resp.data).then(response => { }).then(resp => resp.data).then(response => {
if (response.code !== 200 && response.code !== 0) { if (response.code !== 200 && response.code !== 0) {
if (response.code === 1000) { if (response.code === 1000) {
import.meta.env.MODE === 'development' ? router.push({ path: '/login' }) : window.open(import.meta.env.VITE_BASE_LOGIN_URL) import.meta.env.MODE === 'development' ? router.push({ path: '/login' }) : window.open(import.meta.env.VITE_BASE_LOGIN_URL,'_self')
} }
// if (import.meta.env.DEV && response.code === 1000) { // if (import.meta.env.DEV && response.code === 1000) {
// router.push({path: '/login'}) // router.push({path: '/login'})

View File

@@ -64,7 +64,7 @@ function toDetail(i) {
`${import.meta.env.VITE_BOE_PATH_DETAIL_URL}/pathdetails&params=${encodeURIComponent( `${import.meta.env.VITE_BOE_PATH_DETAIL_URL}/pathdetails&params=${encodeURIComponent(
`routerId=${props.detail.routerId}&routerName=${props.detail.routerName}` `routerId=${props.detail.routerId}&routerName=${props.detail.routerName}`
)}` )}`
); ,'_self');
} }
function close() { function close() {

View File

@@ -44,7 +44,7 @@
评估 评估
</botton> </botton>
<botton :style="{ <botton :style="{
background: `${new Date(data.planDto.beginTime).getTime() > new Date().getTime() ? '#999' : data.isSurvery ? '#999' : 'rgb(57, 146, 249)'}`, background: `${new Date(data.planDto?.beginTime).getTime() > new Date().getTime() ? '#999' : data.isSurvery ? '#999' : 'rgb(57, 146, 249)'}`,
}" class="btn" @click="toSurvery" v-else>{{ data.isSurvery ? "已评估" : "评估" }} }" class="btn" @click="toSurvery" v-else>{{ data.isSurvery ? "已评估" : "评估" }}
</botton> </botton>
</div> </div>
@@ -139,7 +139,7 @@
</div> </div>
<div <div
:style="{ background: new Date(data.planDto.beginTime).getTime() > new Date().getTime() ? '#999' : '' }" :style="{ background: new Date(data.planDto?.beginTime).getTime() > new Date().getTime() ? '#999' : '' }"
class="submit" @click="toExamItem(data.examinationDto)"> class="submit" @click="toExamItem(data.examinationDto)">
去考试 去考试
</div> </div>
@@ -324,8 +324,7 @@ function toSurvery() {
query: { query: {
courseId: data.value.planDto.evaluateId, courseId: data.value.planDto.evaluateId,
pName: "面授课", pName: "面授课",
taskId: data.value.planDto.offcoursePlanId, infoId: data.value.offcourseDto.offcourseId,
taskIds: data.value.planDto.offcoursePlanId,
chapterOrStageId: 0, chapterOrStageId: 0,
sName: data.value.planDto.name, sName: data.value.planDto.name,
type: 3 type: 3
@@ -349,8 +348,7 @@ function toWork() {
query: { query: {
courseId: data.value.workDto.workId, courseId: data.value.workDto.workId,
id: taskId, id: taskId,
taskId: taskId, infoId: data.value.offcourseDto.offcourseId,
taskIds: taskId,
chapterOrStageId: 0, chapterOrStageId: 0,
type, type,
pName: "面授课", pName: "面授课",
@@ -369,7 +367,7 @@ function toExamItem(obj) {
} }
} }
console.log("obj", obj.examinationTestId); console.log("obj", obj.examinationTestId);
window.open(import.meta.env.VITE_BOE_EXAM_DETAIL_URL + obj.examinationTestId); //测评 window.open(import.meta.env.VITE_BOE_EXAM_DETAIL_URL + obj.examinationTestId,'_self'); //测评
// 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 });
} }

View File

@@ -179,7 +179,7 @@
{{data?.submitStartTime}}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{{data?.submitEndTime}} {{data?.submitStartTime}}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{{data?.submitEndTime}}
</div> </div>
<div class="endtime clearfix"> <div class="endtime clearfix">
<div v-if="dayjs(data?.submitEndTime).isBefore(dayjs())" class="endtimetext">任务已结束</div> <div v-if="dayjs(data?.submitEndTime).isBefore(dayjs())" class="endtimetext">任务已结束</div>
<div v-else class="endtimetext">距离结束还有&nbsp;&nbsp;<span class="te">{{parseInt(dayjs(data?.submitEndTime).diff(dayjs(), "minute") / 60)}}</span>&nbsp;&nbsp; 小时&nbsp;&nbsp; <div v-else class="endtimetext">距离结束还有&nbsp;&nbsp;<span class="te">{{parseInt(dayjs(data?.submitEndTime).diff(dayjs(), "minute") / 60)}}</span>&nbsp;&nbsp; 小时&nbsp;&nbsp;
<span class="te">{{dayjs(data?.submitEndTime).diff(dayjs(), "minute") % 60}}</span>&nbsp;&nbsp;分钟</div> <span class="te">{{dayjs(data?.submitEndTime).diff(dayjs(), "minute") % 60}}</span>&nbsp;&nbsp;分钟</div>
</div> </div>

View File

@@ -61,7 +61,9 @@
<botton :style="{ <botton :style="{
background: `${new Date(data.liveStartTime).getTime() > new Date().getTime() ? '#999' : data.isSurvery ? '#999' : 'rgb(57, 146, 249)'}`, background: `${new Date(data.liveStartTime).getTime() > new Date().getTime() ? '#999' : data.isSurvery ? '#999' : 'rgb(57, 146, 249)'}`,
}" class="btn" @click="commitClick" v-if="data.isEvaluate && data.isEvaluate == 1">{{ data.isSurvery ? "已评估": "评估"}} }" class="btn" @click="commitClick" v-if="data.isEvaluate && data.isEvaluate == 1">{{ data.isSurvery ? "已评估" :
"评估"
}}
</botton> </botton>
</div> </div>
</div> </div>
@@ -264,8 +266,7 @@ const commitClick = () => {
path: "/surveydetail", path: "/surveydetail",
query: { query: {
courseId: data.value.assessmentId, courseId: data.value.assessmentId,
taskId: data.value.liveId, infoId: data.value.liveId,
taskIds: data.value.liveId,
chapterOrStageId: 0, chapterOrStageId: 0,
pName: "直播", pName: "直播",
sName: data.value.liveName, sName: data.value.liveName,
@@ -283,7 +284,7 @@ function showClick() {
return; return;
} }
} }
window.open(data.value.liveLink); window.open(data.value.liveLink,'_self');
} }
onUnmounted(() => { onUnmounted(() => {
if (timer) { if (timer) {

View File

@@ -1,24 +1,11 @@
<template> <template>
<div style=" background: #0078fc;height: 150px;width: 100%;position: absolute;top: 0;z-index:-9999;"></div> <div style=" background: #0078fc;height: 150px;width: 100%;position: absolute;top: 0;z-index:-9999;"></div>
<div class="pathdetails" style="padding: 30px"> <div class="pathdetails" style="padding: 30px">
<!-- 面包屑导航 -->
<div class="crumb">
<div>{{ data.name }}</div>
<div style="margin-left: 6px; margin-right: 6px">/</div>
<div style="font-weight: 700">项目详情</div>
<!--
<div class="return">
<div style="display: flex" @click="returnclick">
<el-button style="color:#0073FB"> <img class="img2" style="margin-right:11px;cursor: pointer;"
src="../../assets/image/return.png" />返回</el-button>
</div>
</div>
-->
</div>
<!-- 面包屑导航 -->
<div class="pdname"> <div class="pdname">
{{ userInfo.bandDesc }} {{ data.name }}
<el-popover v-if="data.remark" ref="popover" popper-class="jianjie" placement="right" trigger="hover" :width="300" :content="data.remark"> <el-popover v-if="data.remark" ref="popover" popper-class="jianjie" placement="right" trigger="hover" :width="300"
:content="data.remark">
<template #reference><span style="font-size: 16px;font-weight: 600;">简介></span></template> <template #reference><span style="font-size: 16px;font-weight: 600;">简介></span></template>
</el-popover> </el-popover>
</div> </div>
@@ -95,7 +82,7 @@
</div> </div>
<div class="goclass" @click="toFinish(value, i.stageName, i.stageId)"> <div class="goclass" @click="toFinish(value, i.stageName, i.stageId)">
{{ {{
value.status === 1 value.status === 100
? "已完成" ? "已完成"
: types.path[value.type] : types.path[value.type]
? types.toName[value.type] ? types.toName[value.type]
@@ -356,7 +343,7 @@ const types = ref({
6: "/livebroadcast", 6: "/livebroadcast",
7: ({ courseId }) => 7: ({ courseId }) =>
request(LINK_DETAILS(courseId), {}).then(({ data: { linkAddress } }) => request(LINK_DETAILS(courseId), {}).then(({ data: { linkAddress } }) =>
window.open(linkAddress) window.open(linkAddress,'_self')
), //外联 ), //外联
8: "/discusspage", 8: "/discusspage",
9: "/moreactive", 9: "/moreactive",
@@ -365,7 +352,7 @@ const types = ref({
(evaType == 0 (evaType == 0
? import.meta.env.VITE_BOE_TEST_DETAIL_URL ? import.meta.env.VITE_BOE_TEST_DETAIL_URL
: import.meta.env.VITE_BOE_TEST_OUT_DETAIL_URL) + targetId : import.meta.env.VITE_BOE_TEST_OUT_DETAIL_URL) + targetId
), //测评 ,'_self'), //测评
11: "/surveydetail", 11: "/surveydetail",
12: "/ballotpage", 12: "/ballotpage",
13: "/projectdetails", 13: "/projectdetails",
@@ -462,7 +449,7 @@ function toFinish(d, sName, chapterOrStageId) {
if (typeof types.value.path[d.type] === "string") { if (typeof types.value.path[d.type] === "string") {
types.value.path[d.type] && types.value.path[d.type] &&
types.value.path[d.type].startsWith("http") && types.value.path[d.type].startsWith("http") &&
window.open(types.value.path[d.type] + d.targetId); window.open(types.value.path[d.type] + d.targetId,'_self');
types.value.path[d.type] && types.value.path[d.type] &&
types.value.path[d.type].startsWith("/") && types.value.path[d.type].startsWith("/") &&
router.push({ router.push({
@@ -470,8 +457,7 @@ function toFinish(d, sName, chapterOrStageId) {
query: { query: {
id: d.projectTaskId, id: d.projectTaskId,
type: 2, type: 2,
taskId: data.value.projectId, infoId: data.value.projectId,
taskIds: data.value.projectId,
courseId: d.courseId, courseId: d.courseId,
pName: data.value.name, pName: data.value.name,
sName, sName,
@@ -491,6 +477,7 @@ function whiteTypes(type) {
.example-showcase .el-loading-mask { .example-showcase .el-loading-mask {
z-index: 9; z-index: 9;
} }
.pathdetails { .pathdetails {
.el-dialog__header { .el-dialog__header {
display: none; display: none;

View File

@@ -187,7 +187,7 @@ const goProjectDetails = (value) => {
: window.open( : window.open(
`${import.meta.env.VITE_BOE_PATH_DETAIL_URL}/projectdetails&params=${encodeURIComponent( `${import.meta.env.VITE_BOE_PATH_DETAIL_URL}/projectdetails&params=${encodeURIComponent(
`projectId=${value.projectId}` `projectId=${value.projectId}`
)}` ,'_self')}`
); );
}; };
</script> </script>

View File

@@ -1,26 +1,13 @@
<template> <template>
<div style=" background: #0078fc;height: 150px;width: 100%;position: absolute;top: 0;z-index:-9999;"></div> <div style=" background: #0078fc;height: 150px;width: 100%;position: absolute;top: 0;z-index:-9999;"></div>
<div class="pathdetails" style="padding: 30px"> <div class="pathdetails" style="padding: 30px">
<!-- 面包屑导航 -->
<div class="crumb">
<div>{{ data.name }}</div>
<div style="margin-left: 6px; margin-right: 6px">/</div>
<div style="font-weight: 700">路径图详情</div>
<!--
<div class="return">
<div style="display: flex" @click="returnclick">
<el-button style="color:#0073FB"> <img class="img2" style="margin-right:11px;cursor: pointer;"
src="../../assets/image/return.png" />返回</el-button>
</div>
</div>
-->
</div>
<!-- 面包屑导航 --> <!-- 面包屑导航 -->
<div class="pdname"> <div class="pdname">
{{ userInfo.bandDesc }} {{ data.name }}
<el-popover v-if="data.remark" ref="popover" popper-class="jianjie" placement="right" trigger="hover" :width="300" :content="data.remark"> <el-popover v-if="data.remark" ref="popover" popper-class="jianjie" placement="right" trigger="hover" :width="300"
:content="data.remark">
<template #reference><span style="font-size: 16px;font-weight: 600;">简介></span></template> <template #reference><span style="font-size: 16px;font-weight: 600;">简介></span></template>
</el-popover> </el-popover>
</div> </div>
@@ -32,20 +19,15 @@
<div class="title"> <div class="title">
<div class="titleL">{{ data.currentStageName }}</div> <div class="titleL">{{ data.currentStageName }}</div>
<div class="titleR" :style="{ display: 'flex' }"> <div class="titleR" :style="{ display: 'flex' }">
<img <img :src="data.currentChapterCnt ? circle : circle2" />
:src="data.currentChapterCnt?circle:circle2"/>
<div class="titleRT" :style="{ color: data.currentChapterCnt ? '' : 'rgba(102, 102, 102, 1)' }"> <div class="titleRT" :style="{ color: data.currentChapterCnt ? '' : 'rgba(102, 102, 102, 1)' }">
{{ data.currentChapterCnt ? '进行中' : '未开始' }} {{ data.currentChapterCnt ? '进行中' : '未开始' }}
</div> </div>
</div> </div>
</div> </div>
<div <div class="course" v-for="(value, index) in data.taskBoList?.filter(
class="course"
v-for="(value, index) in data.taskBoList?.filter(
(e) => !whiteTypes(e.type) (e) => !whiteTypes(e.type)
)" )" :key="index">
:key="index"
>
<div style="width: 70%"> <div style="width: 70%">
<div v-if="value.name.length > 50" class="coursename" :title="value.name"> <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"> <el-popover ref="popover" placement="right" trigger="hover" :width="300" :content="value.name">
@@ -57,18 +39,10 @@
{{ value.name }} {{ value.name }}
</div> </div>
<div class="coursetag"> <div class="coursetag">
<div <div class="tag1" style="margin-right: 11px; margin-top: 16px" v-if="value.flag">
class="tag1"
style="margin-right: 11px; margin-top: 16px"
v-if="value.flag"
>
必修 必修
</div> </div>
<div <div class="tag2" style="margin-right: 11px; margin-top: 16px" v-if="!value.flag">
class="tag2"
style="margin-right: 11px; margin-top: 16px"
v-if="!value.flag"
>
选修 选修
</div> </div>
<div class="tag3" style="margin-right: 11px; margin-top: 16px"> <div class="tag3" style="margin-right: 11px; margin-top: 16px">
@@ -99,8 +73,7 @@
}[parseInt(value.currentRatio / 20)] }[parseInt(value.currentRatio / 20)]
" /> " />
</div> </div>
<div style="font-size: 14px;font-weight: 500;color: #277aff;margin-left: 10px;" <div style="font-size: 14px;font-weight: 500;color: #277aff;margin-left: 10px;" :style="{
:style="{
color: { color: {
0: 'rgba(238, 112, 108, 1)', 0: 'rgba(238, 112, 108, 1)',
1: 'rgba(255, 151, 38, 1)', 1: 'rgba(255, 151, 38, 1)',
@@ -118,7 +91,7 @@
<div class="goclass" :style="{ <div class="goclass" :style="{
background: `${types.path[value.type] ? '#2478ff' : '#999'}`, background: `${types.path[value.type] ? '#2478ff' : '#999'}`,
}" @click="toFinish(value)"> }" @click="toFinish(value)">
{{ value.status === 1 ? "已完成" : types.path[value.type] ? types.toName[value.type] : "未开放" }} {{ value.currentRatio === 100 ? "已完成" : types.path[value.type] ? types.toName[value.type] : "未开放" }}
</div> </div>
<!-- <div :style="{ display: value.status === 1 ? 'block' : 'none' }">--> <!-- <div :style="{ display: value.status === 1 ? 'block' : 'none' }">-->
<!-- <div--> <!-- <div-->
@@ -370,7 +343,7 @@ const types = ref({
6: "/livebroadcast", 6: "/livebroadcast",
7: ({ courseId }) => 7: ({ courseId }) =>
request(LINK_DETAILS(courseId), {}).then(({ data: { linkAddress } }) => request(LINK_DETAILS(courseId), {}).then(({ data: { linkAddress } }) =>
window.open(linkAddress) window.open(linkAddress, '_self')
), //外联 ), //外联
8: "/discusspage", 8: "/discusspage",
9: "/moreactive", 9: "/moreactive",
@@ -379,7 +352,7 @@ const types = ref({
(evaType == 0 (evaType == 0
? import.meta.env.VITE_BOE_TEST_DETAIL_URL ? import.meta.env.VITE_BOE_TEST_DETAIL_URL
: import.meta.env.VITE_BOE_TEST_OUT_DETAIL_URL) + targetId : import.meta.env.VITE_BOE_TEST_OUT_DETAIL_URL) + targetId
), //测评 ,'_self'), //测评
11: "/surveydetail", 11: "/surveydetail",
12: "/ballotpage", 12: "/ballotpage",
13: "/projectdetails", 13: "/projectdetails",
@@ -471,17 +444,15 @@ function toFinish(d) {
if (typeof types.value.path[d.type] === "string") { if (typeof types.value.path[d.type] === "string") {
types.value.path[d.type] && types.value.path[d.type] &&
types.value.path[d.type].startsWith("http") && types.value.path[d.type].startsWith("http") &&
window.open(types.value.path[d.type] + d.targetId); window.open(types.value.path[d.type] + d.targetId,'_self');
types.value.path[d.type] && types.value.path[d.type] &&
types.value.path[d.type].startsWith("/") && types.value.path[d.type].startsWith("/") &&
router.push({ router.push({
path: types.value.path[d.type], path: types.value.path[d.type],
query: { query: {
id: d.routerTaskId, id: d.routerTaskId,
// id: routerId,
type: 1, type: 1,
taskId: routerId, infoId: routerId,
taskIds: routerId,
courseId: d.courseId, courseId: d.courseId,
pName: data.value.name, pName: data.value.name,
sName: data.value.currentStageName, sName: data.value.currentStageName,
@@ -522,6 +493,7 @@ function whiteTypes(type) {
margin-top: 24px; margin-top: 24px;
display: flex; display: flex;
z-index: 2; z-index: 2;
.detailL { .detailL {
flex: 1; flex: 1;
margin-right: 20px; margin-right: 20px;

View File

@@ -334,7 +334,7 @@ import { ElMessage } from "element-plus";
import { ref } from "vue"; import { ref } from "vue";
const { const {
query: { courseId, id: taskId, taskIds, type, pName, sName, chapterOrStageId }, query: { courseId, id: taskId, infoId, type, pName, sName, chapterOrStageId },
} = useRoute(); } = useRoute();
const router = useRouter(); const router = useRouter();
const returnclick = () => { const returnclick = () => {
@@ -353,8 +353,8 @@ function formateArr(arr1) {
return newarr return newarr
} }
const { data } = useRequest(ASSESSMENT_QUERY(courseId), { id: courseId, type, chapterOrStageId, targetId: taskIds ? taskIds : 0 }); const { data } = useRequest(ASSESSMENT_QUERY(courseId), { id: courseId, type, chapterOrStageId, targetId: infoId ? infoId : 0 });
console.log('我是查询评估的参数', { id: courseId, type, chapterOrStageId, targetId: taskIds ? taskIds : 0 }) console.log('我是查询评估的参数', { id: courseId, type, chapterOrStageId, targetId: infoId ? infoId : 0 })
console.log('我是需要排序得题目', data) console.log('我是需要排序得题目', data)
function goHome() { function goHome() {
@@ -369,10 +369,10 @@ function submit() {
if (1 > 0) { if (1 > 0) {
console.log(data) console.log(data)
console.log('我是提交的数据', { console.log('我是提交的数据', {
targetId: taskId ? taskId : taskIds ? taskIds : 0, // 项目、路径图或开课的Id targetId: infoId ? infoId : 0, // 项目、路径图或开课的Id
chapterOrStageId: chapterOrStageId ? chapterOrStageId : 0, // 关卡或者阶段Id 关卡Id不允许为空 chapterOrStageId: chapterOrStageId ? chapterOrStageId : 0, // 关卡或者阶段Id 关卡Id不允许为空
assessmentId: courseId, assessmentId: courseId,
taskId: taskId ? taskId : taskIds ? taskIds : 0, taskId: taskId ? taskId : 0,
type, type,
result: JSON.stringify(data.value), result: JSON.stringify(data.value),
}) })
@@ -424,10 +424,10 @@ function submit() {
data.value.isSubmit = !data.value.isSubmit; data.value.isSubmit = !data.value.isSubmit;
request(ASSESSMENT_SUBMIT, { request(ASSESSMENT_SUBMIT, {
targetId: taskIds ? taskIds : 0, // 项目、路径图或开课的Id targetId: infoId ? infoId : 0, // 项目、路径图或开课的Id
chapterOrStageId: chapterOrStageId ? chapterOrStageId : 0, // 关卡或者阶段Id 关卡Id不允许为空 chapterOrStageId: chapterOrStageId ? chapterOrStageId : 0, // 关卡或者阶段Id 关卡Id不允许为空
assessmentId: courseId, assessmentId: courseId,
taskId: taskIds ? taskIds : 0, taskId: taskId ? taskId : 0,
type, type,
result: JSON.stringify(data.value), result: JSON.stringify(data.value),
}).then(() => { }).then(() => {