jwyu пре 3 година
родитељ
комит
46d5342442

+ 1 - 1
src/components/Comment.vue

@@ -24,7 +24,7 @@ const props=defineProps({
 const msgState = reactive({
     show:false,//是否显示评论输入框
     msg:'',
-    hasNickName:store.state.userInfo.nick_name?true:false,//false 匿名
+    hasNickName:store.state.userInfo&&store.state.userInfo.nick_name?true:false,//false 匿名
     like_num:props.data.like_num,
     like_enabled:props.data.like_enabled
 })

+ 1 - 0
src/components/LoginPop.vue

@@ -400,6 +400,7 @@ onMounted(()=>{
         input{
             border: none;
             outline: none;
+            width: 67%;
         }
         .input-item{
             margin-bottom: 20px;

+ 3 - 1
src/utils/interceptRouterMethod.js

@@ -47,7 +47,9 @@ router.push = function push(location) {
     }else{
         console.log('拦截路由push改为返回');
         const _index=index-(store.state.breadCrumbList.length-1)
-        router.go(_index)
+        if(_index!==0){
+            router.go(_index)
+        }
         setTimeout(() => {
             if(query){
                 router.replace({

+ 2 - 1
src/views/report/ChapterDetail.vue

@@ -79,6 +79,7 @@ const getTickerValue=async ()=>{
 let info=ref(null)
 let audioData=ref(null)
 const getChapterReportDetail=async ()=>{
+    console.log(chapterId.value);
     const res=await apiChapterDetail({
         report_chapter_id:Number(chapterId.value)
     })
@@ -226,7 +227,7 @@ onMounted(()=>{
 
 onBeforeRouteUpdate((to,from)=>{
     console.log(to.query);
-    chapterId.value=to.chapterId
+    chapterId.value=to.query.chapterId
     getChapterReportDetail()
     getQRCodeImg()
 })