@jx3box/jx3box-common-ui 8.1.0 → 8.1.2

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-common-ui",
3
- "version": "8.1.0",
3
+ "version": "8.1.2",
4
4
  "description": "JX3BOX UI",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -30,8 +30,8 @@
30
30
  "last 2 versions"
31
31
  ],
32
32
  "dependencies": {
33
- "@jx3box/jx3box-comment-ui": "^1.8.6",
34
- "@jx3box/jx3box-common": "^8.1.9",
33
+ "@jx3box/jx3box-comment-ui": "^1.8.7",
34
+ "@jx3box/jx3box-common": "^8.2.1",
35
35
  "@jx3box/jx3box-data": "^3.5.6",
36
36
  "@jx3box/jx3box-editor": "^2.1.4",
37
37
  "@jx3box/reporter": "^0.0.4",
package/src/App.vue CHANGED
@@ -46,7 +46,7 @@
46
46
  :userId="8"
47
47
  :adminBoxcoinEnable="true"
48
48
  :userBoxcoinEnable="true"
49
- :postId="5575"
49
+ :postId="73440"
50
50
  />
51
51
  <hr />
52
52
  <Like mode="heart" :count="100" :showCount="true" />
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <div class="w-filter-client">
3
3
  <ul>
4
- <li class="u-client" :class="{on: client == ''}" @click="filter('')" v-if="clients">
4
+ <li class="u-client" :class="{on: client == ''}" @click="filter('')">
5
5
  全部
6
6
  </li>
7
7
  <li
@@ -16,14 +16,13 @@
16
16
  </template>
17
17
 
18
18
  <script>
19
- const clients = {
20
- all: "双端",
21
- std: "重制",
19
+ const _clients = {
20
+ std: "旗舰",
22
21
  origin: "缘起",
23
22
  };
24
23
  export default {
25
24
  name: "clientBy",
26
- props: ["type", "clients", "showWujie"],
25
+ props: ["type", "clients", "showWujie","showAll"],
27
26
  data: function () {
28
27
  return {
29
28
  client: this.type || "",
@@ -31,11 +30,18 @@ export default {
31
30
  },
32
31
  computed: {
33
32
  computedClients: function () {
33
+ let clients = this.clients || _clients;
34
34
  if (this.showWujie) {
35
- return Object.assign({}, this.clients || clients, {
35
+ clients = Object.assign({}, clients, {
36
36
  wujie: "无界",
37
37
  });
38
38
  }
39
+ if (this.showAll) {
40
+ clients = Object.assign({}, clients, {
41
+ all: "全端",
42
+ });
43
+ }
44
+ console.log(clients)
39
45
  return clients;
40
46
  },
41
47
  },
@@ -25,7 +25,7 @@ export default {
25
25
  clientThink: false,
26
26
  clients: [
27
27
  {
28
- name: "重制",
28
+ name: "旗舰",
29
29
  client: "std",
30
30
  from: "origin.jx3box.com",
31
31
  to: "www.jx3box.com",
@@ -128,10 +128,14 @@ export default {
128
128
  },
129
129
  submit: function () {
130
130
  this.submitting = true;
131
+ let client = this.client || this.hostClient;
132
+ if (!['std', 'origin', 'all'].includes(client)) {
133
+ client = 'std'
134
+ }
131
135
  batchReward(this.postType, this.count, {
132
136
  items: this.items,
133
137
  remark: this.remark,
134
- client: this.client || this.hostClient,
138
+ client: client,
135
139
  })
136
140
  .then((res) => {
137
141
  return res.data.data;
@@ -139,9 +139,13 @@ export default {
139
139
  submit: function () {
140
140
  this.submitting = true;
141
141
  const count = this.count === "custom" ? this.amount : this.count;
142
+ let client = this.client || this.hostClient;
143
+ if (!['std', 'origin', 'all'].includes(client)) {
144
+ client = 'std'
145
+ }
142
146
  grantBoxcoin(this.postType, this.postId, this.chosen || this.userId, count, {
143
147
  remark: this.remark,
144
- client : this.client || this.hostClient
148
+ client : client
145
149
  })
146
150
  .then((res) => {
147
151
  this.$message({
@@ -123,10 +123,14 @@ export default {
123
123
  this.chosen = userId
124
124
  },
125
125
  submit: function () {
126
- const count = this.count === 'custom' ? this.amount : this.count
126
+ const count = this.count === 'custom' ? this.amount : this.count;
127
+ let client = this.client || this.hostClient;
128
+ if (!['std', 'origin', 'all'].includes(client)) {
129
+ client = 'std'
130
+ }
127
131
  rewardBoxcoin(this.postType, this.postId, this.chosen || this.userId, count, {
128
132
  remark: this.remark,
129
- client : this.client || this.hostClient
133
+ client: client
130
134
  })
131
135
  .then((res) => {
132
136
  this.$message({
@@ -98,7 +98,7 @@ export default {
98
98
  default: "",
99
99
  },
100
100
  userId: {
101
- type: Number,
101
+ type: [Number, String],
102
102
  default: 0,
103
103
  },
104
104
  authors: {