diff --git a/src/api/CONST.js b/src/api/CONST.js index b127de7..5224c3a 100644 --- a/src/api/CONST.js +++ b/src/api/CONST.js @@ -45,9 +45,9 @@ export const TASK_TYPES = { path: { // 增加异步防止ios阻止弹窗弹出 - 1: ({ courseId }) => setTimeout(() => { window.open(window.location.protocol + import.meta.env.VITE_BOE_ONLINE_CLASS_URL + courseId) }), //在线 + 1: ({ courseId }) => setTimeout(() => { window.open(window.location.protocol + import.meta.env.VITE_BOE_ONLINE_CLASS_URL + courseId, '_top') }), //在线 2: ({ targetId }) => setTimeout(() => { window.open(`${location.protocol}//${location.host}${import.meta.env.VITE_BASE_API}/stu/project/redirectDetail?courseId=${targetId}`, '_top') }), - 3: ({ courseId }) => setTimeout(() => { window.open(window.location.protocol + import.meta.env.VITE_BOE_CASS_DETAIL_URL + courseId) }), //案例 + 3: ({ courseId }) => setTimeout(() => { window.open(window.location.protocol + import.meta.env.VITE_BOE_CASS_DETAIL_URL + courseId, '_top') }), //案例 4: "/homeworkpage", 5: ({ examType }) => examType === 2 ? '/externalexam' : (window.location.protocol + import.meta.env.VITE_BOE_EXAM_DETAIL_URL), //考试 6: "/liveboradcast", diff --git a/src/views/projectdetails/projectDetails.vue b/src/views/projectdetails/projectDetails.vue index 6b3e6f5..812b20a 100644 --- a/src/views/projectdetails/projectDetails.vue +++ b/src/views/projectdetails/projectDetails.vue @@ -822,26 +822,8 @@ function toFinish(d, sName, chapterOrStageId, studyModel) { // } } -function isIOS() { - return [ - 'iPad Simulator', - 'iPhone Simulator', - 'iPod Simulator', - 'iPad', - 'iPhone', - 'iPod' - ].includes(navigator.platform) || - // iPad on iOS 13 detection - (navigator.userAgent.includes("Mac") && "ontouchend" in document); -} - -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) {