瀏覽代碼

fix:bug修复

廖彦舟 1 年之前
父節點
當前提交
9022994803

+ 3 - 3
src/router/index.ts

@@ -208,9 +208,9 @@ const router = createRouter({
         }
 
         // 如果当前路径是公开路径,允许继续;否则跳转到首页
-        if (!publicPaths.includes(to.path)) {
-            return '/home';
-        }
+        // if (!publicPaths.includes(to.path)) {
+        //     return '/home';
+        // }
     } catch (error) {
         console.error('Token验证失败:', error);
         // 验证失败,清除无效的 token

+ 2 - 2
src/views/CourseSquare/component/CourseDetails/component/CourseHomeworkTable.vue

@@ -263,9 +263,9 @@ const openEditor = (url: string, title: string) => {
       handleWriting(assignmentId)
     } else if(props.role == 'teachers'){
       changeDialog('edit', assignmentId, type)
-      if(type === '写作'){
+      if(type === '写作' || type == 'writing'){
         writingVisible.value = true;
-      } else if(type === 'AI口语'){
+      } else if(type === 'AI口语' || type == 'speaking'){
         AISpeakingVisible.value =true;
       }
     }