mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/student-h5.git
synced 2025-12-06 17:36:45 +08:00
fix: 测试苹果手机按钮点开其他网页不生效的问题
This commit is contained in:
@@ -675,7 +675,15 @@ function toFinish(d, sName, chapterOrStageId,studyModel) {
|
|||||||
});
|
});
|
||||||
} else if (typeof TASK_TYPES.path[d.type] === "function") {
|
} else if (typeof TASK_TYPES.path[d.type] === "function") {
|
||||||
if (d.type == 5) {
|
if (d.type == 5) {
|
||||||
window.open(TASK_TYPES.path[d.type](d) + d.targetId, "_top");
|
// 模拟点击跳转
|
||||||
|
const url = TASK_TYPES.path[d.type](d) + d.targetId
|
||||||
|
const a = document.createElement("a");
|
||||||
|
a.href = url;
|
||||||
|
a.target = "_blank";
|
||||||
|
a.click();
|
||||||
|
|
||||||
|
// 保底解决兼容问题
|
||||||
|
window.open(url, "_top");
|
||||||
} else {
|
} else {
|
||||||
TASK_TYPES.path[d.type](d);
|
TASK_TYPES.path[d.type](d);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user