jufubao-base 1.0.169-beta1 → 1.0.169-beta10
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 +1 -1
- package/src/components/JfbBaseLogin/Attr.js +54 -16
- package/src/components/JfbBaseMapSearch/MapSearchMp.vue +1 -1
- package/src/components/JfbBaseOrderDetail/Api.js +12 -7
- package/src/components/JfbBaseOrderDetail/Attr.js +28 -14
- package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetail.vue +68 -18
- package/src/components/JfbBaseOrderDetail/Mock.js +3 -1
- package/src/components/JfbBaseTfkCardBind/Api.js +49 -30
- package/src/components/JfbBaseTfkCardBind/Attr.js +61 -10
- package/src/components/JfbBaseTfkCardBind/JfbBaseTfkCardBind.vue +169 -9
- package/src/components/JfbBaseTfkCardBind/Mock.js +19 -9
- package/src/components/JfbBaseTfkCardDetail/Api.js +26 -0
- package/src/components/JfbBaseTfkCardDetail/Attr.js +336 -9
- package/src/components/JfbBaseTfkCardDetail/JfbBaseTfkCardDetail.vue +236 -30
- package/src/components/JfbBaseTfkCardDetail/Mock.js +2 -2
- package/src/components/JfbBaseTfkCardLogin/Attr.js +301 -5
- package/src/components/JfbBaseTfkCardLogin/JfbBaseTfkCardLogin.vue +317 -158
- package/src/components/JfbBaseTfkCardLogin/Mock.js +2 -46
- package/src/components/JfbBaseTfkCardLogin/XdCouponItem.vue +271 -0
- package/src/components/JfbBaseTfkSearch/AllList.vue +232 -0
- package/src/components/JfbBaseTfkSearch/Api.js +11 -42
- package/src/components/JfbBaseTfkSearch/Attr.js +225 -33
- package/src/components/JfbBaseTfkSearch/ContentCinema.vue +157 -0
- package/src/components/JfbBaseTfkSearch/ContentFilm.vue +179 -0
- package/src/components/JfbBaseTfkSearch/ContentProduct.vue +308 -0
- package/src/components/JfbBaseTfkSearch/ContentShop.vue +184 -0
- package/src/components/JfbBaseTfkSearch/CusAttr.js +213 -0
- package/src/components/JfbBaseTfkSearch/CustomList.vue +402 -0
- package/src/components/JfbBaseTfkSearch/JfbBaseTfkSearch.vue +230 -26
- package/src/components/JfbBaseTfkSearch/Mock.js +90 -11
- package/src/components/JfbBaseTfkSearch/SkeletonCinema.vue +45 -0
- package/src/components/JfbBaseTfkSearch/SkeletonFilm.vue +109 -0
- package/src/components/JfbBaseTfkSearch/SkeletonProduct.vue +246 -0
- package/src/components/JfbBaseTfkSearch/SkeletonShop.vue +81 -0
- package/src/components/JfbBaseTfkSearch/handleKeyword.js +24 -0
- package/src/components/JfbBaseTfkSearch/listMixins.js +153 -0
- package/src/components/JfbBaseTfkSearch/search.js +293 -0
- package/src/mixins/colorCardMixins.js +71 -9
- package/src/mixins/componentsMixins.js +346 -23
|
@@ -18,38 +18,43 @@
|
|
|
18
18
|
}">
|
|
19
19
|
<view class="menu_wrap" :style="menuBoxStyle">
|
|
20
20
|
<view class="menu_list">
|
|
21
|
-
<view class="menu_item"
|
|
22
|
-
|
|
23
|
-
|
|
21
|
+
<view class="menu_item"
|
|
22
|
+
:style="{
|
|
23
|
+
marginRight: menuItemMargin + 'px'
|
|
24
|
+
}"
|
|
25
|
+
@click="changeMenu('card')"
|
|
26
|
+
>
|
|
24
27
|
<view class="menu_item_inner"
|
|
25
28
|
:style="[menuType === 'card' ? menuItemActiveStyle : menuItemStyle, menuItemBoxStyle]">我的票券包</view>
|
|
26
29
|
</view>
|
|
27
|
-
<view class="menu_item">
|
|
30
|
+
<view class="menu_item" @click="changeMenu('coupon')">
|
|
28
31
|
<view class="menu_item_inner"
|
|
29
32
|
:style="[menuType === 'coupon' ? menuItemActiveStyle : menuItemStyle, menuItemBoxStyle]">我的优惠券</view>
|
|
30
33
|
</view>
|
|
31
34
|
</view>
|
|
32
|
-
<view @click="toBindCard">
|
|
35
|
+
<view class="bind_card" :style="bindCardBoxStyle" @click="toBindCard">
|
|
33
36
|
<xd-font-icon :icon="bindCardIcon.icon"
|
|
34
37
|
:color="bindCardIcon.color"
|
|
35
|
-
:
|
|
38
|
+
:size="bindCardIcon.size"
|
|
36
39
|
></xd-font-icon>
|
|
40
|
+
<view v-if="bindCardText" :style="getBindCardTextStyle">{{ bindCardText }}</view>
|
|
37
41
|
</view>
|
|
38
42
|
</view>
|
|
39
43
|
<view class="JfbBaseNotice">
|
|
40
44
|
<!--notice-->
|
|
41
45
|
<view class="jfb-base-tfk-card-login__body-line" v-if="!notice"></view>
|
|
42
|
-
<view
|
|
46
|
+
<view class="jfb-base-tfk-card-login__body-notice" :style="noticeWrapBoxStyle" v-if="notice">
|
|
43
47
|
<view
|
|
44
48
|
class="jfb-base-tfk-card-login__body-notice-in"
|
|
45
|
-
:style="
|
|
49
|
+
:style="noticeBoxStyle"
|
|
46
50
|
>
|
|
47
51
|
<xd-notice-bar
|
|
48
52
|
style="width: 100%"
|
|
53
|
+
:color="noticeFont.color"
|
|
49
54
|
:showIcon="true"
|
|
50
55
|
:scrollable="true"
|
|
51
56
|
:speed="20"
|
|
52
|
-
:fontSize="
|
|
57
|
+
:fontSize="noticeFont.size"
|
|
53
58
|
:height="70"
|
|
54
59
|
:is-no-bgc="false"
|
|
55
60
|
>
|
|
@@ -59,15 +64,14 @@
|
|
|
59
64
|
</xd-notice-bar>
|
|
60
65
|
</view>
|
|
61
66
|
</view>
|
|
62
|
-
<view class="jfb-base-tfk-card-login__body-notice" v-if="noticeStatus && isPreview && notice === ''">
|
|
67
|
+
<view class="jfb-base-tfk-card-login__body-notice" :style="noticeWrapBoxStyle" v-if="noticeStatus && isPreview && notice === ''">
|
|
63
68
|
<view
|
|
64
69
|
class="jfb-base-tfk-card-login__body-notice-in"
|
|
65
|
-
:style="{
|
|
66
|
-
background: noticeBackgroundColor,
|
|
70
|
+
:style="[noticeBoxStyle, {
|
|
67
71
|
textAlign: 'center',
|
|
68
72
|
color: dangerColor,
|
|
69
73
|
fontSize: 26 + 'rpx',
|
|
70
|
-
}">该组件未配置数据,因此改模块在正式环境将不显示</view>
|
|
74
|
+
}]">该组件未配置数据,因此改模块在正式环境将不显示</view>
|
|
71
75
|
</view>
|
|
72
76
|
<!--notice end-->
|
|
73
77
|
</view>
|
|
@@ -78,10 +82,14 @@
|
|
|
78
82
|
<view v-if="loadingList">
|
|
79
83
|
<view class="bind_list skeleton-wrap">
|
|
80
84
|
<view class="bind_item" v-for="i in 5" :key="i" :style="cardItemBoxStyle">
|
|
81
|
-
<view
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
+
<view>
|
|
86
|
+
<view class="bind_point"></view>
|
|
87
|
+
<view class="bind_deduct"></view>
|
|
88
|
+
</view>
|
|
89
|
+
<view>
|
|
90
|
+
<view class="bind_number"></view>
|
|
91
|
+
<view class="bind_time"></view>
|
|
92
|
+
</view>
|
|
85
93
|
<view class="bind_type"></view>
|
|
86
94
|
<view class="bind_btn"></view>
|
|
87
95
|
</view>
|
|
@@ -90,26 +98,45 @@
|
|
|
90
98
|
<view v-else>
|
|
91
99
|
<view v-if="cardList.length" class="bind_list">
|
|
92
100
|
<view class="bind_item" v-for="(item, i) in cardList" :key="i"
|
|
93
|
-
:style="cardItemBoxStyle">
|
|
94
|
-
<view
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
101
|
+
:style="cardItemBoxStyle" @click="toCardDetail(item)">
|
|
102
|
+
<view>
|
|
103
|
+
<view class="bind_point">
|
|
104
|
+
<xd-unit
|
|
105
|
+
:unitFontSize="24"
|
|
106
|
+
:fontSize="48"
|
|
107
|
+
:price="item.card_point"
|
|
108
|
+
:isOld="false"
|
|
109
|
+
:unit="item.unit || ''"
|
|
110
|
+
:colorNew="'#333333'"
|
|
111
|
+
></xd-unit>
|
|
112
|
+
</view>
|
|
113
|
+
<view v-if="item.other_card_point && item.card_point_type !== 1" class="bind_deduct">
|
|
114
|
+
兑换其他商品可抵:{{ item.other_card_point }}
|
|
115
|
+
</view>
|
|
116
|
+
</view>
|
|
117
|
+
<view>
|
|
118
|
+
<view class="bind_number">{{ item.card_number }}</view>
|
|
119
|
+
<view class="bind_time">{{ item.end_time }}到期</view>
|
|
120
|
+
</view>
|
|
98
121
|
<view class="bind_type" :style="{
|
|
99
122
|
top: cardPadding.top + 'rpx',
|
|
100
123
|
right: cardPadding.right + 'rpx',
|
|
101
124
|
}">
|
|
102
|
-
<view
|
|
103
|
-
<view>(可转票券)</view>
|
|
125
|
+
<view>{{ item.card_type_name }}</view>
|
|
126
|
+
<view v-if="item.is_exchange === 'Y'">(可转票券)</view>
|
|
104
127
|
</view>
|
|
105
|
-
<view class="bind_btn"
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
128
|
+
<view class="bind_btn"
|
|
129
|
+
:style="[{
|
|
130
|
+
right: cardPadding.right + 'rpx',
|
|
131
|
+
bottom: cardPadding.bottom + 'rpx',
|
|
132
|
+
borderRadius: cardBtnRadius + 'rpx',
|
|
133
|
+
padding: bindCardBtnPadding,
|
|
134
|
+
minWidth: cardBtnMinWidth + 'rpx',
|
|
135
|
+
}, item.is_login === 'Y' ? bindCardActiveStyle : bindCardBtnStyle]"
|
|
136
|
+
@click.stop="doCardLogin(item)"
|
|
137
|
+
>{{ item.is_login === 'Y' ? '已登录' : '登录'}}</view>
|
|
111
138
|
</view>
|
|
112
|
-
<view v-if="!hasCardList" class="no_more_card">没有更多券了,查看失效的票券 ></view>
|
|
139
|
+
<view v-if="!hasCardList" class="no_more_card" @click="toDisableUrl">没有更多券了,查看失效的票券 ></view>
|
|
113
140
|
</view>
|
|
114
141
|
<view v-else>
|
|
115
142
|
暂无数据
|
|
@@ -120,38 +147,18 @@
|
|
|
120
147
|
<!-- 优惠券 -->
|
|
121
148
|
<template v-else >
|
|
122
149
|
<view v-if="couponList.length" class="coupon_list">
|
|
123
|
-
<
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
<view class="cou_point">余额:120</view>
|
|
136
|
-
<view class="cou_btn" :style="[couponBtnStyle, {
|
|
137
|
-
padding: couponBtnPadding,
|
|
138
|
-
borderRadius: couponBtnRadius + 'rpx'
|
|
139
|
-
}]">去使用</view>
|
|
140
|
-
</view>
|
|
141
|
-
<view class="cont_bottom">
|
|
142
|
-
<view class="switch_rule">
|
|
143
|
-
<view>使用规则</view>
|
|
144
|
-
<view>
|
|
145
|
-
<xd-font-icon icon="iconxia_down" size="24"></xd-font-icon>
|
|
146
|
-
</view>
|
|
147
|
-
</view>
|
|
148
|
-
<view class="expand_rule">
|
|
149
|
-
这是一段文字规则描述,不知道又多长多长长...
|
|
150
|
-
</view>
|
|
151
|
-
</view>
|
|
152
|
-
</view>
|
|
153
|
-
</view>
|
|
154
|
-
<view v-if="!hasCouponList" class="no_more_card">没有更多券了,查看失效的票券 ></view>
|
|
150
|
+
<xd-coupon-item v-for="(item, i) in couponList" :key="i"
|
|
151
|
+
:couponRadius="couponRadius"
|
|
152
|
+
:couponImageUrl="couponImageUrl"
|
|
153
|
+
:couponTitleBgColor="couponTitleBgColor"
|
|
154
|
+
:couponUseBtnPadding="couponUseBtnPadding"
|
|
155
|
+
:couponBtnRadius="couponBtnRadius"
|
|
156
|
+
:couponBtnTextStyle="couponBtnTextStyle"
|
|
157
|
+
:couponLeftBgColor="couponLeftBgColor"
|
|
158
|
+
:item="item"
|
|
159
|
+
@useCoupon="doCardLogin(item)"
|
|
160
|
+
></xd-coupon-item>
|
|
161
|
+
<view v-if="!hasCouponList" class="no_more_card" @click="toDisableUrl">没有更多券了,查看失效的票券 ></view>
|
|
155
162
|
</view>
|
|
156
163
|
<view v-else>
|
|
157
164
|
暂无数据
|
|
@@ -166,6 +173,7 @@
|
|
|
166
173
|
|
|
167
174
|
<script>
|
|
168
175
|
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
176
|
+
import XdUnit from "@/components/XdUnit/XdUnit";
|
|
169
177
|
import { jfbRootExec } from "@/utils/xd.event";
|
|
170
178
|
import JfbBaseTfkCardLoginMixin from "./JfbBaseTfkCardLoginMixin";
|
|
171
179
|
import { getContainerPropsValue } from "@/utils/xd.base";
|
|
@@ -173,25 +181,38 @@
|
|
|
173
181
|
import extsMixins from "@/mixins/extsMixins";
|
|
174
182
|
import getServiceUrl from '@/common/getServiceUrl'
|
|
175
183
|
import XdNoticeBar from "@/components/XdNoticeBar/XdNoticeBar";
|
|
184
|
+
import XdCouponItem from "./XdCouponItem";
|
|
176
185
|
import Color from "color"
|
|
186
|
+
import { mapState, mapActions } from "vuex";
|
|
177
187
|
export default {
|
|
178
188
|
name: "JfbBaseTfkCardLogin",
|
|
179
189
|
components: {
|
|
180
190
|
XdFontIcon,
|
|
181
|
-
XdNoticeBar
|
|
191
|
+
XdNoticeBar,
|
|
192
|
+
XdCouponItem,
|
|
193
|
+
XdUnit
|
|
182
194
|
},
|
|
183
195
|
mixins: [
|
|
184
196
|
componentsMixins, extsMixins, JfbBaseTfkCardLoginMixin
|
|
185
197
|
],
|
|
186
198
|
data() {
|
|
187
199
|
return {
|
|
188
|
-
menuType: "
|
|
189
|
-
loadingList:
|
|
190
|
-
cardList: [
|
|
191
|
-
couponList: [
|
|
200
|
+
menuType: "card", // card, coupon
|
|
201
|
+
loadingList: true,
|
|
202
|
+
cardList: [],
|
|
203
|
+
couponList: [],
|
|
192
204
|
hasCardList: false,
|
|
193
205
|
hasCouponList: false,
|
|
194
206
|
|
|
207
|
+
inCallbackUrlOrg:'',//是否带有回调地址
|
|
208
|
+
inCallback: null, //内部跳转地址
|
|
209
|
+
allEntryPath: "", //综合福利入口页
|
|
210
|
+
cardDetailPath: "", //我的票券包详情页
|
|
211
|
+
disabledPath: "", //禁用票券包详情页
|
|
212
|
+
|
|
213
|
+
options: {},
|
|
214
|
+
showDisabled: 'Y',
|
|
215
|
+
|
|
195
216
|
//todo
|
|
196
217
|
previewCurrent: "",
|
|
197
218
|
isPreview: false,
|
|
@@ -219,9 +240,28 @@
|
|
|
219
240
|
couponBtnTextStyle: {}, //优惠券包登录按钮文字背景色设置
|
|
220
241
|
couponUseBtnPadding: {},
|
|
221
242
|
couponBtnRadius: 16,
|
|
243
|
+
couponLeftBgColor: "",
|
|
244
|
+
noticeBgColor: "",
|
|
245
|
+
noticeMargin: {},
|
|
246
|
+
noticePadding: {},
|
|
247
|
+
noticeFont: {},
|
|
248
|
+
bindCardText: "",
|
|
249
|
+
bindCardTextStyle: {},
|
|
250
|
+
bindCardShowType: "",
|
|
251
|
+
bindCardBtnRadius: 16,
|
|
252
|
+
cardBorder: {},
|
|
253
|
+
cardShadow: {},
|
|
254
|
+
cardImageMode: "",
|
|
255
|
+
entryGroupId: "",
|
|
256
|
+
cardHeight: 270,
|
|
257
|
+
cardBtnMinWidth: 100,
|
|
222
258
|
}
|
|
223
259
|
},
|
|
224
260
|
computed: {
|
|
261
|
+
...mapState({
|
|
262
|
+
jwxSDK: (state) => state.jwxSDK,
|
|
263
|
+
jfbAuthorize: (state) => state.jfbAuthorize,
|
|
264
|
+
}),
|
|
225
265
|
menuBoxStyle(){
|
|
226
266
|
let padding = `${this.checkValue(this.menuPadding.top, 20)}rpx`;
|
|
227
267
|
padding = `${padding} ${this.checkValue(this.menuPadding.right, 20)}rpx`;
|
|
@@ -306,6 +346,21 @@
|
|
|
306
346
|
}
|
|
307
347
|
return this.styleObjectToString(styleObj)
|
|
308
348
|
},
|
|
349
|
+
bindCardBoxStyle(){
|
|
350
|
+
return this.styleObjectToString({
|
|
351
|
+
border: `1px solid ${this.bindCardShowType == 'button' ? this.bindCardTextStyle.color : 'transparent'}`,
|
|
352
|
+
borderRadius: this.bindCardBtnRadius + 'rpx',
|
|
353
|
+
})
|
|
354
|
+
},
|
|
355
|
+
getBindCardTextStyle(){
|
|
356
|
+
let styleObj = {
|
|
357
|
+
color: this.bindCardTextStyle['color'] || '#333',
|
|
358
|
+
fontSize: this.bindCardTextStyle['fontSize'] || '30rpx',
|
|
359
|
+
fontWeight: this.bindCardTextStyle['fontWeight'] || 'normal',
|
|
360
|
+
marginLeft: this.bindCardIcon.icon ? '10rpx' : 0,
|
|
361
|
+
}
|
|
362
|
+
return this.styleObjectToString(styleObj)
|
|
363
|
+
},
|
|
309
364
|
getCardBgImage(){
|
|
310
365
|
let bg = '';
|
|
311
366
|
if(this.$xdUniHelper.checkVarType(this.cardImageUrl) === 'object'
|
|
@@ -319,18 +374,35 @@
|
|
|
319
374
|
},
|
|
320
375
|
cardItemBoxStyle(){
|
|
321
376
|
let image = {};
|
|
377
|
+
let border = "none";
|
|
378
|
+
let boxShadow = "none";
|
|
379
|
+
if(this.cardBorder && this.cardBorder.type === 'Y'){
|
|
380
|
+
let { width, color } = this.cardBorder.value;
|
|
381
|
+
border = `${width}rpx solid ${color}`;
|
|
382
|
+
}
|
|
383
|
+
if(this.cardShadow && this.cardShadow.type === 'Y'){
|
|
384
|
+
let { width, color } = this.cardShadow.value;
|
|
385
|
+
boxShadow = `0 0 ${width}rpx ${color}`;
|
|
386
|
+
}
|
|
322
387
|
if(this.cardImageUrl) image = {
|
|
323
388
|
backgroundImage: `url(${this.getCardBgImage})`,
|
|
324
389
|
backgroundSize: '100%',
|
|
325
390
|
backgroundRepeat: 'no-repeat',
|
|
326
391
|
}
|
|
392
|
+
if(this.cardImageMode) image['backgroundSize'] = this.cardImageMode;
|
|
393
|
+
|
|
327
394
|
let padding = `${this.checkValue(this.cardPadding.top, 20)}rpx`;
|
|
328
395
|
padding = `${padding} ${this.checkValue(this.cardPadding.right, 20)}rpx`;
|
|
329
396
|
padding = `${padding} ${this.checkValue(this.cardPadding.bottom, 20)}rpx`;
|
|
330
397
|
padding = `${padding} ${this.checkValue(this.cardPadding.left, 20)}rpx`;
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
398
|
+
return this.styleObjectToString({
|
|
399
|
+
...image,
|
|
400
|
+
padding: padding,
|
|
401
|
+
borderRadius: this.cardRadius + 'rpx',
|
|
402
|
+
border: border,
|
|
403
|
+
boxShadow: boxShadow,
|
|
404
|
+
height: this.cardHeight + 'rpx',
|
|
405
|
+
})
|
|
334
406
|
},
|
|
335
407
|
listBoxStyle(){
|
|
336
408
|
let padding = `${this.checkValue(this.cardListPadding.top, 20)}rpx`;
|
|
@@ -367,6 +439,26 @@
|
|
|
367
439
|
borderRadius: this.couponRadius + 'rpx',
|
|
368
440
|
})
|
|
369
441
|
},
|
|
442
|
+
noticeWrapBoxStyle(){
|
|
443
|
+
let padding = `${this.checkValue(this.noticeMargin.top, 20)}rpx`;
|
|
444
|
+
padding = `${padding} ${this.checkValue(this.noticeMargin.right, 20)}rpx`;
|
|
445
|
+
padding = `${padding} ${this.checkValue(this.noticeMargin.bottom, 20)}rpx`;
|
|
446
|
+
padding = `${padding} ${this.checkValue(this.noticeMargin.left, 20)}rpx`;
|
|
447
|
+
|
|
448
|
+
return this.styleObjectToString({
|
|
449
|
+
padding: padding,
|
|
450
|
+
})
|
|
451
|
+
},
|
|
452
|
+
noticeBoxStyle(){
|
|
453
|
+
let padding = `${this.checkValue(this.noticePadding.top, 20)}rpx`;
|
|
454
|
+
padding = `${padding} ${this.checkValue(this.noticePadding.right, 20)}rpx`;
|
|
455
|
+
padding = `${padding} ${this.checkValue(this.noticePadding.bottom, 20)}rpx`;
|
|
456
|
+
padding = `${padding} ${this.checkValue(this.noticePadding.left, 20)}rpx`;
|
|
457
|
+
return this.styleObjectToString({
|
|
458
|
+
padding: padding,
|
|
459
|
+
background: this.noticeBgColor
|
|
460
|
+
})
|
|
461
|
+
}
|
|
370
462
|
},
|
|
371
463
|
watch: {
|
|
372
464
|
container(value, oldValue) {
|
|
@@ -382,6 +474,22 @@
|
|
|
382
474
|
},
|
|
383
475
|
methods: {
|
|
384
476
|
onJfbLoad(options) {
|
|
477
|
+
this.options = options;
|
|
478
|
+
let { inCallback } = options;
|
|
479
|
+
if(!inCallback) this.$storage.remove("inCallback"); //作为入口
|
|
480
|
+
else {
|
|
481
|
+
this.$storage.set("inCallback", inCallback);
|
|
482
|
+
try{
|
|
483
|
+
inCallback = Base64.decode(inCallback);
|
|
484
|
+
this.inCallbackUrlOrg = options.inCallback;
|
|
485
|
+
}catch (e){
|
|
486
|
+
inCallback = null;
|
|
487
|
+
}
|
|
488
|
+
}
|
|
489
|
+
//登录成功调整地址优先级
|
|
490
|
+
this.inCallback = inCallback || this.allEntryPath || this.settings.index;
|
|
491
|
+
|
|
492
|
+
this.getCardList();
|
|
385
493
|
this.getContent();
|
|
386
494
|
},
|
|
387
495
|
/**
|
|
@@ -411,13 +519,118 @@
|
|
|
411
519
|
this.couponBtnTextStyle = getContainerPropsValue(value, "content.couponBtnTextStyle", {});
|
|
412
520
|
this.couponUseBtnPadding = getContainerPropsValue(value, "content.couponUseBtnPadding", {top: 20, left: 20, right: 20, bottom: 20});
|
|
413
521
|
this.couponBtnRadius = getContainerPropsValue(value, "content.couponBtnRadius", 16);
|
|
522
|
+
this.couponLeftBgColor = getContainerPropsValue(value, "content.couponLeftBgColor", "");
|
|
523
|
+
this.noticeBgColor = getContainerPropsValue(value, "content.noticeBgColor", "");
|
|
524
|
+
this.noticeMargin = getContainerPropsValue(value, "content.noticeMargin", {top: 20, left: 20, right: 20, bottom: 20});
|
|
525
|
+
this.noticePadding = getContainerPropsValue(value, "content.noticePadding", {top: 20, left: 20, right: 20, bottom: 20});
|
|
526
|
+
this.noticeFont = getContainerPropsValue(value, "content.noticeFont", {});
|
|
527
|
+
this.bindCardText = getContainerPropsValue(value, "content.bindCardText", "");
|
|
528
|
+
this.bindCardTextStyle = getContainerPropsValue(value, "content.bindCardTextStyle", {});
|
|
529
|
+
this.bindCardShowType = getContainerPropsValue(value, "content.bindCardShowType", 'text');
|
|
530
|
+
this.bindCardBtnRadius = getContainerPropsValue(value, "content.bindCardBtnRadius", 16);
|
|
531
|
+
this.cardBorder = getContainerPropsValue(value, "content.cardBorder", {});
|
|
532
|
+
this.cardShadow = getContainerPropsValue(value, "content.cardShadow", {});
|
|
533
|
+
this.cardImageMode = getContainerPropsValue(value, "content.cardImageMode", '');
|
|
534
|
+
this.allEntryPath = getContainerPropsValue(value, "content.allEntryPath", {value: ""}).value;
|
|
535
|
+
this.cardDetailPath = getContainerPropsValue(value, "content.cardDetailPath", {value: ""}).value;
|
|
536
|
+
// this.entryGroupId = getContainerPropsValue(value,"content.entryGroupId","default");
|
|
537
|
+
this.cardHeight = getContainerPropsValue(value, "content.cardHeight", 270);
|
|
538
|
+
this.cardBtnMinWidth = getContainerPropsValue(value, "content.cardBtnMinWidth", 100);
|
|
539
|
+
this.disabledPath = getContainerPropsValue(value, "content.disabledPath", {value: ""}).value;
|
|
414
540
|
|
|
415
|
-
console.log(this.
|
|
541
|
+
console.log(this.cardShadow, 'cardShadow')
|
|
542
|
+
if(this.bindCardTextStyle && !this.bindCardTextStyle.color){
|
|
543
|
+
this.bindCardTextStyle.color = this.mainColor;
|
|
544
|
+
}
|
|
545
|
+
if(this.bindCardIcon && !this.bindCardIcon.color){
|
|
546
|
+
this.bindCardIcon.color = this.mainColor;
|
|
547
|
+
}
|
|
548
|
+
if(this.menuTabColor && !this.menuTabColor.actColor){
|
|
549
|
+
this.menuTabColor.actColor = this.mainColor;
|
|
550
|
+
}
|
|
551
|
+
if(this.cardBtnTextStyle){
|
|
552
|
+
if(!this.cardBtnTextStyle.actBgColor){
|
|
553
|
+
this.cardBtnTextStyle.actBgColor = this.mainColor;
|
|
554
|
+
}
|
|
555
|
+
if(!this.cardBtnTextStyle.bgColor){
|
|
556
|
+
this.cardBtnTextStyle.bgColor = this.mainColor;
|
|
557
|
+
}
|
|
558
|
+
}
|
|
416
559
|
|
|
417
560
|
if(this.$configProject.isPreview){
|
|
418
561
|
this.menuType = this.previewCurrent;
|
|
562
|
+
this.getCardList();
|
|
419
563
|
}
|
|
420
564
|
},
|
|
565
|
+
toCardDetail(item){
|
|
566
|
+
this.$xdUniHelper.navigateTo({
|
|
567
|
+
url: this.cardDetailPath + `?card_number=${item["card_number"]}`
|
|
568
|
+
},false)
|
|
569
|
+
},
|
|
570
|
+
doCardLogin(item){
|
|
571
|
+
this.$xdShowLoading({});
|
|
572
|
+
jfbRootExec("loginTfkCardBind", {
|
|
573
|
+
vm: this,
|
|
574
|
+
data: {
|
|
575
|
+
card_number: item["card_number"]
|
|
576
|
+
}
|
|
577
|
+
}).then(res => {
|
|
578
|
+
this.$xdHideLoading();
|
|
579
|
+
//#ifdef MP-WEIXIN
|
|
580
|
+
if (this.jfbAuthorize !== null) {
|
|
581
|
+
this.jfbAuthorize.setCardToken(res);
|
|
582
|
+
}
|
|
583
|
+
//#endif
|
|
584
|
+
|
|
585
|
+
if (this.$configProject.isPreview) {
|
|
586
|
+
console.log("handleBindLogin", "预览模式不跳转", this.inCallback);
|
|
587
|
+
} else {
|
|
588
|
+
this.$xdUniHelper.redirectTo({
|
|
589
|
+
url: this.inCallback,
|
|
590
|
+
});
|
|
591
|
+
}
|
|
592
|
+
}).catch((res) => {
|
|
593
|
+
this.$xdHideLoading();
|
|
594
|
+
});
|
|
595
|
+
},
|
|
596
|
+
changeMenu(menu){
|
|
597
|
+
this.menuType = menu;
|
|
598
|
+
this.getCardList();
|
|
599
|
+
},
|
|
600
|
+
getCardList(){
|
|
601
|
+
let show_type = this.menuType === 'coupon' ? 'coupon' : 'normal';
|
|
602
|
+
let params = {show_type};
|
|
603
|
+
|
|
604
|
+
// let params = {is_all: 'Y', is_show_entry_settings: 'Y'};
|
|
605
|
+
// if(options['jfb_business_code']) {
|
|
606
|
+
// params['card_business_code'] = options['jfb_business_code'];
|
|
607
|
+
// }
|
|
608
|
+
// if(this.entryGroupId) params['group_id'] = this.entryGroupId;
|
|
609
|
+
this.$xdShowLoading({});
|
|
610
|
+
jfbRootExec("getTfkListCardBind", {
|
|
611
|
+
vm: this,
|
|
612
|
+
data: params,
|
|
613
|
+
}).then(res => {
|
|
614
|
+
this.loadingList = false;
|
|
615
|
+
this.$xdHideLoading();
|
|
616
|
+
this.showDisabled = res.is_show_invalid_card_entrance;
|
|
617
|
+
|
|
618
|
+
let list = res.list.map(item => {
|
|
619
|
+
item.other_card_point = item.other_card_point ? this.$xdUniHelper.divisionFloatNumber(item.other_card_point, 100) : 0
|
|
620
|
+
return item;
|
|
621
|
+
})
|
|
622
|
+
if(show_type === 'coupon'){
|
|
623
|
+
if(this.$configProject.isPreview){
|
|
624
|
+
list = list.filter(item => item.consume_type == 2)
|
|
625
|
+
}
|
|
626
|
+
this.couponList = list;
|
|
627
|
+
}
|
|
628
|
+
if(show_type === 'normal'){
|
|
629
|
+
this.cardList = list;
|
|
630
|
+
}
|
|
631
|
+
})
|
|
632
|
+
.catch(() => this.$xdHideLoading());
|
|
633
|
+
},
|
|
421
634
|
toBindCard(){
|
|
422
635
|
this.$xdUniHelper.navigateTo({
|
|
423
636
|
url: this.cardBindPath
|
|
@@ -444,8 +657,13 @@
|
|
|
444
657
|
console.error(error);
|
|
445
658
|
});
|
|
446
659
|
},
|
|
660
|
+
toDisableUrl(){
|
|
661
|
+
this.$xdUniHelper.navigateTo({
|
|
662
|
+
url: this.disabledPath
|
|
663
|
+
})
|
|
664
|
+
},
|
|
447
665
|
onJfbScroll(options) {
|
|
448
|
-
console.log('event.onJfbScroll', options)
|
|
666
|
+
// console.log('event.onJfbScroll', options)
|
|
449
667
|
},
|
|
450
668
|
onJfbReachBottom(options) {
|
|
451
669
|
console.log('event.onJfbReachBottom', options)
|
|
@@ -487,22 +705,21 @@
|
|
|
487
705
|
border-bottom: 1px solid transparent;
|
|
488
706
|
}
|
|
489
707
|
}
|
|
708
|
+
.bind_card{
|
|
709
|
+
display: flex;
|
|
710
|
+
align-items: center;
|
|
711
|
+
padding: 8rpx 20rpx;
|
|
712
|
+
border-radius: 16rpx;
|
|
713
|
+
}
|
|
490
714
|
}
|
|
491
715
|
&-notice {
|
|
492
716
|
width: 100%;
|
|
493
|
-
|
|
494
|
-
height: unit(80, rpx);
|
|
495
|
-
position: relative;
|
|
717
|
+
box-sizing: border-box;
|
|
496
718
|
&-in {
|
|
497
|
-
position: absolute;
|
|
498
|
-
left: unit(-30, rpx);
|
|
499
|
-
top: unit(0, rpx);
|
|
500
|
-
right: unit(-30, rpx);
|
|
501
|
-
bottom: 0;
|
|
502
719
|
display: flex;
|
|
503
|
-
padding: 0 unit(30, rpx);
|
|
504
720
|
overflow: hidden;
|
|
505
721
|
align-items: center;
|
|
722
|
+
box-sizing: border-box;
|
|
506
723
|
}
|
|
507
724
|
|
|
508
725
|
}
|
|
@@ -537,12 +754,23 @@
|
|
|
537
754
|
padding: 32rpx;
|
|
538
755
|
background: #fff;
|
|
539
756
|
border-radius: 16rpx;
|
|
540
|
-
|
|
757
|
+
box-sizing: border-box;
|
|
541
758
|
margin: var(--card-list-margin) 0;
|
|
542
759
|
position: relative;
|
|
760
|
+
display: flex;
|
|
761
|
+
flex-direction: column;
|
|
762
|
+
justify-content: space-between;
|
|
543
763
|
.bind_point{
|
|
544
|
-
color: #
|
|
764
|
+
color: #333333;
|
|
545
765
|
font-size: 48rpx;
|
|
766
|
+
::v-deep .xd-unit{
|
|
767
|
+
height: auto !important;
|
|
768
|
+
font-weight: bold;
|
|
769
|
+
align-items: flex-end;
|
|
770
|
+
.xd-unit__unit{
|
|
771
|
+
line-height: 1.7 !important;
|
|
772
|
+
}
|
|
773
|
+
}
|
|
546
774
|
}
|
|
547
775
|
.bind_deduct{
|
|
548
776
|
font-size: 28rpx;
|
|
@@ -584,86 +812,17 @@
|
|
|
584
812
|
background: #ddd;
|
|
585
813
|
padding: 16rpx 60rpx;
|
|
586
814
|
border-radius: 12rpx;
|
|
587
|
-
}
|
|
588
|
-
}
|
|
589
|
-
}
|
|
590
|
-
.coupon_list{
|
|
591
|
-
.coupon_item{
|
|
592
|
-
display: flex;
|
|
593
|
-
margin: 20rpx 0;
|
|
594
|
-
border-radius: 16rpx;
|
|
595
|
-
background: #FFFFFF;
|
|
596
|
-
overflow: hidden;
|
|
597
|
-
.coupon_left{
|
|
598
|
-
color: #FFFFFF;
|
|
599
|
-
width: 170rpx;
|
|
600
815
|
display: flex;
|
|
601
|
-
flex-direction: column;
|
|
602
816
|
align-items: center;
|
|
603
817
|
justify-content: center;
|
|
604
|
-
background: linear-gradient(180deg, #FFA852 0%, #FF5733 100%);
|
|
605
|
-
|
|
606
|
-
._point{
|
|
607
|
-
font-size: 48rpx;
|
|
608
|
-
}
|
|
609
|
-
._rule{
|
|
610
|
-
font-size: 24rpx;
|
|
611
|
-
}
|
|
612
|
-
}
|
|
613
|
-
.coupon_right{
|
|
614
|
-
flex: 1;
|
|
615
|
-
width: 530rpx;
|
|
616
|
-
.cont_top{
|
|
617
|
-
background: rgba(255, 87, 51, 0.1);
|
|
618
|
-
padding: 8rpx 40rpx;
|
|
619
|
-
font-size: 24rpx;
|
|
620
|
-
overflow: hidden;
|
|
621
|
-
white-space: nowrap;
|
|
622
|
-
text-overflow: ellipsis;
|
|
623
|
-
}
|
|
624
|
-
.cont_main{
|
|
625
|
-
position: relative;
|
|
626
|
-
padding: 28rpx 20rpx 28rpx 40rpx;
|
|
627
|
-
.cou_number{
|
|
628
|
-
font-size: 32rpx;
|
|
629
|
-
font-weight: bold;
|
|
630
|
-
}
|
|
631
|
-
.cou_time{
|
|
632
|
-
font-size: 28rpx;
|
|
633
|
-
margin: 16rpx 0;
|
|
634
|
-
}
|
|
635
|
-
.cou_point{
|
|
636
|
-
font-size: 28rpx;
|
|
637
|
-
}
|
|
638
|
-
.cou_btn{
|
|
639
|
-
position: absolute;
|
|
640
|
-
padding: 10rpx 30rpx;
|
|
641
|
-
background-color: #ddd;
|
|
642
|
-
border-radius: 12rpx;
|
|
643
|
-
right: 20rpx;
|
|
644
|
-
bottom: 20rpx;
|
|
645
|
-
}
|
|
646
|
-
}
|
|
647
|
-
.cont_bottom{
|
|
648
|
-
background: #EEEEEE;
|
|
649
|
-
.switch_rule{
|
|
650
|
-
display: flex;
|
|
651
|
-
align-items: center;
|
|
652
|
-
justify-content: space-between;
|
|
653
|
-
padding: 12rpx 40rpx;
|
|
654
|
-
}
|
|
655
|
-
.expand_rule{
|
|
656
|
-
padding: 12rpx 40rpx;
|
|
657
|
-
font-size: 20rpx;
|
|
658
|
-
overflow: hidden;
|
|
659
|
-
white-space: nowrap;
|
|
660
|
-
text-overflow: ellipsis;
|
|
661
|
-
background-color: #F5F5F5;
|
|
662
|
-
}
|
|
663
|
-
}
|
|
664
818
|
}
|
|
665
819
|
}
|
|
666
820
|
}
|
|
821
|
+
.coupon_list{
|
|
822
|
+
::v-deep .xd-coupon_item{
|
|
823
|
+
margin: var(--card-list-margin) 0;
|
|
824
|
+
}
|
|
825
|
+
}
|
|
667
826
|
.no_more_card{
|
|
668
827
|
text-align: center;
|
|
669
828
|
padding: 20rpx 0;
|