jufubao-base 1.0.159-beta18 → 1.0.159-beta20

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": "jufubao-base",
3
- "version": "1.0.159-beta18",
3
+ "version": "1.0.159-beta20",
4
4
  "private": false,
5
5
  "description": "聚福宝业务组件基础插件包",
6
6
  "main": "index.js",
@@ -177,9 +177,15 @@ export default {
177
177
  return this.valueKey.filter(item => item.key !== "end_time");
178
178
  }
179
179
  return this.valueKey;
180
- }
180
+ },
181
+ container(value,oldValue) {
182
+ if(JSON.stringify(value) === JSON.stringify(oldValue)) return;
183
+ if (this.$configProject['isPreview']) this.init(value)
184
+ },
185
+ },
186
+ created() {
187
+ this.init(this.container)
181
188
  },
182
- created() {},
183
189
  methods: {
184
190
  handleIcon(){
185
191
  this.isPassword = !this.isPassword
@@ -270,39 +276,37 @@ export default {
270
276
  }
271
277
  })
272
278
  },
273
- init() {
274
- this.backUrl = getContainerPropsValue(
275
- this.container,
276
- "content.back_url",
277
- { value: "/pages/card/card" }
278
- ).value;
279
- this.card_num_placeholder = getContainerPropsValue(
280
- this.container,
281
- "content.card_num_placeholder",
282
- "请输入券号(电子券除外)"
283
- );
284
- this.card_pwd_placeholder = getContainerPropsValue(
285
- this.container,
286
- "content.card_pwd_placeholder",
287
- "请输入密码"
288
- );
289
- this.is_show_balance = getContainerPropsValue(this.container, 'content.is_show_balance', "N");
290
- this.my_card_url = getContainerPropsValue(this.container, 'content.my_card_url', { value: "" }).value;
279
+ init(container) {
280
+ this.backUrl = getContainerPropsValue(container, "content.back_url", { value: "/pages/card/card" }).value;
281
+ this.card_num_placeholder = getContainerPropsValue(container, "content.card_num_placeholder", "请输入券号(电子券除外)");
282
+ this.card_pwd_placeholder = getContainerPropsValue(container, "content.card_pwd_placeholder", "请输入密码");
283
+ this.is_show_balance = getContainerPropsValue(container, 'content.is_show_balance', "N");
284
+ this.my_card_url = getContainerPropsValue(container, 'content.my_card_url', { value: "" }).value;
291
285
  },
292
286
  onJfbLoad(options) {
293
- this.init();
294
-
295
- this.qrcode = options.qrcode;
287
+ this.qrcode = options.qrcode || options.pa;
296
288
 
297
289
  //#ifdef MP-WEIXIN
298
- if(options.qrcode) {
299
- this.qrcode = decodeURIComponent(options.qrcode);
290
+ if(this.qrcode) {
291
+ this.qrcode = decodeURIComponent(this.qrcode);
300
292
  }
301
293
  //#endif
302
294
 
303
295
  if(options.inCallback) {
304
296
  this.inCallbackUrlOrg = options.inCallback;
305
297
  }
298
+
299
+ //正式环境判断参数错误
300
+ if(!this.$configProject.isPreview) {
301
+ if(!this.qrcode) {
302
+ this.$xdAlert({
303
+ content: '参数配置错误',
304
+ type: 'error'
305
+ });
306
+ return
307
+ }
308
+ }
309
+
306
310
  if (this.qrcode) {
307
311
  jfbRootExec("getByQrCardDetail", {
308
312
  vm: this,
@@ -302,17 +302,29 @@ export default {
302
302
  this.entryGroupId = getContainerPropsValue(container,"content.entryGroupId","default");
303
303
  },
304
304
  onJfbLoad(options) {
305
- this.qrcode = options.qrcode;
305
+ this.qrcode = options.qrcode || options.pa;
306
306
 
307
307
  //#ifdef MP-WEIXIN
308
- if(options.qrcode) {
309
- this.qrcode = decodeURIComponent(options.qrcode);
308
+ if(this.qrcode) {
309
+ this.qrcode = decodeURIComponent(this.qrcode);
310
310
  }
311
311
  //#endif
312
312
 
313
313
  if(options.inCallback) {
314
314
  this.inCallbackUrlOrg = options.inCallback;
315
315
  }
316
+
317
+ //正式环境判断参数错误
318
+ if(!this.$configProject.isPreview) {
319
+ if(!this.qrcode) {
320
+ this.$xdAlert({
321
+ content: '参数配置错误',
322
+ type: 'error'
323
+ });
324
+ return
325
+ }
326
+ }
327
+
316
328
  if (this.qrcode) {
317
329
  jfbRootExec("getByQrCardDetailEntry", {
318
330
  vm: this,
@@ -10,9 +10,7 @@
10
10
  :class="{ editx: isEditx && active }"
11
11
  v-if="isEditx && active"
12
12
  >
13
- <view class="jfb-base-card-sweep-info__edit-icon" @click="delEdit"
14
- >删除</view
15
- >
13
+ <view class="jfb-base-card-sweep-info__edit-icon" @click="delEdit">删除</view>
16
14
  </view>
17
15
  <!-- #endif -->
18
16
  <view class="jfb-base-card-sweep-info__body" style="position: relative">
@@ -186,6 +184,7 @@ export default {
186
184
  },
187
185
  onJfbLoad(options) {
188
186
  this.pa = options.pa;
187
+
189
188
  if(options.inCallback) {
190
189
  this.inCallbackUrlOrg = options.inCallback;
191
190
  }
@@ -273,7 +273,7 @@
273
273
  </view>
274
274
 
275
275
  <view v-if="info.codes[0].can_read_password" class="jfb-base-order-detail__body-cashier-password" @click="showPassword = true">
276
- {{ showPassword ? info.codes[0].can_read_code : "查看密码" }}
276
+ {{ showPassword ? info.codes[0].can_read_code : "查看" }}
277
277
  </view>
278
278
  <view v-else class="jfb-base-order-detail__body-cashier-text">
279
279
  {{ info.codes[0].can_read_code }}
@@ -387,7 +387,7 @@
387
387
  <view
388
388
  class="jfb-base-order-detail__body-num-info-copy"
389
389
  style="margin-top: 0;"
390
- @click="handleShowCode(item)">查看二维码和密码</view>
390
+ @click="handleShowCode(item)">查看二维码和{{ item.password_title }}</view>
391
391
  <view
392
392
  v-if="item.code_end_time"
393
393
  class="jfb-base-order-detail__body-cashier-code"
@@ -107,7 +107,7 @@
107
107
  class="jfb-base-success__body-cashier-password"
108
108
  @click="showPassword = true"
109
109
  :style="{borderRadius: jfbListRadius + 'rpx', color:btnTextColor, backgroundColor:btnBgColor, borderColor:btnBorderColor}"
110
- >{{ showPassword ? info.codes[0].can_read_code : "查看密码" }}</view>
110
+ >{{ showPassword ? info.codes[0].can_read_code : "查看" }}</view>
111
111
  <view v-else class="jfb-base-success__body-cashier-text">{{ info.codes[0].can_read_code }}</view>
112
112
  <view v-if="info.codes[0].refund_tip_text" style="color:red;font-size:24rpx;text-align:center;margin-top:10rpx">{{info.codes[0].refund_tip_text}}</view>
113
113
  <view
@@ -218,7 +218,7 @@
218
218
  class="jfb-base-success__body-num-info-copy"
219
219
  @click="handleShowCode(item)"
220
220
  :style="{marginTop:0, borderRadius: jfbListRadius + 'rpx', color:btnTextColor, backgroundColor:btnBgColor, borderColor:btnBorderColor}"
221
- >查看二维码和密码</view>
221
+ >查看二维码和{{ item.password_title }}</view>
222
222
  <view
223
223
  v-if="item['code_end_time']"
224
224
  class="jfb-base-success__body-cashier-code"