From 6598c91e61d17bda404c39a7e5a2a30257c64fdc Mon Sep 17 00:00:00 2001 From: ruibaby Date: Tue, 27 Aug 2019 12:30:53 +0800 Subject: [PATCH] Support journal type. --- src/api/journal.js | 9 ++ src/views/post/PostList.vue | 5 +- src/views/sheet/internal/JournalList.vue | 157 ++++++++++++++++++----- 3 files changed, 136 insertions(+), 35 deletions(-) diff --git a/src/api/journal.js b/src/api/journal.js index 2f94d715c..09786d1ee 100644 --- a/src/api/journal.js +++ b/src/api/journal.js @@ -42,4 +42,13 @@ journalApi.commentTree = journalId => { }) } +journalApi.journalType = { + PUBLIC: { + text: '公开' + }, + PRIVATE: { + text: '私密' + } +} + export default journalApi diff --git a/src/views/post/PostList.vue b/src/views/post/PostList.vue index f9f2894ef..c565b2d7f 100644 --- a/src/views/post/PostList.vue +++ b/src/views/post/PostList.vue @@ -169,6 +169,7 @@ v-for="(category,index) in categoriesOfPost" :key="index" color="blue" + style="margin-bottom: 8px" >{{ category.name }} @@ -180,6 +181,7 @@ v-for="(tag, index) in tags" :key="index" color="green" + style="margin-bottom: 8px" >{{ tag.name }} @@ -313,7 +315,8 @@ const columns = [ dataIndex: 'commentCount' }, { - title: '访问量', + title: '访问', + width: '70px', dataIndex: 'visits' }, { diff --git a/src/views/sheet/internal/JournalList.vue b/src/views/sheet/internal/JournalList.vue index 7c6b8ccf3..4cc36f0da 100644 --- a/src/views/sheet/internal/JournalList.vue +++ b/src/views/sheet/internal/JournalList.vue @@ -6,32 +6,57 @@
- + - + - - + + - 查询 - 重置 + 查询 + 重置
- 写日志 + 写日志
- +
- + - + - + {{ item.likes }} - - + + {{ item.commentCount }} @@ -77,8 +119,11 @@ -->