Browse Source

feat: fix

gemercheung 6 tháng trước cách đây
mục cha
commit
ef4b3379a0

+ 1 - 1
packages/backend/src/modules/web/web.service.ts

@@ -75,7 +75,7 @@ export class WebService {
     });
     if (!article) {
       return false;
-    };
+    }
     article.readCount = article.readCount + 1;
     // console.log('article', article);
     await this.articleRepo.save(article);

+ 1 - 0
packages/frontend/src/views/article/index.vue

@@ -55,6 +55,7 @@ const { handleDelete }
   })
 
 const columns = [
+  { title: 'ID', key: 'id', width: '80' },
   { title: '标题', key: 'title', width: '200' },
   { title: '分类', key: 'category.title' },
   {

+ 4 - 2
packages/web/src/pages/showdoc/[id].vue

@@ -33,7 +33,8 @@
           <div class="w-full content-html" v-html="detail.content"></div>
           <div class="w-full flex justify-between pt-6 bt-1px_#EBEBEB color-[#999898]">
             <div class="prev flex flex-col">
-              <span class="flex-1 text-align-left">
+              <span class="flex-1 text-align-left" :class="{ articleNear: articleNear[0] }"
+                @click="handleToArticle(articleNear[0])">
                 {{ $t('prev_article') }} </span>
               <span class="flex-1 articleNear" v-if="articleNear[0]" @click="handleToArticle(articleNear[0])">
                 {{ articleNear[0].title }}
@@ -44,7 +45,8 @@
 
             </div>
             <div class="next flex flex-col ">
-              <span class="flex-1 text-align-right">
+              <span class="flex-1  text-align-right" :class="{ articleNear: articleNear[1] }"
+                @click="handleToArticle(articleNear[1])">
                 {{ $t('next_article') }}
               </span>
               <span class="flex-1 articleNear" v-if="articleNear[1]" @click="handleToArticle(articleNear[1])">