mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/student-h5.git
synced 2025-12-06 17:36:45 +08:00
feat:增加投票
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2023-01-13 11:42:48
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2023-01-31 17:32:26
|
||||
* @LastEditTime: 2023-02-03 12:01:18
|
||||
* @FilePath: /stu_h5/src/api/api.js
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
*/
|
||||
@@ -26,12 +26,11 @@ export const STU_OFFCOURSE_DETAIL = '/stu/offcourse/detail post'
|
||||
export const WORK_QUERYWORKDETAILBYID = '/work/queryWorkDetailById'
|
||||
export const EXAMINATION_QUERYEXAMINATIONDETAILBYID = '/examination/queryExaminationDetailById'
|
||||
export const DISCUSS_COLLECTION = '/discussSubmit/clickDiscussCollectionCountOr POST'
|
||||
export const DISCUSS_LIKE = '/discussSubmit/clickDiscussLikeCountOr POST'
|
||||
export const ACTIVITY = '/activity'
|
||||
export const EXAMINATION_QUERY = examinationId => `/examination/queryExaminationDetailById?examinationId=${examinationId} post`
|
||||
export const TASK_OFFCOURSE_NOTASK_SIGN = '/stu/task/offcourse/notask/sign post'
|
||||
export const TASK_OFFCOURSE_SIGN = '/stu/task/offcourse/sign post'
|
||||
export const LINK_DETAILS = linkId => `/link/getOne?linkId=${linkId} post`
|
||||
export const LINK_DETAILS = linkId => `/link/getOne?linkId=${linkId}`
|
||||
export const STUDY_RECORD = '/stu/task/thirdTask/submit post'
|
||||
export const TASK_WORK_SUBMIT_LIST = '/workSubmit/queryWorkSubmitDetailById'
|
||||
export const WORK_HISTROY = '/workSubmit/queryWorkDetailListByStuId'
|
||||
@@ -42,3 +41,17 @@ export const ROUTER_DETAILS = '/admin/router/detail'
|
||||
export const TASK_LIST = '/stu/tasks'
|
||||
export const ONLINE_PROCESS = '/onlineClasses/queryOnlineClassesStudyDetail post'
|
||||
export const PROJECT_PROCESS = '/stu/project/process'
|
||||
export const EVALUATION_DETAIL = evaluationId => `/evaluation/queryEvaluationDetailById?evaluationId=${evaluationId} post`
|
||||
export const DISCUSS_LIKE = '/discussSubmit/clickDiscussLikeCountOr post'
|
||||
export const DISCUSS_LIST = '/discussSubmit/taskList'
|
||||
export const DISCUSS_DETAIL = '/discussSubmit/detail'
|
||||
export const DISCUSS_SUBMIT_REVIEW_LIST = '/discussSubmit/queryDiscussSubmitAndReview'
|
||||
export const VOTE_DETAIL2 = `/voteSubmit/queryVoteTaskDetailById post`
|
||||
// 投票详情接口
|
||||
export const VOTE_DETAIL_SUBMIT = `/voteSubmit/vote/commit post`
|
||||
|
||||
// 讨论模块
|
||||
// -- 根据讨论的Id查询讨论发表的帖子
|
||||
export const QueryDiscussSubmitDetailByDiscussId = '/discussSubmit/queryDiscussSubmitDetailByDiscussId post'
|
||||
export const COMMENT_PRAISE = '/comment/praise post'
|
||||
export const COMMENT_COLLECTION = '/comment/collection post'
|
||||
@@ -3,7 +3,9 @@ import { reactive, ref, toRefs, watch } from "vue";
|
||||
import axios from 'axios';
|
||||
import { getCookie } from "@/api/utils";
|
||||
import JSONBigInt from 'json-bigint';
|
||||
|
||||
const JSONBigIntStr = JSONBigInt({ storeAsString: true });
|
||||
|
||||
export function usePage(_url, param, callback) {
|
||||
|
||||
const state = reactive({
|
||||
@@ -38,27 +40,30 @@ export function usePage(_url, param, callback) {
|
||||
fetchData,
|
||||
};
|
||||
}
|
||||
|
||||
export function useRequest(_url, params = {}) {
|
||||
|
||||
const data = ref({})
|
||||
const loading = ref(false)
|
||||
const state = reactive({
|
||||
data: {},
|
||||
loading: false,
|
||||
|
||||
})
|
||||
|
||||
watch(params, () => {
|
||||
fetchData()
|
||||
})
|
||||
|
||||
function fetchData() {
|
||||
loading.value = true
|
||||
state.loading = true
|
||||
request(_url, params).then(r => {
|
||||
data.value = r.data
|
||||
loading.value = false
|
||||
state.data = r.data
|
||||
state.loading = false
|
||||
})
|
||||
}
|
||||
|
||||
fetchData()
|
||||
return {
|
||||
data,
|
||||
loading,
|
||||
...toRefs(state),
|
||||
fetchData,
|
||||
};
|
||||
}
|
||||
@@ -94,6 +99,12 @@ export async function request(_url, params) {
|
||||
if (response.code === 1000) {
|
||||
(import.meta.env.MODE === 'development' || import.meta.env.MODE === 'test') ? router.push({ path: '/login' }) : window.open(import.meta.env.VITE_BASE_LOGIN_URL, '_top')
|
||||
}
|
||||
if (response.code === 2001) {
|
||||
router.push({ path: '/FaceTeachSignUp', query: { courseId: router.currentRoute.value.query.courseId, type: 3 } })
|
||||
}
|
||||
if (response.code === 2002) {
|
||||
router.push({ path: '/FaceTeachNoCommon', query: { courseId: router.currentRoute.value.query.courseId, type: 3 } })
|
||||
}
|
||||
// if (import.meta.env.DEV && response.code === 1000) {
|
||||
// router.push({path: '/login'})
|
||||
// } else {
|
||||
@@ -103,12 +114,8 @@ export async function request(_url, params) {
|
||||
// duration: 2,
|
||||
// });
|
||||
// }
|
||||
throw new Error('接口异常')
|
||||
}
|
||||
return response
|
||||
}).catch(e => {
|
||||
console.log('eeeee', e)
|
||||
// router.push({path: '/login'})
|
||||
})
|
||||
}
|
||||
|
||||
@@ -140,11 +147,5 @@ export async function boeRequest(_url, params) {
|
||||
return res.text()
|
||||
}).then(res => {
|
||||
return JSONBigIntStr.parse(res)
|
||||
}).then(res => {
|
||||
console.log(res)
|
||||
if (res.status === 500) {
|
||||
import.meta.env.MODE === 'development' ? router.push({ path: '/login', query: { returnUrl: router.currentRoute.value.fullPath } }) : window.open(import.meta.env.VITE_BASE_LOGIN_URL + window.location.url, '_top')
|
||||
}
|
||||
return res
|
||||
})
|
||||
}
|
||||
@@ -1,23 +1,25 @@
|
||||
<template>
|
||||
<div class="ballotpage">
|
||||
<!-- <TitleHead text="【投票】管理者进阶腾飞班 - 授课方式"></TitleHead> -->
|
||||
|
||||
<ReturnHead text="投票详情"></ReturnHead>
|
||||
<div class="notice">
|
||||
<div class="noticebox">
|
||||
<div class="mani">
|
||||
<div class="joininfo" style="margin-left: -8px">
|
||||
【投票】管理者进阶腾飞班 - 授课方式
|
||||
【投票】{{ data?.voteName }}
|
||||
</div>
|
||||
<div class="contenttitle">
|
||||
<img class="timeimg" src="../../assets/image/ballotpage/time.png" />
|
||||
<div class="timee">2022-07-20 20:00-21:00</div>
|
||||
<div class="timee">
|
||||
{{ data?.voteStartTime + " 至 " + data?.voteEndTime }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="timebox">
|
||||
<div class="samez" style="margin-left: 18px">00</div>
|
||||
<div class="samez" style="margin-left: 18px">{{ hour }}</div>
|
||||
<div class="samey">时</div>
|
||||
<div class="samez">00</div>
|
||||
<div class="samez">{{ minute }}</div>
|
||||
<div class="samey">分</div>
|
||||
<div class="samez">00</div>
|
||||
<div class="samez">{{ seconds }}</div>
|
||||
<div class="samey">秒</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -31,15 +33,33 @@
|
||||
<div class="line"></div>
|
||||
<div class="contentone">
|
||||
<div class="same ba">
|
||||
<div class="samenum" style="color: #089dff">123</div>
|
||||
<div class="samenum" style="color: #089dff">
|
||||
{{
|
||||
data?.numberOfInvolved || data?.numberOfInvolved == 0
|
||||
? data?.numberOfInvolved
|
||||
: "-"
|
||||
}}
|
||||
</div>
|
||||
<div class="samego">参与数</div>
|
||||
</div>
|
||||
<div class="same bt">
|
||||
<div class="samenum" style="color: #387df7">123</div>
|
||||
<div class="samenum" style="color: #387df7">
|
||||
{{
|
||||
data?.votesTotal || data?.votesTotal == 0
|
||||
? data?.votesTotal
|
||||
: "-"
|
||||
}}
|
||||
</div>
|
||||
<div class="samego">总票数</div>
|
||||
</div>
|
||||
<div class="same bh">
|
||||
<div class="samenum" style="color: #00c1fc">123</div>
|
||||
<div class="samenum" style="color: #00c1fc">
|
||||
{{
|
||||
data?.numberOfBrowse || data?.numberOfBrowse == 0
|
||||
? data?.numberOfBrowse
|
||||
: "-"
|
||||
}}
|
||||
</div>
|
||||
<div class="samego">浏览数</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -53,8 +73,7 @@
|
||||
<div class="line"></div>
|
||||
<div class="contentone">
|
||||
<div class="ballotdetail">
|
||||
为提高核心项目讲解体验,现向广大学员征集较为接受的授课方式
|
||||
,每位学员可投票2个选项,我们将选取最高选项的两个做后续讲解。
|
||||
{{ data?.voteExplain }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -96,43 +115,76 @@
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { reactive, toRefs } from "vue";
|
||||
<script setup>
|
||||
import { reactive, toRefs, computed, onUnmounted, ref } from "vue";
|
||||
import ReturnHead from "@/components/ReturnHead.vue";
|
||||
// import TitleHead from "@/components/TitleHead.vue";
|
||||
export default {
|
||||
name: "BallotPage",
|
||||
components: {
|
||||
// TitleHead,
|
||||
},
|
||||
setup() {
|
||||
const state = reactive({
|
||||
ballot: [
|
||||
{
|
||||
id: 1,
|
||||
content: "录播课",
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
content: "PPT+配音",
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
content: "HTML5",
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
content: "OTHER",
|
||||
},
|
||||
],
|
||||
});
|
||||
const getId = (id) => {
|
||||
console.log(id);
|
||||
};
|
||||
return {
|
||||
...toRefs(state),
|
||||
getId,
|
||||
};
|
||||
},
|
||||
import { useRequest, request } from "@/api/request";
|
||||
import { VOTE_DETAIL2, VOTE_DETAIL_SUBMIT } from "@/api/api";
|
||||
import dayjs from "dayjs";
|
||||
import store from "@/store";
|
||||
import { ElMessage } from "element-plus";
|
||||
import { useRoute, useRouter } from "vue-router/dist/vue-router";
|
||||
|
||||
const {
|
||||
query: { courseId, chapterOrStageId, infoId, id, btype, studentId },
|
||||
} = useRoute();
|
||||
const { data } = useRequest(VOTE_DETAIL2, {
|
||||
chapterOrStageId: chapterOrStageId ? chapterOrStageId : 0,
|
||||
courseId: courseId,
|
||||
studentId: studentId,
|
||||
targetId: infoId,
|
||||
type: btype,
|
||||
});
|
||||
console.log("投票基本信息", data);
|
||||
//投票倒计时
|
||||
let hour = ref(0);
|
||||
let minute = ref(0);
|
||||
let seconds = ref(0);
|
||||
let timer = setInterval(() => {
|
||||
let endTime = parseInt(new Date(data.value.voteEndTime).getTime() / 1000);
|
||||
let nowTime = parseInt(new Date().getTime() / 1000);
|
||||
if (endTime > nowTime) {
|
||||
hour.value = parseInt(
|
||||
dayjs(data.value.voteEndTime).diff(dayjs(), "minute") / 60
|
||||
);
|
||||
minute.value = parseInt(
|
||||
dayjs(data.value.voteEndTime).diff(dayjs(), "minute") % 60
|
||||
);
|
||||
seconds.value = parseInt(
|
||||
dayjs(data.value.voteEndTime).diff(dayjs(), "seconds") -
|
||||
(hour.value * 60 + minute.value) * 60
|
||||
);
|
||||
} else {
|
||||
clearInterval(timer);
|
||||
}
|
||||
}, 1000);
|
||||
onUnmounted(() => {
|
||||
clearInterval(timer);
|
||||
});
|
||||
const state = reactive({
|
||||
ballot: [
|
||||
{
|
||||
id: 1,
|
||||
content: "录播课",
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
content: "PPT+配音",
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
content: "HTML5",
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
content: "OTHER",
|
||||
},
|
||||
],
|
||||
});
|
||||
|
||||
const getId = (id) => {
|
||||
console.log(id);
|
||||
};
|
||||
</script>
|
||||
|
||||
@@ -148,6 +200,7 @@ export default {
|
||||
width: 100%;
|
||||
|
||||
.notice {
|
||||
margin-top: 10px;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
<template>
|
||||
<div class="discusspage">
|
||||
<ReturnHead text="讨论详情"></ReturnHead>
|
||||
<div class="head clearfix">
|
||||
<div class="title">
|
||||
请基于公司战略方向和你所负责的组织业务发展,识别3个你和你的团队在未来3年的新的能力与技能要求
|
||||
</div>
|
||||
<div class="title">{}</div>
|
||||
</div>
|
||||
|
||||
<div class="preview">
|
||||
@@ -75,75 +74,83 @@
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
<script setup>
|
||||
import { reactive, toRefs } from "vue";
|
||||
// import TitleHead from "@/components/TitleHead.vue";
|
||||
export default {
|
||||
name: "DiscussPage",
|
||||
components: {},
|
||||
setup() {
|
||||
const state = reactive({
|
||||
onfo: true,
|
||||
discuss: [
|
||||
{
|
||||
id: 1,
|
||||
title: "从营销角度分析:我的团队需要这些能力",
|
||||
contain:
|
||||
"所谓团队协作能力,是指建立在团队的基础之上,发挥团队精神、互补互助以达到团队最大工作效率的能力。对于团队的成员来说...",
|
||||
import ReturnHead from "@/components/ReturnHead.vue";
|
||||
import { request, useRequest } from "@/api/request";
|
||||
import { useRoute } from "vue-router/dist/vue-router";
|
||||
import { useRouter } from "vue-router";
|
||||
import { ElMessage } from "element-plus";
|
||||
import {
|
||||
COMMENT_COLLECTION,
|
||||
COMMENT_PRAISE,
|
||||
DISCUSS_LIST,
|
||||
QueryDiscussSubmitDetailByDiscussId,
|
||||
} from "@/api/api";
|
||||
|
||||
pinglun: 317,
|
||||
dianzan: 103,
|
||||
isGood: false,
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
title: "从营销角度分析:我的团队需要这些能力",
|
||||
contain:
|
||||
"所谓团队协作能力,是指建立在团队的基础之上,发挥团队精神、互补互助以达到团队最大工作效率的能力。对于团队的成员来说...",
|
||||
const state = reactive({
|
||||
onfo: true,
|
||||
discuss: [
|
||||
{
|
||||
id: 1,
|
||||
title: "从营销角度分析:我的团队需要这些能力",
|
||||
contain:
|
||||
"所谓团队协作能力,是指建立在团队的基础之上,发挥团队精神、互补互助以达到团队最大工作效率的能力。对于团队的成员来说...",
|
||||
|
||||
pinglun: 317,
|
||||
dianzan: 103,
|
||||
isGood: false,
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
title: "从营销角度分析:我的团队需要这些能力",
|
||||
contain:
|
||||
"所谓团队协作能力,是指建立在团队的基础之上,发挥团队精神、互补互助以达到团队最大工作效率的能力。对于团队的成员来说...",
|
||||
pinglun: 317,
|
||||
dianzan: 103,
|
||||
isGood: false,
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
title: "从营销角度分析:我的团队需要这些能力",
|
||||
contain:
|
||||
"所谓团队协作能力,是指建立在团队的基础之上,发挥团队精神、互补互助以达到团队最大工作效率的能力。对于团队的成员来说...",
|
||||
|
||||
pinglun: 317,
|
||||
dianzan: 103,
|
||||
isGood: false,
|
||||
},
|
||||
],
|
||||
});
|
||||
const changee = () => {
|
||||
if (state.onfo !== true) {
|
||||
state.onfo = !state.onfo;
|
||||
}
|
||||
};
|
||||
const changeee = () => {
|
||||
if (state.onfo == true) {
|
||||
state.onfo = !state.onfo;
|
||||
}
|
||||
};
|
||||
const getId = (it) => {
|
||||
it.isGood = !it.isGood;
|
||||
if (it.isGood) {
|
||||
it.dianzan++;
|
||||
} else {
|
||||
it.dianzan--;
|
||||
}
|
||||
// console.log(it.isGood);
|
||||
};
|
||||
return {
|
||||
...toRefs(state),
|
||||
changee,
|
||||
changeee,
|
||||
getId,
|
||||
};
|
||||
},
|
||||
pinglun: 317,
|
||||
dianzan: 103,
|
||||
isGood: false,
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
title: "从营销角度分析:我的团队需要这些能力",
|
||||
contain:
|
||||
"所谓团队协作能力,是指建立在团队的基础之上,发挥团队精神、互补互助以达到团队最大工作效率的能力。对于团队的成员来说...",
|
||||
|
||||
pinglun: 317,
|
||||
dianzan: 103,
|
||||
isGood: false,
|
||||
},
|
||||
],
|
||||
});
|
||||
const { onfo, discuss } = toRefs(state);
|
||||
const changee = () => {
|
||||
if (state.onfo !== true) {
|
||||
state.onfo = !state.onfo;
|
||||
}
|
||||
};
|
||||
const changeee = () => {
|
||||
if (state.onfo == true) {
|
||||
state.onfo = !state.onfo;
|
||||
}
|
||||
};
|
||||
const getId = (it) => {
|
||||
it.isGood = !it.isGood;
|
||||
if (it.isGood) {
|
||||
it.dianzan++;
|
||||
} else {
|
||||
it.dianzan--;
|
||||
}
|
||||
// console.log(it.isGood);
|
||||
};
|
||||
|
||||
//获取讨论详情
|
||||
const {
|
||||
query: { id, type },
|
||||
} = useRoute();
|
||||
const { data } = useRequest(DISCUSS_LIST, { id: 23, type });
|
||||
console.log("获取讨论", data);
|
||||
</script>
|
||||
|
||||
<!-- Add "scoped" attribute to limit CSS to this component only -->
|
||||
@@ -157,7 +164,7 @@ export default {
|
||||
.discusspage {
|
||||
width: 100%;
|
||||
.head {
|
||||
margin-top: 20px;
|
||||
margin-top: 10px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
width: 100%;
|
||||
|
||||
@@ -21,11 +21,11 @@
|
||||
<div class="avaname">{{ data.userInfoBo?.userName }}</div>
|
||||
</div> -->
|
||||
<div class="mani">
|
||||
<div class="joininfo">【测评】{{ data?.linkName }}</div>
|
||||
<div class="joininfo">【测评】{{ data?.evaluationName }}</div>
|
||||
<div class="contenttitle">
|
||||
<img class="timeimg" src="../../assets/image/ballotpage/time.png" />
|
||||
<div class="timee">
|
||||
{{ data?.liveStartTime + " 至 " + data?.liveEndTime }}
|
||||
{{ data?.evaluationStartTime + " 至 " + data?.evaluationEndTime }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="timebox">
|
||||
@@ -54,7 +54,7 @@
|
||||
<div class="line"></div>
|
||||
<div class="contentone">
|
||||
<div class="actinner">
|
||||
{{ data.linkDescription }}
|
||||
{{ data?.evaluationExplain }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -71,7 +71,7 @@ import ReturnHead from "@/components/ReturnHead.vue";
|
||||
import { computed, reactive, toRefs, onUnmounted, ref } from "vue";
|
||||
import img from "@/assets/image/uploadimg.png";
|
||||
import { request, useRequest } from "@/api/request";
|
||||
import { LINK_DETAILS, STUDY_RECORD } from "@/api/api";
|
||||
import { EVALUATION_DETAIL, STUDY_RECORD } from "@/api/api";
|
||||
import { useRoute } from "vue-router/dist/vue-router";
|
||||
import { useRouter } from "vue-router";
|
||||
import { useUserInfo } from "@/api/utils";
|
||||
@@ -79,31 +79,47 @@ import { ElMessage } from "element-plus";
|
||||
import dayjs from "dayjs";
|
||||
|
||||
const {
|
||||
query: {
|
||||
courseId: linkId,
|
||||
id: taskId,
|
||||
type,
|
||||
status,
|
||||
chapterOrStageId,
|
||||
infoId,
|
||||
studentId,
|
||||
},
|
||||
query: { courseId: evaluationId, evaType, targetId },
|
||||
} = useRoute();
|
||||
const router = useRouter();
|
||||
console.log("外链信息", linkId);
|
||||
const { data } = useRequest(LINK_DETAILS(linkId));
|
||||
console.log("外链信息", data);
|
||||
const { data } = useRequest(EVALUATION_DETAIL(evaluationId));
|
||||
console.log("测评信息222", data);
|
||||
//作业倒计时
|
||||
let hour = ref(0);
|
||||
let minute = ref(0);
|
||||
let seconds = ref(0);
|
||||
let timer = setInterval(() => {
|
||||
let endTime = parseInt(
|
||||
new Date(data.value.evaluationEndTime).getTime() / 1000
|
||||
);
|
||||
let nowTime = parseInt(new Date().getTime() / 1000);
|
||||
if (endTime > nowTime) {
|
||||
hour.value = parseInt(
|
||||
dayjs(data.value.evaluationEndTime).diff(dayjs(), "minute") / 60
|
||||
);
|
||||
minute.value = parseInt(
|
||||
dayjs(data.value.evaluationEndTime).diff(dayjs(), "minute") % 60
|
||||
);
|
||||
seconds.value = parseInt(
|
||||
dayjs(data.value.evaluationEndTime).diff(dayjs(), "seconds") -
|
||||
(hour.value * 60 + minute.value) * 60
|
||||
);
|
||||
} else {
|
||||
clearInterval(timer);
|
||||
}
|
||||
}, 1000);
|
||||
onUnmounted(() => {
|
||||
clearInterval(timer);
|
||||
});
|
||||
const goOuterChain = () => {
|
||||
status != 1 &&
|
||||
request(STUDY_RECORD, {
|
||||
studentId: studentId,
|
||||
targetId: infoId,
|
||||
logo: type,
|
||||
stageOrChapterId: chapterOrStageId,
|
||||
taskId: taskId,
|
||||
});
|
||||
|
||||
window.open(data.value.linkAddress, "_top");
|
||||
window.open(
|
||||
evaType == 0
|
||||
? import.meta.env.VITE_BOE_TEST_DETAIL_URL + targetId
|
||||
: import.meta.env.VITE_BOE_TEST_OUT_DETAIL_URL +
|
||||
targetId +
|
||||
`&quizTaskKid=${routerId}&channelCode=learningpath`,
|
||||
"_top"
|
||||
); //测评
|
||||
};
|
||||
</script>
|
||||
|
||||
|
||||
@@ -191,15 +191,16 @@ const types = ref({
|
||||
// 7: ({ targetId }) => window.open(targetId, "_top"), //外联
|
||||
8: "/discusspage",
|
||||
9: "/activitiespage",
|
||||
10: ({ evaType, targetId }) =>
|
||||
window.open(
|
||||
evaType == 0
|
||||
? import.meta.env.VITE_BOE_TEST_DETAIL_URL + targetId
|
||||
: import.meta.env.VITE_BOE_TEST_OUT_DETAIL_URL +
|
||||
targetId +
|
||||
`&quizTaskKid=${routerId}&channelCode=learningpath`,
|
||||
"_top"
|
||||
), //测评
|
||||
// 10: ({ evaType, targetId }) =>
|
||||
// window.open(
|
||||
// evaType == 0
|
||||
// ? import.meta.env.VITE_BOE_TEST_DETAIL_URL + targetId
|
||||
// : import.meta.env.VITE_BOE_TEST_OUT_DETAIL_URL +
|
||||
// targetId +
|
||||
// `&quizTaskKid=${routerId}&channelCode=learningpath`,
|
||||
// "_top"
|
||||
// ), //测评
|
||||
10: "/evaluation", //测评
|
||||
11: "/investigatpage",
|
||||
12: "/ballotpage",
|
||||
13: "/projectdetails",
|
||||
@@ -299,7 +300,7 @@ function toFinish(d) {
|
||||
taskId: d.routerTaskId,
|
||||
});
|
||||
}
|
||||
console.log("点击跳转");
|
||||
console.log("点击跳转", d);
|
||||
if (typeof types.value.path[d.type] === "string") {
|
||||
types.value.path[d.type] &&
|
||||
types.value.path[d.type].startsWith("http") &&
|
||||
@@ -318,6 +319,8 @@ function toFinish(d) {
|
||||
chapterOrStageId: data.value.currentStageId,
|
||||
studentId: userInfo.value.id,
|
||||
status: d.status,
|
||||
targetId: d.targetId,
|
||||
evaType: d.evaType,
|
||||
},
|
||||
});
|
||||
} else if (typeof types.value.path[d.type] === "function") {
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2023-01-19 11:28:11
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2023-01-31 18:01:11
|
||||
* @LastEditTime: 2023-02-02 16:42:01
|
||||
* @FilePath: /stu_h5/src/views/projectdetails/ProjectPath.vue
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
-->
|
||||
@@ -179,14 +179,14 @@ const handleClick = (tab, event) => {
|
||||
console.log("selectTab", selectTab.value);
|
||||
};
|
||||
const goDetails = () => {
|
||||
// router.push({
|
||||
// path: "/levelList",
|
||||
// query: { routerId: 2 },
|
||||
// });
|
||||
router.push({
|
||||
path: "/projectdetails",
|
||||
query: { projectId: 3 },
|
||||
path: "/pathmappage",
|
||||
query: { routerId: 2 },
|
||||
});
|
||||
// router.push({
|
||||
// path: "/projectdetails",
|
||||
// query: { projectId: 3 },
|
||||
// });
|
||||
};
|
||||
</script>
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2023-01-13 11:42:48
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2023-01-13 18:18:01
|
||||
* @LastEditTime: 2023-02-02 17:45:36
|
||||
* @FilePath: /stu_h5/vite.config.js
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
*/
|
||||
@@ -101,6 +101,11 @@ export default defineConfig(({ command, mode }) =>
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/evaluation/queryEvaluationDetailById': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
},
|
||||
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user