|
@@ -42,7 +42,17 @@ const state: anyObj = reactive({
|
|
|
const itemClick = (type: 'training' | 'report' | 'report_share') => {
|
|
|
|
|
|
if (type == 'training') {
|
|
|
- router.push({ path: `/train/chapter/${state.taskId}/${state.trainSelf.id}` });
|
|
|
+ router.push({ path: `/train/chapter/${state.taskId}/${state.trainSelf.id}` })
|
|
|
+ .then(() => {
|
|
|
+ // console.log("路由跳转完成了 ===>");
|
|
|
+ /**
|
|
|
+ * 由于 router.push 跳转页面,会导致来回切换三维场景存留一些其他参数
|
|
|
+ * 导致第一次进入三维界面是正常的,退回,切换回来,三维场景会出现报错
|
|
|
+ * 所以,这里切换到三维场景,要进行整个页面刷新一下
|
|
|
+ * 就可以解决这个问题,让它正常运行
|
|
|
+ */
|
|
|
+ window.location.reload();
|
|
|
+ });
|
|
|
}
|
|
|
|
|
|
if (type == 'report') {
|
|
@@ -52,7 +62,7 @@ const itemClick = (type: 'training' | 'report' | 'report_share') => {
|
|
|
if (type == 'report_share') {
|
|
|
router.push({ path: `/train/share/${state.taskId}` });
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
};
|
|
|
|
|
|
onMounted(() => {
|