@jx3box/jx3box-common-ui 8.8.4 → 8.8.6
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
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<b>{{left}}</b>
|
|
13
13
|
<!-- <a class="u-charge" :href="chargeLink" target="_blank">[充值]</a> -->
|
|
14
14
|
</div>
|
|
15
|
-
<el-radio-group class="u-homework-type" v-model="type" size="small" v-if="
|
|
15
|
+
<el-radio-group class="u-homework-type" v-model="type" size="small" v-if="hasPermission">
|
|
16
16
|
<el-radio-button label="reward">打赏</el-radio-button>
|
|
17
17
|
<el-radio-button label="grant">品鉴</el-radio-button>
|
|
18
18
|
</el-radio-group>
|
|
@@ -91,8 +91,8 @@ export default {
|
|
|
91
91
|
left() {
|
|
92
92
|
return this.type === "reward" ? this.user_left : this.admin_left;
|
|
93
93
|
},
|
|
94
|
-
|
|
95
|
-
return User.
|
|
94
|
+
hasPermission() {
|
|
95
|
+
return User.hasPermission('manage_bbs_reward');
|
|
96
96
|
},
|
|
97
97
|
total: function () {
|
|
98
98
|
return this.admin_total;
|
|
@@ -73,6 +73,7 @@ export default {
|
|
|
73
73
|
"total",
|
|
74
74
|
"max",
|
|
75
75
|
"min",
|
|
76
|
+
"category"
|
|
76
77
|
],
|
|
77
78
|
components: {
|
|
78
79
|
Contributors,
|
|
@@ -136,6 +137,7 @@ export default {
|
|
|
136
137
|
items: this.items,
|
|
137
138
|
remark: this.remark,
|
|
138
139
|
client: client,
|
|
140
|
+
category: this.category,
|
|
139
141
|
})
|
|
140
142
|
.then((res) => {
|
|
141
143
|
return res.data.data;
|
|
@@ -59,7 +59,7 @@ import { getBreadcrumb } from "@jx3box/jx3box-common/js/api_misc";
|
|
|
59
59
|
import Contributors from './Contributors.vue';
|
|
60
60
|
export default {
|
|
61
61
|
name: "BoxcoinAdmin",
|
|
62
|
-
props: ["postType", "postId", "userId", "own", "total", "points", "max", "min", 'authors','client'],
|
|
62
|
+
props: ["postType", "postId", "userId", "own", "total", "points", "max", "min", 'authors','client',"category"],
|
|
63
63
|
components: {
|
|
64
64
|
Contributors
|
|
65
65
|
},
|
|
@@ -145,7 +145,9 @@ export default {
|
|
|
145
145
|
}
|
|
146
146
|
grantBoxcoin(this.postType, this.postId, this.chosen || this.userId, count, {
|
|
147
147
|
remark: this.remark,
|
|
148
|
-
client : client
|
|
148
|
+
client : client,
|
|
149
|
+
// 如果有category,传入category
|
|
150
|
+
category : this.category
|
|
149
151
|
})
|
|
150
152
|
.then((res) => {
|
|
151
153
|
this.$message({
|
|
@@ -54,7 +54,7 @@ import Contributors from './Contributors.vue';
|
|
|
54
54
|
import _ from "lodash";
|
|
55
55
|
export default {
|
|
56
56
|
name: "BoxcoinUser",
|
|
57
|
-
props: ["boxcoin", "postType", "postId", "userId", "own", "points", "authors",'client'],
|
|
57
|
+
props: ["boxcoin", "postType", "postId", "userId", "own", "points", "authors",'client',"category"],
|
|
58
58
|
components: {
|
|
59
59
|
Contributors
|
|
60
60
|
},
|
|
@@ -130,7 +130,8 @@ export default {
|
|
|
130
130
|
}
|
|
131
131
|
rewardBoxcoin(this.postType, this.postId, this.chosen || this.userId, count, {
|
|
132
132
|
remark: this.remark,
|
|
133
|
-
client: client
|
|
133
|
+
client: client,
|
|
134
|
+
category: this.category
|
|
134
135
|
})
|
|
135
136
|
.then((res) => {
|
|
136
137
|
this.$message({
|
package/src/single/Thx.vue
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
<template v-if="type === 'batchReward'">
|
|
4
4
|
<!-- 批量打赏 -->
|
|
5
5
|
<batch-reward
|
|
6
|
+
v-if="hasRight && adminBoxcoinEnable && boxcoin_enable"
|
|
6
7
|
:postType="postType"
|
|
7
8
|
:items="postId"
|
|
8
9
|
:boxcoin="boxcoin"
|
|
@@ -11,19 +12,19 @@
|
|
|
11
12
|
:points="admin_points"
|
|
12
13
|
:authors="authors"
|
|
13
14
|
:client="finalClient"
|
|
14
|
-
v-if="hasRight && adminBoxcoinEnable && boxcoin_enable"
|
|
15
15
|
:max="admin_max"
|
|
16
16
|
:min="admin_min"
|
|
17
17
|
:total="admin_total"
|
|
18
|
+
:category="category"
|
|
18
19
|
@updateRecord="updateRecord"
|
|
19
20
|
/>
|
|
20
21
|
</template>
|
|
21
22
|
<template v-else>
|
|
22
23
|
<div class="w-thx-panel">
|
|
23
24
|
<boxcoin-admin
|
|
25
|
+
v-if="hasRight && adminBoxcoinEnable && boxcoin_enable"
|
|
24
26
|
:postId="postId"
|
|
25
27
|
:postType="postType"
|
|
26
|
-
v-if="hasRight && adminBoxcoinEnable && boxcoin_enable"
|
|
27
28
|
:userId="userId"
|
|
28
29
|
:max="admin_max"
|
|
29
30
|
:min="admin_min"
|
|
@@ -31,12 +32,14 @@
|
|
|
31
32
|
:total="admin_total"
|
|
32
33
|
:points="admin_points"
|
|
33
34
|
:authors="authors"
|
|
34
|
-
@updateRecord="updateRecord"
|
|
35
35
|
:client="finalClient"
|
|
36
|
+
:category="category"
|
|
37
|
+
@updateRecord="updateRecord"
|
|
36
38
|
/>
|
|
37
39
|
<Like :postId="postId" :postType="postType"></Like>
|
|
38
40
|
<fav :postId="postId" :postType="postType" :postTitle="postTitle"></fav>
|
|
39
41
|
<boxcoin-user
|
|
42
|
+
v-if="userBoxcoinEnable && boxcoin_enable && allowGift"
|
|
40
43
|
:postId="postId"
|
|
41
44
|
:postType="postType"
|
|
42
45
|
:boxcoin="boxcoin"
|
|
@@ -44,9 +47,9 @@
|
|
|
44
47
|
:own="user_left"
|
|
45
48
|
:points="user_points"
|
|
46
49
|
:authors="authors"
|
|
47
|
-
v-if="userBoxcoinEnable && boxcoin_enable && allowGift"
|
|
48
|
-
@updateRecord="updateRecord"
|
|
49
50
|
:client="finalClient"
|
|
51
|
+
:category="category"
|
|
52
|
+
@updateRecord="updateRecord"
|
|
50
53
|
/>
|
|
51
54
|
<Share :postId="postId" :postType="postType" :client="client" />
|
|
52
55
|
</div>
|
|
@@ -125,6 +128,9 @@ export default {
|
|
|
125
128
|
type: Boolean,
|
|
126
129
|
default: false,
|
|
127
130
|
},
|
|
131
|
+
category: {
|
|
132
|
+
default: undefined,
|
|
133
|
+
},
|
|
128
134
|
},
|
|
129
135
|
components: {
|
|
130
136
|
Like,
|