jufubao-base 1.0.61-beta5 → 1.0.62

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.
@@ -16,55 +16,31 @@
16
16
  </view>
17
17
  <!-- #endif -->
18
18
  <view class="jfb-base-card-detail-entry__body" v-if="info!==null">
19
- <view
20
- class="jfb-base-card-detail-entry__body-header"
21
- :style="{
22
- background: headerBg.color,
23
- backgroundSize: '100%',
24
- }"
25
- >
26
- <view
27
- class="jfb-base-card-detail-entry__body-header-wrap"
28
- :style="{
29
- backgroundImage: `url(${headerBg.image})`,
30
- }"
31
- >
32
- <view class="jfb-base-card-detail-entry__body-header-item">
33
- <view>券名:</view>
34
- <view>{{info.card_type_name}}</view>
35
- </view>
36
- <view
37
- style="padding-bottom: 0px"
38
- class="jfb-base-card-detail-entry__body-header-item"
39
- >
40
- <view>券号:</view>
41
- <view>{{info.card_number}}</view>
42
- </view>
43
- </view>
44
- </view>
45
- <view
46
- class="jfb-base-card-detail-entry__body-content"
47
- >
48
- <view
49
- :class="
50
- item.key === 'other_card_point'
51
- ? 'jfb-base-card-detail-entry__body-content-special'
52
- : 'jfb-base-card-detail-entry__body-content-item'
53
- "
54
- v-for="(item, index) in valueKey"
55
- :key="index"
56
- >
57
- <view> {{ item.label }}: </view>
58
- <view :style="{color:mainColor,fontWeight:500}" v-if="item.type === 'price'">
59
- {{ info[item.key] }}
60
- <text>{{info.unit}}</text>
61
- </view>
62
- <view style="color: #333; font-weight: 500" v-else>
63
- {{ info[item.key] }}
64
- <text v-if="item.type === 'type'">券</text>
19
+ <view class="card-list" :style="{
20
+ background: headerBg['color'],
21
+ backgroundSize: '100%'
22
+ }">
23
+ <view class="card-list-warp" :style="{backgroundImage: `url(${headerBg['image']})`}">
24
+ <view class="card-list__title"><view>{{info['card_type_name']}}</view></view>
25
+ <div class="card-list__content">
26
+ <view>
27
+ <text>券号:</text>
28
+ <text>{{info.card_number}}</text>
29
+ </view>
30
+ </div>
31
+ <view class="card-list__date">
32
+ <text>有效期:</text>
33
+ <text>{{info.end_time}}</text>
34
+ </view>
35
+ <view class="card-list__yue">
36
+ <text>余额:</text>
37
+ <text>{{info.card_point}} {{ info.unit }}</text>
38
+ </view>
39
+ <view class="card-list__other" v-if="info.other_card_point && info.card_point_type === 2">
40
+ <view><text>购买其他物品可抵:</text><text>{{info.other_card_point}} {{ info.unit }}</text></view>
41
+ </view>
65
42
  </view>
66
43
  </view>
67
- </view>
68
44
  <view class="jfb-base-card-detail-entry__body-qrcode">
69
45
  <view>
70
46
  <view>
@@ -90,7 +66,7 @@
90
66
  >
91
67
  进入业务板块
92
68
  </view>
93
- <view style="display:flex;align-content:center;justify-content:center">
69
+ <view style="display:flex;align-content:center;justify-content:flex-start">
94
70
  <view class="jfb-base-card-detail-entry__body-business-content">
95
71
  <view
96
72
  class="jfb-base-card-detail-entry__body-business-content-item"
@@ -106,25 +82,26 @@
106
82
  <view :style="{height: '100rpx'}"></view>
107
83
  <!-- 靠底支付 -->
108
84
  <view class="fixe_bottom" :style="prod_bottom">
109
- <!-- <xd-button
110
- size="small"
111
- type="primary">
112
- 消费记录
113
- </xd-button> -->
114
- <xd-button
115
- v-if="info.is_exchange==='Y'"
116
- @click="handleToShift"
117
- size="small"
118
- type="primary">
119
- 券转换
120
- </xd-button>
121
- <xd-button
122
- v-if="isShowUnbind"
123
- @click="handleUnBindCard"
124
- size="small"
125
- type="primary">
126
- 解除绑定
127
- </xd-button>
85
+ <view v-if="0">
86
+ <xd-button size="small" type="primary" width="100%">消费记录</xd-button>
87
+ </view>
88
+ <view v-if="info.is_exchange==='Y'">
89
+ <xd-button
90
+ width="100%"
91
+ @click="handleToShift"
92
+ size="small"
93
+ type="primary"
94
+ >券转换</xd-button>
95
+ </view>
96
+ <view v-if="isShowUnbind">
97
+ <xd-button
98
+ width="100%"
99
+ @click="handleUnBindCard"
100
+ size="small"
101
+ type="primary">
102
+ 解除绑定
103
+ </xd-button>
104
+ </view>
128
105
  </view>
129
106
  </view>
130
107
  </view>
@@ -162,23 +139,6 @@ export default {
162
139
  userInfo: null, //用户信息(暂时不可用)
163
140
 
164
141
  info: null,
165
- valueKey: [
166
- {
167
- label: "票券余额",
168
- key: "card_point",
169
- type: "price",
170
- },
171
- {
172
- label: "购买其他物品可抵",
173
- key: "other_card_point",
174
- type: "price",
175
- },
176
- {
177
- label: "有效期限",
178
- key: "end_time",
179
- type: "normal",
180
- },
181
- ],
182
142
  timeStr: "",
183
143
  timeer: null,
184
144
  date: 2, //时间底数
@@ -303,21 +263,11 @@ export default {
303
263
  );
304
264
  }
305
265
  if(res && res.site_entry_settings && res.site_entry_settings.length>0) {
306
- res.site_entry_settings = res.site_entry_settings.map(item=>{
266
+ res.site_entry_settings = res.site_entry_settings.filter(item=>{
307
267
  item['image_url'] = getServiceUrl(item['image_url'])
308
- return item
268
+ return res.business_codes.includes(item.business_code)
309
269
  })
310
- }
311
- if(res.other_card_point===0 || res.card_point_type === 1) {
312
- this.valueKey.splice(1,1)
313
- }
314
- this.info = res;
315
- if(!this.$configProject.isPreview) {
316
- this.setInval(this.info.card_qrcode_expire);
317
- }
318
- this.show = false;
319
- this.headerBg = this.getCardThemes(res.card_type_name);
320
-
270
+ }
321
271
  //显示按钮
322
272
  if (res["is_show_qrcode_logo"] === "Y") {
323
273
  this.isBrandLogo = true;
@@ -325,6 +275,13 @@ export default {
325
275
 
326
276
  this.isShowUnbind =
327
277
  res["is_can_unbind"] === "Y" || res["is_can_unbind"] === undefined;
278
+ this.info = res;
279
+ if(!this.$configProject.isPreview) {
280
+ this.setInval(this.info.card_qrcode_expire);
281
+ }
282
+ this.show = false;
283
+ console.log(this.getCardThemes(res.card_type_name),'this.getCardThemes(res.card_type_name)');
284
+ this.headerBg = this.getCardThemes(res.card_type_name);
328
285
  })
329
286
  .catch((err) => {
330
287
  // this.$refs["pwPay"].clearPwd();
@@ -397,7 +354,7 @@ export default {
397
354
  if (this.$configProject.isPreview) {
398
355
  console.log("handleBindLogin", "预览模式不跳转", this.inCallback);
399
356
  }
400
-
357
+
401
358
  else {
402
359
  this.handleToApp(entry);
403
360
  }
@@ -420,7 +377,7 @@ export default {
420
377
  }
421
378
  const {dir, path, host} = item;
422
379
  let nsp = Base64.encodeURI(JSON.stringify({business_code: entry['business_code']}));
423
-
380
+
424
381
  //外站配置地址
425
382
  if (entry.redirect_type === 'URL') {
426
383
  if (item['path'].indexOf('?') === -1) {
@@ -429,13 +386,13 @@ export default {
429
386
  this.toApp(redirectUrl);
430
387
  return;
431
388
  }
432
-
389
+
433
390
  //站内转换
434
391
  let jumpUrl = item.path;
435
392
  //#ifdef H5
436
393
  jumpUrl = `//${host}/${dir}${path}`;
437
394
  //#endif
438
-
395
+
439
396
  if (item['fixed_business_code'] === '') {
440
397
  redirectUrl = `${jumpUrl}?x-common=${nsp}&vs=${new Date().getTime()}`
441
398
  }
@@ -463,7 +420,7 @@ export default {
463
420
  handleUnBindCard() {
464
421
  this.$xdConfirm({
465
422
  $vm: this,
466
- content: "您确定要解除绑定卡券吗",
423
+ content: "您确定要解除绑定票券吗",
467
424
  title: "系统提示",
468
425
  width: "80%",
469
426
  isTitle: true,
@@ -483,7 +440,7 @@ export default {
483
440
  })
484
441
  .then((res) => {
485
442
  this.$xdAlert({
486
- content: "解绑成功",
443
+ content: "票券已解绑",
487
444
  close: () => {
488
445
  this.$xdUniHelper.redirectTo({
489
446
  url: this.backUrl || this.settings.index,
@@ -610,65 +567,216 @@ export default {
610
567
  transform: translate(-50rpx, -50rpx);
611
568
  }
612
569
  padding: unit(26, rpx);
613
- &-header {
614
- border-radius: unit(16, rpx);
615
- font-size: unit(40, rpx);
570
+ .card-list {
571
+ overflow: hidden;
572
+ border-radius: unit(16, rpx);
573
+ margin-bottom: unit(30, rpx);
574
+
575
+ &:last-child {
576
+ margin-bottom: 0;
577
+ }
578
+
579
+
580
+ &__title {
581
+ height: unit(56, rpx);
582
+ display: flex;
583
+ justify-content: flex-start;
584
+ align-items: center;
585
+
586
+ & > view {
587
+ padding: 0 unit(80, rpx);
588
+ font-size: unit(24, rpx);
589
+ line-height: unit(56, rpx);
590
+ background: rgba(102, 102, 102, 0.4);
591
+ color: #fff;
592
+ border-radius: 0 0 unit(16, rpx) 0;
593
+ }
594
+
595
+ }
596
+
597
+ &__content {
598
+ padding: unit(10, rpx) unit(40, rpx) 0;
599
+ height: unit(86, rpx);
600
+ display: flex;
601
+ justify-content: space-between;
602
+ align-items: center;
603
+
604
+ & > view:first-child {
605
+ font-size: unit(36, rpx);
606
+ line-height: unit(86, rpx);
607
+ color: #fff;
616
608
  font-weight: 700;
609
+ }
610
+
611
+ & > view:nth-child(2) {
612
+ font-size: unit(24, rpx);
613
+ display: flex;
614
+ justify-content: space-between;
615
+ align-items: center;
616
+ flex-flow: wrap;
617
+ flex-direction: column;
617
618
  color: #fff;
618
- position: relative;
619
- min-height: unit(260,rpx);
620
-
621
- &-wrap {
622
- width: unit(700, rpx);
623
- border-radius: unit(16, rpx);
624
- background-size: 100%;
625
- min-height: unit(260,rpx);
626
- display: flex;
627
- flex-direction: column;
628
- justify-content: center;
619
+ }
620
+ }
621
+
622
+ &__date {
623
+ padding: 0 unit(40, rpx);
624
+ font-size: unit(28, rpx);
625
+ line-height: unit(32, rpx);
626
+ color: #fff;
627
+ }
628
+
629
+ &__yue {
630
+ padding: unit(10, rpx) unit(40, rpx) 0;
631
+ font-size: unit(28, rpx);
632
+ line-height: unit(32, rpx);
633
+ color: #fff;
634
+
635
+ & > text:nth-child(2) {
636
+ font-weight: 700;
637
+ }
638
+ }
639
+
640
+ &__other {
641
+ display: flex;
642
+ justify-content: flex-start;
643
+ align-items: center;
644
+ padding: unit(20, rpx) unit(40, rpx) 0;
645
+ margin-top: unit(0, rpx);
646
+
647
+ & > view {
648
+ border-radius:unit(8, rpx);
649
+ background: rgba(255, 255, 255, 0.2);
650
+ height: unit(48, rpx);
651
+ line-height: unit(48, rpx);
652
+ display: flex;
653
+ justify-content: flex-start;
654
+ align-items: center;
655
+ font-weight: 400;
656
+ font-size: unit(24, rpx);
657
+ padding: 0 unit(20, rpx);
658
+ color: #fff;
659
+ }
660
+
661
+
662
+ }
663
+
664
+ &__nodata {
665
+ padding: unit(20, rpx) unit(40, rpx) 0;
666
+ margin-top: unit(0, rpx);
667
+ color: #fff;
668
+ font-size: unit(28, rpx);
669
+ }
670
+
671
+ &__entry {
672
+ padding: unit(20, rpx) unit(40, rpx) 0;
673
+ & > view {
674
+ line-height: unit(64, rpx);
675
+ text-align: center;
676
+ font-size: unit(26, rpx);
677
+ border-radius: unit(32, rpx);
678
+ background: rgba(255, 255, 255, 1);
679
+ box-shadow: 0 unit(4, rpx) unit(8, rpx) rgba(156, 62, 0, 0.11);
680
+ font-weight: 500;
681
+ }
682
+ }
683
+
684
+ &__entrys {
685
+ margin: unit(20, rpx) unit(20, rpx) 0;
686
+ padding: unit(30, rpx);
687
+ border-radius: unit(16, rpx);
688
+ background: rgba(255, 255, 255, 1);
689
+ box-shadow: 0 unit(4, rpx) unit(8, rpx) rgba(156, 62, 0, 0.11);
690
+
691
+ &-title {
692
+ display: flex;
693
+ justify-content: space-between;
694
+ align-items: center;
695
+
696
+
697
+ & > view:first-child {
698
+ font-size: unit(28, rpx);
699
+ font-weight: 500;
700
+ flex: 1;
629
701
  }
630
702
 
631
- &-item {
703
+ & > view:nth-child(2) {
632
704
  display: flex;
633
705
  justify-content: flex-start;
634
- align-content: center;
635
- padding-bottom: unit(32, rpx);
636
- padding-left: unit(40,rpx);
706
+ align-items: center;
707
+ flex-shrink: 0;
708
+ font-size: unit(20, rpx);
709
+ color: #999;
710
+ }
711
+ }
712
+
713
+ &-scroll {
714
+
715
+ }
716
+
717
+ &-item {
718
+ display: flex;
719
+ justify-content: flex-start;
720
+ align-items: center;
721
+ flex-flow: nowrap;
722
+ margin-left: unit(-14, rpx);
723
+ padding-top: unit(20, rpx);
724
+
725
+ & > view {
726
+ width: unit(120, rpx);
727
+ margin-right: unit(10, rpx);
728
+ flex-shrink: 0;
729
+ display: flex;
730
+ justify-content: center;
731
+ flex-direction: column;
732
+ align-items: center;
637
733
 
638
734
  & > view:first-child {
639
- flex-basis: unit(120,rpx);
735
+ width: unit(76, rpx);
736
+ height: unit(76, rpx);
737
+ overflow: hidden;
738
+
739
+ & > image {
740
+ height: 100%;
741
+ width: 100%;
742
+ }
743
+ }
744
+
745
+ & > view:nth-child(2) {
746
+ margin-top: unit(10, rpx);
747
+ font-size: unit(24, rpx);
748
+ line-height: unit(36, rpx);
749
+ margin-bottom: unit(10, rpx);
750
+ }
751
+
752
+ & > view:nth-child(3) {
753
+ display: flex;
754
+ justify-content: flex-start;
755
+ align-items: center;
640
756
  flex-shrink: 0;
757
+ font-size: unit(20, rpx);
758
+ color: #999;
641
759
  }
642
- }
643
- }
644
760
 
645
- &-content {
646
- background: #fff;
647
- border-radius: unit(16, rpx);
648
- padding: unit(38, rpx) 0;
649
- margin-top: unit(24, rpx);
761
+ &:last-child {
762
+ margin-right: 0;
763
+ }
650
764
 
651
- &-item {
652
- display: flex;
653
- color: #666;
654
- justify-content: space-between;
655
- align-content: center;
656
- font-size: unit(28, rpx);
657
- padding: unit(16, rpx) unit(48, rpx);
658
765
  }
659
766
 
660
- &-special {
661
- display: flex;
662
- color: #666;
663
- justify-content: space-between;
664
- font-size: unit(24, rpx);
665
- padding: unit(18, rpx) unit(24, rpx);
666
- margin: 0 unit(24, rpx);
667
- border-radius: unit(16, rpx);
668
- background: #f9f9f9;
669
- align-content: center;
670
- }
767
+
671
768
  }
769
+ }
770
+
771
+ &-warp {
772
+ width: unit(700, rpx);
773
+ // min-height: unit(290, rpx);
774
+ position: relative;
775
+ border-radius: unit(16, rpx);
776
+ background-size: 100%;
777
+ padding-bottom: unit(20, rpx);
778
+ }
779
+ }
672
780
 
673
781
  &-qrcode {
674
782
  text-align: center;
@@ -695,12 +803,11 @@ export default {
695
803
  box-sizing: border-box;
696
804
  height: unit(200, rpx);
697
805
  width: 100%;
698
- margin-top: unit(20, rpx);
699
806
 
700
807
  & > view {
701
808
  width: 100%;
702
809
  height: unit(200, rpx);
703
- padding: unit(10, rpx);
810
+ padding: 0 unit(10, rpx) unit(10, rpx) unit(10, rpx);
704
811
  display: flex;
705
812
  justify-content: center;
706
813
  align-items: center;
@@ -749,7 +856,7 @@ export default {
749
856
  align-items: center;
750
857
  flex-flow: wrap;
751
858
  padding-left: unit(30, rpx);
752
-
859
+
753
860
  & > view {
754
861
  width: unit(120, rpx);
755
862
  margin-right: unit(10, rpx);
@@ -758,25 +865,25 @@ export default {
758
865
  justify-content: center;
759
866
  flex-direction: column;
760
867
  align-items: center;
761
-
868
+
762
869
  & > view:first-child {
763
870
  width: unit(76, rpx);
764
871
  height: unit(76, rpx);
765
872
  overflow: hidden;
766
-
873
+
767
874
  & > image {
768
875
  height: 100%;
769
876
  width: 100%;
770
877
  }
771
878
  }
772
-
879
+
773
880
  & > view:nth-child(2) {
774
881
  margin-top: unit(10, rpx);
775
882
  font-size: unit(24, rpx);
776
883
  line-height: unit(36, rpx);
777
884
  margin-bottom: unit(10, rpx);
778
885
  }
779
-
886
+
780
887
  & > view:nth-child(3) {
781
888
  display: flex;
782
889
  justify-content: flex-start;
@@ -785,7 +892,7 @@ export default {
785
892
  font-size: unit(20, rpx);
786
893
  color: #999;
787
894
  }
788
-
895
+
789
896
  &:last-child {
790
897
  margin-right: 0;
791
898
  }
@@ -794,19 +901,27 @@ export default {
794
901
  }
795
902
 
796
903
  .fixe_bottom{
904
+ display: flex;
905
+ align-items: center;
906
+ justify-content: space-around;
907
+ height: unit(100, rpx);
908
+ padding: 0 unit(40, rpx);
909
+ flex-flow: nowrap;
910
+ background: #FFF;
911
+ box-shadow: 0 0 unit(16, rpx) rgba(0,0,0,.05);
912
+ .flex_l{
797
913
  display: flex;
798
914
  align-items: center;
799
- justify-content: space-between;
800
- height: unit(100, rpx);
801
- padding: 0 unit(40, rpx);
802
- background: #FFF;
803
- box-shadow: 0 0 unit(16, rpx) rgba(0,0,0,.05);
804
- .flex_l{
805
- display: flex;
806
- align-items: center;
807
- font-size: unit(32,rpx);
808
- }
915
+ font-size: unit(32,rpx);
916
+ }
917
+
918
+ & > view {
919
+ flex: 1;
920
+ padding:0 unit(15, rpx);
921
+
809
922
  }
923
+
924
+ }
810
925
  }
811
926
  }
812
927
  </style>