jufubao-base 1.0.237-beta1 → 1.0.237-beta4

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.
Files changed (104) hide show
  1. package/package.json +1 -1
  2. package/src/components/JfbBaseBalance/Api.js +46 -0
  3. package/src/components/JfbBaseBalance/Attr.js +316 -0
  4. package/src/components/JfbBaseBalance/JfbBaseBalance.vue +331 -0
  5. package/src/components/JfbBaseBalance/JfbBaseBalanceLess.less +79 -0
  6. package/src/components/JfbBaseBalance/JfbBaseBalanceMixin.js +30 -0
  7. package/src/components/JfbBaseBalance/Mock.js +9 -0
  8. package/src/components/JfbBaseCodeOpenVip/Api.js +35 -0
  9. package/src/components/JfbBaseCodeOpenVip/Attr.js +281 -0
  10. package/src/components/JfbBaseCodeOpenVip/JfbBaseCodeOpenVip.vue +251 -0
  11. package/src/components/JfbBaseCodeOpenVip/JfbBaseCodeOpenVipLess.less +79 -0
  12. package/src/components/JfbBaseCodeOpenVip/JfbBaseCodeOpenVipMixin.js +30 -0
  13. package/src/components/JfbBaseCodeOpenVip/Mock.js +13 -0
  14. package/src/components/JfbBaseConsumpCode/Api.js +133 -0
  15. package/src/components/JfbBaseConsumpCode/Attr.js +61 -0
  16. package/src/components/JfbBaseConsumpCode/JfbBaseConsumpCode.vue +961 -0
  17. package/src/components/JfbBaseConsumpCode/JfbBaseConsumpCodeLess.less +79 -0
  18. package/src/components/JfbBaseConsumpCode/JfbBaseConsumpCodeMixin.js +30 -0
  19. package/src/components/JfbBaseConsumpCode/Mock.js +22 -0
  20. package/src/components/JfbBaseNoticeDialog/Api.js +1 -1
  21. package/src/components/JfbBaseNoticeDialog/Attr.js +26 -0
  22. package/src/components/JfbBaseNoticeDialog/JfbBaseNoticeDialog.vue +25 -6
  23. package/src/components/JfbBaseOpenVip/Api.js +39 -0
  24. package/src/components/JfbBaseOpenVip/Attr.js +290 -0
  25. package/src/components/JfbBaseOpenVip/JfbBaseOpenVip.vue +430 -0
  26. package/src/components/JfbBaseOpenVip/JfbBaseOpenVipLess.less +79 -0
  27. package/src/components/JfbBaseOpenVip/JfbBaseOpenVipMixin.js +30 -0
  28. package/src/components/JfbBaseOpenVip/Mock.js +7 -0
  29. package/src/components/JfbBaseOpenVip/XdVipList.vue +125 -0
  30. package/src/components/JfbBaseOpenVipCard/Api.js +58 -0
  31. package/src/components/JfbBaseOpenVipCard/Attr.js +48 -0
  32. package/src/components/JfbBaseOpenVipCard/JfbBaseOpenVipCard.vue +111 -0
  33. package/src/components/JfbBaseOpenVipCard/JfbBaseOpenVipCardLess.less +79 -0
  34. package/src/components/JfbBaseOpenVipCard/JfbBaseOpenVipCardMixin.js +30 -0
  35. package/src/components/JfbBaseOpenVipCard/Mock.js +13 -0
  36. package/src/components/JfbBaseOpenVipDetail/Api.js +35 -0
  37. package/src/components/JfbBaseOpenVipDetail/Attr.js +37 -0
  38. package/src/components/JfbBaseOpenVipDetail/JfbBaseOpenVipDetail.vue +223 -0
  39. package/src/components/JfbBaseOpenVipDetail/JfbBaseOpenVipDetailLess.less +79 -0
  40. package/src/components/JfbBaseOpenVipDetail/JfbBaseOpenVipDetailMixin.js +30 -0
  41. package/src/components/JfbBaseOpenVipDetail/Mock.js +13 -0
  42. package/src/components/JfbBasePersonalData/Api.js +26 -0
  43. package/src/components/JfbBasePersonalData/Attr.js +12 -0
  44. package/src/components/JfbBasePersonalData/JfbBasePersonalData.vue +198 -0
  45. package/src/components/JfbBasePersonalData/JfbBasePersonalDataLess.less +79 -0
  46. package/src/components/JfbBasePersonalData/JfbBasePersonalDataMixin.js +30 -0
  47. package/src/components/JfbBasePersonalData/Mock.js +13 -0
  48. package/src/components/JfbBasePointsCard/Api.js +18 -0
  49. package/src/components/JfbBasePointsCard/Attr.js +187 -0
  50. package/src/components/JfbBasePointsCard/JfbBasePointsCard.vue +208 -0
  51. package/src/components/JfbBasePointsCard/JfbBasePointsCardLess.less +79 -0
  52. package/src/components/JfbBasePointsCard/JfbBasePointsCardMixin.js +30 -0
  53. package/src/components/JfbBasePointsCard/Mock.js +5 -0
  54. package/src/components/JfbBasePointsDetail/Api.js +48 -0
  55. package/src/components/JfbBasePointsDetail/Attr.js +304 -0
  56. package/src/components/JfbBasePointsDetail/JfbBasePointsDetail.vue +267 -0
  57. package/src/components/JfbBasePointsDetail/JfbBasePointsDetailLess.less +79 -0
  58. package/src/components/JfbBasePointsDetail/JfbBasePointsDetailMixin.js +30 -0
  59. package/src/components/JfbBasePointsDetail/Mock.js +6 -0
  60. package/src/components/JfbBasePosterGroup/Api.js +22 -0
  61. package/src/components/JfbBasePosterGroup/Attr.js +146 -0
  62. package/src/components/JfbBasePosterGroup/JfbBasePosterGroup.vue +265 -0
  63. package/src/components/JfbBasePosterGroup/JfbBasePosterGroupLess.less +79 -0
  64. package/src/components/JfbBasePosterGroup/JfbBasePosterGroupMixin.js +30 -0
  65. package/src/components/JfbBasePosterGroup/Mock.js +13 -0
  66. package/src/components/JfbBaseSavingDetail/Api.js +41 -0
  67. package/src/components/JfbBaseSavingDetail/Attr.js +70 -0
  68. package/src/components/JfbBaseSavingDetail/JfbBaseSavingDetail.vue +679 -0
  69. package/src/components/JfbBaseSavingDetail/JfbBaseSavingDetailLess.less +79 -0
  70. package/src/components/JfbBaseSavingDetail/JfbBaseSavingDetailMixin.js +30 -0
  71. package/src/components/JfbBaseSavingDetail/Mock.js +10 -0
  72. package/src/components/JfbBaseSavingDetail/components/echarts.min.js +26 -0
  73. package/src/components/JfbBaseSavingDetail/components/echarts.vue +254 -0
  74. package/src/components/JfbBaseSavingDetail/components/wx-canvas.js +105 -0
  75. package/src/components/JfbBaseShare/Api.js +20 -0
  76. package/src/components/JfbBaseShare/Attr.js +14 -0
  77. package/src/components/JfbBaseShare/JfbBaseShare.vue +270 -0
  78. package/src/components/JfbBaseShare/JfbBaseShareLess.less +79 -0
  79. package/src/components/JfbBaseShare/JfbBaseShareMixin.js +30 -0
  80. package/src/components/JfbBaseShare/Mock.js +16 -0
  81. package/src/components/JfbBaseTfkSearch/ContentProduct.vue +11 -22
  82. package/src/components/JfbBaseTfkSearch/JfbBaseTfkSearch.vue +8 -1
  83. package/src/components/JfbBaseTfkSearch/Mock.js +51 -3
  84. package/src/components/JfbBaseTfkSearch/listMixins.js +1 -1
  85. package/src/components/JfbBaseUserInfo/Attr.js +114 -10
  86. package/src/components/JfbBaseUserInfo/JfbBaseUserInfo.vue +312 -114
  87. package/src/components/JfbBaseWithDrawAgain/Api.js +41 -0
  88. package/src/components/JfbBaseWithDrawAgain/Attr.js +92 -0
  89. package/src/components/JfbBaseWithDrawAgain/JfbBaseWithDrawAgain.vue +334 -0
  90. package/src/components/JfbBaseWithDrawAgain/JfbBaseWithDrawAgainLess.less +79 -0
  91. package/src/components/JfbBaseWithDrawAgain/JfbBaseWithDrawAgainMixin.js +30 -0
  92. package/src/components/JfbBaseWithDrawAgain/Mock.js +10 -0
  93. package/src/components/JfbBaseWithDrawRecord/Api.js +19 -0
  94. package/src/components/JfbBaseWithDrawRecord/Attr.js +79 -0
  95. package/src/components/JfbBaseWithDrawRecord/JfbBaseWithDrawRecord.vue +233 -0
  96. package/src/components/JfbBaseWithDrawRecord/JfbBaseWithDrawRecordLess.less +79 -0
  97. package/src/components/JfbBaseWithDrawRecord/JfbBaseWithDrawRecordMixin.js +30 -0
  98. package/src/components/JfbBaseWithDrawRecord/Mock.js +7 -0
  99. package/src/components/JfbBaseWithdraw/Api.js +48 -0
  100. package/src/components/JfbBaseWithdraw/Attr.js +328 -0
  101. package/src/components/JfbBaseWithdraw/JfbBaseWithdraw.vue +245 -0
  102. package/src/components/JfbBaseWithdraw/JfbBaseWithdrawLess.less +79 -0
  103. package/src/components/JfbBaseWithdraw/JfbBaseWithdrawMixin.js +30 -0
  104. package/src/components/JfbBaseWithdraw/Mock.js +7 -0
@@ -0,0 +1,430 @@
1
+ <template>
2
+ <view
3
+ class="jfb-base-open-vip"
4
+ @click="handleEditxSelect"
5
+ :class="{ editx : isEditx && active }"
6
+ >
7
+ <!--#ifdef H5-->
8
+ <view
9
+ class="jfb-base-open-vip__edit"
10
+ :class="{ editx : isEditx && active }"
11
+ v-if="isEditx && active"
12
+ >
13
+ <view class="jfb-base-open-vip__edit-icon" @click="delEdit">删除</view>
14
+ </view>
15
+ <!-- #endif -->
16
+ <view class="jfb-base-open-vip__body" :style="[bodyStyle]">
17
+ <!-- 用户信息 -->
18
+ <view class="u_header">
19
+ <view class="u_avatar">
20
+ <image :src="uInfo.head_url" mode="aspectFill"></image>
21
+ </view>
22
+ <view class="u_info">
23
+ <view class="u_info-top">
24
+ <view class="vip_name">{{ uInfo.show_user_name }}</view>
25
+ <view v-if="isVip" class="vip_level plus">PLUS会员</view>
26
+ <view v-else class="vip_level">普通用户</view>
27
+ </view>
28
+ <view class="u_sub">
29
+ <view v-if="isVip" style="color:#999999;">已省{{ $xdUniHelper.divisionFloatNumber(save_amount, 100) }}</view>
30
+ <view v-else style="color:#333333;">{{ uInfo.phone_number }}</view>
31
+ </view>
32
+ </view>
33
+ <view v-if="isVip" class="buy_btn" @click="showDrawer=true">立即续费</view>
34
+ <!-- <view v-else class="buy_btn" @click="showDrawer=true">立即开通</view> -->
35
+ </view>
36
+
37
+ <!-- plus会员权益 -->
38
+ <view class="vip_info">
39
+ <view class="vip_box" :style="{
40
+ backgroundImage: `url(${bannerBgImg})`,
41
+ }">
42
+ <view class="vip_box-left">
43
+ <view class="vip_box-title">PLUS会员</view>
44
+ <view v-if="isVip">有效期至:{{ vip_expire_time }}</view>
45
+ <view v-else>开通享受更多权益</view>
46
+ </view>
47
+ <!-- <view class="vip_logo">
48
+ <image :src="siteLogo" mode="aspectFill"></image>
49
+ </view> -->
50
+ </view>
51
+ </view>
52
+ <view>
53
+ <image :src="specialImage" mode="widthFix" style="width: 100%;"></image>
54
+ <!--
55
+ <view class="vip_banner">
56
+ <view class="banner_item" v-for="i in 4" :key="i">
57
+ <view class="banner_img"></view>
58
+ <view class="banner_text">生日祝福</view>
59
+ </view>
60
+ </view>
61
+ <view class="vip_good">
62
+ <view class="vip_good-title">
63
+ <text class="_text">4大特权</text>
64
+ <view class="line"></view>
65
+ </view>
66
+ <view class="good_list">
67
+ <view class="good_item" v-for="i in 4" :key="i">
68
+ <view class="good_title">
69
+ <view class="good_title-tag">特权福利1</view>
70
+ <view>生日祝福</view>
71
+ </view>
72
+ <view class="good_cont">平台会在生日当天为用户发放专属的生日祝福</view>
73
+ </view>
74
+ </view>
75
+ </view> -->
76
+ </view>
77
+
78
+ <xd-vip-list v-if="!isVip" :list="vipCardList"
79
+ @handlePrivacy="handlePrivacy"
80
+ @toVipDetail="toVipDetail"
81
+ ></xd-vip-list>
82
+
83
+ <xd-down-drawer :show.sync="showDrawer" height="480rpx">
84
+ <view class="drawer_title">立即续费</view>
85
+ <xd-vip-list :list="vipCardList"
86
+ @handlePrivacy="handlePrivacy"
87
+ @toVipDetail="toVipDetail"
88
+ ></xd-vip-list>
89
+ </xd-down-drawer>
90
+
91
+ </view>
92
+ </view>
93
+ </template>
94
+
95
+ <script>
96
+ import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
97
+ import XdButton from "@/components/XdButton/XdButton";
98
+ import XdVipList from "./XdVipList.vue";
99
+ import XdDownDrawer from "@/components/XdDownDrawer/XdDownDrawer.vue"
100
+ import { jfbRootExec } from "@/utils/xd.event";
101
+ import JfbBaseOpenVipMixin from "./JfbBaseOpenVipMixin";
102
+ import { getContainerPropsValue } from "@/utils/xd.base";
103
+ import componentsMixins from "@/mixins/componentsMixins";
104
+ import extsMixins from "@/mixins/extsMixins";
105
+ import getServiceUrl from "@/common/getServiceUrl"
106
+
107
+ export default {
108
+ name: "JfbBaseOpenVip",
109
+ components: {
110
+ XdFontIcon,
111
+ XdButton,
112
+ XdVipList,
113
+ XdDownDrawer
114
+ },
115
+ mixins: [
116
+ componentsMixins, extsMixins, JfbBaseOpenVipMixin
117
+ ],
118
+ data() {
119
+ return {
120
+ closeMask: true,
121
+
122
+ showDrawer: false,
123
+ uInfo: {},
124
+ vipCardList: [],
125
+ save_amount: 0,
126
+ vip_expire_time: "",
127
+
128
+ siteLogo: "",
129
+ //todo
130
+ vipDetailPath: "",
131
+ bannerBgImg: "",
132
+ specialImage: "",
133
+ }
134
+ },
135
+ computed: {
136
+ bodyStyle(){
137
+ return {
138
+ minHeight: this.layoutInfo.bodyMinHeightRpx + "rpx",
139
+ '--main-color': this.mainColor
140
+ }
141
+ },
142
+ isVip(){
143
+ return this.uInfo.user_level === 'VIP';
144
+ }
145
+ },
146
+ watch: {
147
+ container(value, oldValue) {
148
+ if (JSON.stringify(value) === JSON.stringify(oldValue)) return;
149
+ if (this.$configProject['isPreview']) this.init(value)
150
+ },
151
+ },
152
+ created() {
153
+ this.init(this.container);
154
+ this.siteLogo = getServiceUrl(this.projectAttr['site_logo']);
155
+ //todo
156
+ },
157
+ methods: {
158
+ onJfbLoad(options) {
159
+ this.p_getBaseUserInfo();
160
+ this.p_getVipMoneySaving();
161
+ this.p_getVipList();
162
+ },
163
+ /**
164
+ * @description 监听事件变化
165
+ * @param container {object} 业务组件对象自己
166
+ */
167
+ init(container) {
168
+ this.vipDetailPath = getContainerPropsValue(container, 'content.vipDetailPath', {value: "/system/system/vipdetail"}).value;
169
+ this.bannerBgImg = getServiceUrl(getContainerPropsValue(container, 'content.bannerBgImg', {url: ""}).url);
170
+ this.specialImage = getServiceUrl(getContainerPropsValue(container, 'content.specialImage', {url: ""}).url);
171
+ },
172
+ p_getBaseUserInfo(){
173
+ jfbRootExec("getOpenBaseUserInfo", {
174
+ vm: this,
175
+ data: {}
176
+ }).then(res => {
177
+ this.uInfo = res;
178
+ this.vip_expire_time = this.$xdUniHelper.getDate(res.vip_expire_time * 1000 ).fullTime;
179
+ })
180
+ },
181
+ p_getVipMoneySaving(){
182
+ jfbRootExec("getVipMoneySaving", {
183
+ vm: this,
184
+ data: {}
185
+ }).then(res => {
186
+ this.save_amount = res.save_amount;
187
+ })
188
+ },
189
+ p_getVipList(){
190
+ jfbRootExec("getVipList", {
191
+ vm: this,
192
+ data: {}
193
+ }).then(res => {
194
+ this.vipCardList = res.list;
195
+ })
196
+ },
197
+ handlePrivacy(code){
198
+ let params = `page_id=${this.pageAttr["page_id"]}`;
199
+ params = `${params}&container_id=${this.containerId}${code}`;
200
+ this.$xdUniHelper.navigateTo({
201
+ url: `/pages/content/content?${params}`
202
+ })
203
+ },
204
+ toVipDetail(vip_card_id){
205
+ this.$xdUniHelper.navigateTo({
206
+ url: `${this.vipDetailPath}?vip_card_id=${vip_card_id}`
207
+ })
208
+ },
209
+ onJfbScroll(options) {
210
+ // console.log('event.onJfbScroll', options)
211
+ },
212
+ onJfbReachBottom(options) {
213
+ console.log('event.onJfbReachBottom', options)
214
+ },
215
+ onJfbShow(options) {
216
+ console.log('event.onJfbShow', options)
217
+ },
218
+ onJfbHide(options) {
219
+ console.log('event.onJfbHide', options)
220
+ },
221
+ onJfbBack(options) {
222
+ console.log('event.onJfbBack', options)
223
+ },
224
+ onJfbUpdate(...data) {
225
+ console.log('event.onJfbUpdate', data)
226
+ },
227
+ onJfbCustomEvent(options) {
228
+ console.log('event.onJfbReachBottom', options)
229
+ },
230
+ }
231
+ }
232
+
233
+ </script>
234
+
235
+ <style scoped lang="less">
236
+ @import "./JfbBaseOpenVipLess.less";
237
+
238
+ .jfb-base-open-vip {
239
+ &__body{
240
+ .u_header{
241
+ display: flex;
242
+ align-items: center;
243
+ padding: 24rpx 40rpx;
244
+ margin: 20rpx;
245
+
246
+ .u_avatar{
247
+ width: 120rpx;
248
+ height: 120rpx;
249
+ border-radius: 120rpx;
250
+ margin-right: 24rpx;
251
+ overflow: hidden;
252
+ image{
253
+ width: 100%;
254
+ height: 100%;
255
+ }
256
+ }
257
+ .u_info{
258
+ flex:1;
259
+ &-top{
260
+ display: flex;
261
+ align-items: center;
262
+ .vip_name{
263
+ font-size: 28rpx;
264
+ color: #333333;
265
+ }
266
+ .vip_level{
267
+ padding: 4rpx 16rpx;
268
+ border-radius: 24rpx;
269
+ font-size: 24rpx;
270
+ background-color: #FFE6C4;
271
+ color: #615850;
272
+ margin-left: 8rpx;
273
+ &.plus{
274
+ background: linear-gradient(180deg, #615243 0%, #2D2824 100%);
275
+ color: #FFEFD7;
276
+ }
277
+ }
278
+ }
279
+ .u_sub{
280
+ margin-top: 24rpx;
281
+ font-size: 24rpx;
282
+ }
283
+ }
284
+ .buy_btn{
285
+ width: 146rpx;
286
+ height: 60rpx;
287
+ background-color: var(--main-color);
288
+ color: #fff;
289
+ border-radius: 60rpx;
290
+ line-height: 60rpx;
291
+ text-align: center;
292
+ font-size: 24rpx;
293
+ }
294
+ }
295
+
296
+ .vip_info{
297
+ // padding: 20rpx;
298
+ .vip_box{
299
+ width: 710rpx;
300
+ height: 184rpx;
301
+ margin: auto;
302
+ border-radius: 24rpx;
303
+ // background: linear-gradient(90deg, #E8A841 0%, #FAD48E 100%);
304
+ background-size: 100% 100%;
305
+ background-repeat: no-repeat;
306
+ display: flex;
307
+ align-items: center;
308
+ justify-content: space-between;
309
+ padding: 40rpx;
310
+ box-sizing: border-box;
311
+
312
+ &-left{
313
+ font-size: 24rpx;
314
+ font-weight: 400;
315
+ color: #FFFFFF;
316
+ display: flex;
317
+ align-self: stretch;
318
+ flex-direction: column;
319
+ justify-content: space-between;
320
+ }
321
+ &-title{
322
+ font-size: 32rpx;
323
+ font-weight: bold;
324
+ }
325
+ .vip_logo{
326
+ width: 104rpx;
327
+ height: 104rpx;
328
+ image{
329
+ width: 100%;
330
+ height: 100%;
331
+ }
332
+ }
333
+ }
334
+
335
+ .vip_banner{
336
+ display: flex;
337
+ padding: 16rpx;
338
+ margin: 20rpx 0;
339
+ justify-content: space-around;
340
+ .banner_item{
341
+ display: flex;
342
+ align-items: center;
343
+ flex-direction: column;
344
+ .banner_img{
345
+ width: 108rpx;
346
+ height: 108rpx;
347
+ border-radius: 108rpx;
348
+ background-color: #EBB963;
349
+ }
350
+ .banner_text{
351
+ color: #333333;
352
+ font-size: 24rpx;
353
+ font-weight: 500;
354
+ margin-top: 16rpx;
355
+ }
356
+ }
357
+ }
358
+
359
+ .vip_good{
360
+ background-color: #FFFFFF;
361
+ border-radius: 24rpx;
362
+ overflow: hidden;
363
+ &-title{
364
+ height: 110rpx;
365
+ line-height: 110rpx;
366
+ font-size: 36rpx;
367
+ font-weight: 500;
368
+ text-align: center;
369
+ color: #000000;
370
+ border-bottom: 1px solid #FAFAFA;
371
+ position: relative;
372
+ .line{
373
+ position: absolute;
374
+ left: 50%;
375
+ top: 50%;
376
+ transform: translate(-50%, -50%);
377
+ width: 280rpx;
378
+ height: 1px;
379
+ background-color: #000000;
380
+ }
381
+ ._text{
382
+ position: relative;
383
+ z-index: 10;
384
+ background-color: #fff;
385
+ padding: 0 24rpx;
386
+ }
387
+ }
388
+ .good_item{
389
+ padding: 32rpx 46rpx;
390
+ border-bottom: 1px solid #FAFAFA;
391
+ &:last-child{
392
+ border-bottom: none;
393
+ }
394
+ .good_title{
395
+ display: flex;
396
+ align-items: center;
397
+ font-size: 28rpx;
398
+ font-weight: 500;
399
+ color: #666666;
400
+
401
+ &-tag{
402
+ padding: 8rpx 16rpx;
403
+ border-radius: 8rpx;
404
+ font-size: 22rpx;
405
+ line-height: 1;
406
+ background: linear-gradient(90deg, #FCD083 0%, #FFDEAD 100%);
407
+ color: #915714;
408
+ margin-right: 16rpx;
409
+ }
410
+ }
411
+ .good_cont{
412
+ font-size: 28rpx;
413
+ color: #BBBBBB;
414
+ font-size: 400;
415
+ margin-top: 16rpx;
416
+ }
417
+ }
418
+ }
419
+ }
420
+ .drawer_title{
421
+ height: 100rpx;
422
+ line-height: 100rpx;
423
+ text-align: center;
424
+ font-size: 28rpx;
425
+ color: #333333;
426
+ font-weight: 500;
427
+ }
428
+ }
429
+ }
430
+ </style>
@@ -0,0 +1,79 @@
1
+ /**
2
+ * @desc 获取绝对路径完整地址
3
+ * @param @path
4
+ **/
5
+ //例如:https://image.jufubao.cn/20220501010108/image/bg/default_gonghui_bg.png
6
+ @basePath: 'business/';
7
+ @doMain: '//sandbox-img.jufubao.cn/';
8
+
9
+ .getBusinessImageUrl(@path, @size: 'size8') {
10
+ @url: "@{doMain}@{basePath}@{path}?x-oss-process=style/@{size}";
11
+ background-image: url(@url);
12
+ }
13
+
14
+ //start
15
+ .jfb-base-open-vip {
16
+ box-sizing: border-box;
17
+
18
+ &__body{
19
+ position: relative;
20
+ overflow: hidden;
21
+ z-index: 2
22
+ }
23
+
24
+ &.editx,&.editx:hover {
25
+ position: relative;
26
+ min-height: unit(100, rpx);
27
+ z-index: 3;
28
+ &::after {
29
+ border: 2rpx dashed blue;
30
+ content: " ";
31
+ position: absolute;
32
+ top:0;
33
+ left:0;
34
+ bottom:0;
35
+ right:0;
36
+ z-index: 4;
37
+ cursor: pointer;
38
+ }
39
+
40
+ }
41
+
42
+
43
+ &__edit {
44
+ cursor: pointer;
45
+ position: absolute;
46
+ right: unit(0, rpx);
47
+ top: unit(-52, rpx);
48
+ height: unit(50, rpx);
49
+ line-height: unit(50, rpx);
50
+ display: flex;
51
+ justify-content: center;
52
+ align-items: center;
53
+ background: rgba(0, 0, 0, .6);
54
+ border-radius: unit(10, rpx);
55
+ box-shadow: 0 0 10px rbga(0, 0, 0, 0.3);
56
+ color: #fff;
57
+ font-size: unit(22, rpx);
58
+
59
+ &-icon{
60
+ padding: 0 unit(20, rpx);
61
+ }
62
+
63
+ &.editx {
64
+ box-sizing: border-box;
65
+
66
+ }
67
+ }
68
+ }
69
+ //end
70
+
71
+
72
+ /**notPreview**/
73
+ .jfb-base-open-vip {
74
+ //&:before {
75
+ //content: " ";
76
+ //display: table;
77
+ //}
78
+ }
79
+ /**endNotPreview**/
@@ -0,0 +1,30 @@
1
+ 'use strict';
2
+
3
+
4
+ //@AttrImport
5
+ import Attr from "./Attr";
6
+ //@EndAttrImport
7
+
8
+
9
+ export default {
10
+ data() {
11
+ return {
12
+ //#ifdef H5
13
+
14
+ //@AttrData
15
+ Attr:{}, //对外开发编辑属性
16
+ //@EndAttrData
17
+
18
+ // #endif
19
+ cssRoot: 'jfb-base-open-vip'
20
+ }
21
+ },
22
+ created() {
23
+
24
+ //@AttrDataCreated
25
+ this.Attr = this.$xdUniHelper.customClone(Attr);
26
+ //@EndAttrDataCreated
27
+
28
+
29
+ },
30
+ }
@@ -0,0 +1,7 @@
1
+ 'use strict';
2
+
3
+ module.exports = {
4
+ getOpenBaseUserInfo: {"user_name":"","user_code":"Uf4zx6EPfV","nickname":"未来~","real_name":"","head_url":"https:\/\/thirdwx.qlogo.cn\/mmopen\/vi_32\/Q0j4TwGTfTJsajZzh53IB56crRSdmKvRbjT4V1Ha8v5uCOkASbWS0GibgLeic8OKBzAwUyBa3vZGhjwmd6RfpG9g\/132","province_code":"","city_code":"","province_name":"","city_name":"","sex":"","sex_name":"未知","birthday_date":"","phone_number":"13611111111","show_user_name":"未来~","user_level":"VIP","vip_expire_time":1745026677,"request_id":"250e5709e6c95066"},
5
+ getVipList: {"total_size":3,"next_page_token":"","list":[{"vip_card_id":3,"product_id":60038520,"product_name":"体验卡","sale_price":200,"vip_card_icon":""},{"vip_card_id":2,"product_id":60038519,"product_name":"月卡","sale_price":2678,"vip_card_icon":""},{"vip_card_id":1,"product_id":60038515,"product_name":"测1","sale_price":20085,"vip_card_icon":""}],"request_id":"6b4aef5e06411d8a"},
6
+ getVipMoneySaving: { "save_amount": 100 , "request_id": "6b4aef5e06411d8a" }
7
+ }
@@ -0,0 +1,125 @@
1
+ <template>
2
+ <view class="xd_vip_wrap">
3
+ <view class="vip_list">
4
+ <view class="vip_item" :class="{active: item.vip_card_id===vip_card_id}"
5
+ v-for="item in uiList" :key="item.vip_card_id"
6
+ @click="handleChoseVip(item.vip_card_id)"
7
+ >
8
+ <view class="vip_name">{{ item.product_name}}</view>
9
+ <view class="vip_price">{{ $xdUniHelper.divisionFloatNumber(item.sale_price, 100) }}</view>
10
+ </view>
11
+ </view>
12
+ <view class="vip_pay">
13
+ <view class="pay_btn" @click="toVipDetail">立即支付 <xd-unit style="margin-left: 16rpx;" :price="curVipCard.sale_price" :isOld="false" colorNew="#FFFFFF"></xd-unit></view>
14
+ <view class="vip_tip">开通视为同意<text @click.stop="handlePrivacy('privacy_service')">《共享PLUS会员用户协议》</text></view>
15
+ </view>
16
+ </view>
17
+ </template>
18
+
19
+ <script>
20
+ import XdButton from "@/components/XdButton/XdButton.vue"
21
+ import XdUnit from "@/components/XdUnit/XdUnit.vue"
22
+ export default {
23
+ components: {
24
+ XdButton,
25
+ XdUnit
26
+ },
27
+ props: {
28
+ list: {
29
+ type: Array,
30
+ default(){
31
+ return []
32
+ }
33
+ }
34
+ },
35
+ watch: {
36
+ list(val){
37
+ this.vip_card_id = val[0].vip_card_id || ''
38
+ this.uiList = val
39
+ }
40
+ },
41
+ computed: {
42
+ curVipCard(){
43
+ return this.uiList.find(item => item.vip_card_id === this.vip_card_id) || {}
44
+ }
45
+ },
46
+ data(){
47
+ return {
48
+ uiList: [],
49
+ vip_card_id: ''
50
+ }
51
+ },
52
+ methods: {
53
+ handlePrivacy(type){
54
+ this.$emit('handlePrivacy', type)
55
+ },
56
+ handleChoseVip(vip_card_id){
57
+ this.vip_card_id = vip_card_id
58
+ },
59
+ toVipDetail(){
60
+ if(this.vip_card_id){
61
+ this.$emit('toVipDetail', this.vip_card_id)
62
+ }
63
+ }
64
+ }
65
+ }
66
+ </script>
67
+
68
+ <style lang="less" scoped>
69
+ .xd_vip_wrap{
70
+ background: #FFFFFF;
71
+ .vip_list{
72
+ width: 100%;
73
+ overflow: auto;
74
+ white-space: nowrap;
75
+ padding: 32rpx 16rpx;
76
+ .vip_item{
77
+ display: inline-block;
78
+ width: 160rpx;
79
+ height: 112rpx;
80
+ border-radius: 24rpx;
81
+ text-align: center;
82
+ color: #999999;
83
+ border: 4rpx solid #EEEEEE;
84
+ background-color: #EEEEEE;
85
+ box-sizing: border-box;
86
+ margin: 0 16rpx;
87
+ padding: 20rpx 0;
88
+ line-height: 1;
89
+ font-weight: 500;
90
+ &.active{
91
+ border-color: #AB6900;
92
+ background-color: #FFF2DE;
93
+ color: #AB6900;
94
+ }
95
+ .vip_name{
96
+ font-size: 24rpx;
97
+ margin-bottom: 12rpx;
98
+ }
99
+ .vip_price{
100
+ font-size: 36rpx;
101
+ }
102
+ }
103
+ }
104
+ .vip_pay{
105
+ padding: 24rpx 0 50rpx;
106
+ .pay_btn{
107
+ width: 600rpx;
108
+ display: flex;
109
+ align-items: center;
110
+ justify-content: center;
111
+ height: 80rpx;
112
+ background-color: var(--main-color);
113
+ color: #FFFFFF;
114
+ margin: 0 auto;
115
+ border-radius: 80rpx;
116
+ }
117
+ }
118
+ .vip_tip{
119
+ text-align: center;
120
+ font-size: 22rpx;
121
+ color: #999999;
122
+ margin-top: 24rpx;
123
+ }
124
+ }
125
+ </style>