@jx3box/jx3box-ui 2.2.9 → 2.2.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jx3box/jx3box-ui",
3
- "version": "2.2.9",
3
+ "version": "2.2.10",
4
4
  "description": "JX3BOX Vue3 UI",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -79,7 +79,7 @@ export default {
79
79
  });
80
80
  },
81
81
  addFav: function () {
82
- addFav(this.postType, this.postId, this.postTitle).then((res) => {
82
+ addFav(this.postType, this.postId, this.postTitle, this.author_id).then((res) => {
83
83
  this.favorite = res.id;
84
84
  this.total++;
85
85
  });
@@ -46,6 +46,7 @@
46
46
  :userBoxcoinEnable="true"
47
47
  :authors="authors"
48
48
  :client="post_client"
49
+ :authorId="author_id"
49
50
  showRss
50
51
  v-if="showThx"
51
52
  />
@@ -72,6 +73,7 @@
72
73
  :postId="id"
73
74
  :postType="post_type"
74
75
  :postTitle="post_title"
76
+ :authorId="author_id"
75
77
  :showComment="id && allow_comment"
76
78
  @toComment="toComment($event)"
77
79
  ></right-affix>
@@ -1,7 +1,14 @@
1
1
  <template>
2
2
  <div class="c-right-affix" :class="{ 'is-close': !isOpen }">
3
3
  <div class="item">
4
- <fav :postId="postId" :postType="postType" :postTitle="postTitle" :hiddenNum="true" :isOld="true"></fav>
4
+ <fav
5
+ :postId="postId"
6
+ :postType="postType"
7
+ :postTitle="postTitle"
8
+ :hiddenNum="true"
9
+ :isOld="true"
10
+ :author_id="authorId"
11
+ ></fav>
5
12
  </div>
6
13
  <el-tooltip v-if="showCommentBtn && showComment" effect="dark" content="去评论" placement="left">
7
14
  <div class="u-item" @click="toComment">
@@ -38,6 +45,10 @@ export default {
38
45
  type: [Boolean, Number],
39
46
  default: false,
40
47
  },
48
+ authorId: {
49
+ type: [String, Number],
50
+ default: "",
51
+ },
41
52
  },
42
53
  data() {
43
54
  return {
@@ -16,7 +16,7 @@
16
16
  :client="client"
17
17
  />
18
18
  <Like :postId="postId" :postType="postType"></Like>
19
- <fav :postId="postId" :postType="postType" :postTitle="postTitle"></fav>
19
+ <fav :postId="postId" :postType="postType" :postTitle="postTitle" :author_id="userId"></fav>
20
20
  <boxcoin-user
21
21
  :postId="postId"
22
22
  :postType="postType"
@@ -39,8 +39,8 @@
39
39
  :category="category"
40
40
  />
41
41
  <Like :postId="postId" :postType="postType"></Like>
42
- <fav :postId="postId" :postType="postType" :postTitle="postTitle"></fav>
43
- <Rss v-if="showRss" :type="postType" :id="postId" :title="postTitle"></Rss>
42
+ <fav :postId="postId" :postType="postType" :postTitle="postTitle" :author_id="postAuthorId"></fav>
43
+ <Rss v-if="showRss" :type="postType" :id="postId" :title="postTitle" :author_id="postAuthorId"></Rss>
44
44
  <boxcoin-user
45
45
  :postId="postId"
46
46
  :postType="postType"
@@ -58,7 +58,7 @@
58
58
  <watch-later
59
59
  :category="postType"
60
60
  :title="postTitle"
61
- :author-id="authorId"
61
+ :author-id="postAuthorId"
62
62
  :banner="banner"
63
63
  :content-id="contentMetaId"
64
64
  ></watch-later>
@@ -228,6 +228,9 @@ export default {
228
228
  }
229
229
  return this.client;
230
230
  },
231
+ postAuthorId: function () {
232
+ return this.authorId || this.userId;
233
+ },
231
234
  showRecord() {
232
235
  // 当admin_boxcoin_visible为0时,作者本人和64及以上权限可见打赏记录
233
236
  if (this.admin_boxcoin_visible === 0) {