jufubao-base 1.0.146 → 1.0.148-beta1
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/common/ICB.SDK.js +78 -0
- package/src/common/authorize.js +187 -33
- package/src/components/JfbBaseAfterOrderList/JfbBaseAfterOrderList.vue +1 -1
- package/src/components/JfbBaseCard/JfbBaseCard.vue +10 -9
- package/src/components/JfbBaseCardBindV2/JfbBaseCardBindV2.vue +4 -2
- package/src/components/JfbBaseCardDetailEntry/JfbBaseCardDetailEntry.vue +1 -3
- package/src/components/JfbBaseCardDisabled/JfbBaseCardDisabled.vue +3 -3
- package/src/components/JfbBaseCardDisabledEntry/JfbBaseCardDisabledEntry.vue +10 -5
- package/src/components/JfbBaseCardDisabledEntry/cardListMixins.js +15 -1
- package/src/components/JfbBaseCardEntry/JfbBaseCardEntry.vue +5 -7
- package/src/components/JfbBaseCardInfo/JfbBaseCardInfo.vue +2 -1
- package/src/components/JfbBaseCardV2/JfbBaseCardV2.vue +1 -3
- package/src/components/JfbBaseCardV3/JfbBaseCardV3.vue +1 -3
- package/src/components/JfbBaseEntry/JfbBaseEntry.vue +12 -4
- package/src/components/JfbBaseLogin/Api.js +12 -0
- package/src/components/JfbBaseLogin/Attr.js +13 -1
- package/src/components/JfbBaseLogin/JfbBaseLogin.vue +95 -40
- package/src/components/JfbBaseNoticeBottom/JfbBaseNoticeBottom.vue +1 -34
- package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetail.vue +6 -6
- package/src/components/JfbBaseOrderList/JfbBaseOrderList.vue +8 -3
- package/src/components/JfbBasePay/JfbBasePay.vue +7 -17
- package/src/components/JfbBasePosterType/JfbBasePosterType.vue +1 -1
- package/src/components/JfbBaseSearch/JfbBaseSearch.vue +11 -1
- package/src/components/JfbBaseWxAuthorize/Api.js +13 -0
- package/src/components/JfbBaseWxAuthorize/Attr.js +20 -0
- package/src/components/JfbBaseWxAuthorize/JfbBaseWxAuthorize.vue +60 -5
|
@@ -65,6 +65,19 @@ export default {
|
|
|
65
65
|
|
|
66
66
|
},
|
|
67
67
|
|
|
68
|
+
clearData(){
|
|
69
|
+
this.ajaxCardList = null;
|
|
70
|
+
this.cardOrgList = []
|
|
71
|
+
this.cardList = null;
|
|
72
|
+
this.cardPageNum = 0;
|
|
73
|
+
this.cardComputedList = [];
|
|
74
|
+
this.cardLoading = false;
|
|
75
|
+
this.cardNextTop = 0;
|
|
76
|
+
this.cardIndex = 0;
|
|
77
|
+
this.contentStatus = false;
|
|
78
|
+
this.hasContent = true;
|
|
79
|
+
},
|
|
80
|
+
|
|
68
81
|
async handleCardComputed(paddingBottom=30){
|
|
69
82
|
this.$xdShowLoading({});
|
|
70
83
|
if(this.contentStatus === false) await this.getBoxTop();
|
|
@@ -83,7 +96,6 @@ export default {
|
|
|
83
96
|
return card
|
|
84
97
|
});
|
|
85
98
|
this.cardList = (this.cardList||[]).concat(arr);
|
|
86
|
-
this.cardPageNum++;
|
|
87
99
|
this.$xdHideLoading();
|
|
88
100
|
}).exec();
|
|
89
101
|
})
|
|
@@ -102,6 +114,7 @@ export default {
|
|
|
102
114
|
this.cardPageNum*this.cardPageLen,
|
|
103
115
|
this.cardPageNum*this.cardPageLen + this.cardPageLen
|
|
104
116
|
);
|
|
117
|
+
console.warn(`无效卡张数:${validCardList.length} 张,页码:第 ${this.cardPageNum} 页`);
|
|
105
118
|
if(this.cardComputedList.length < this.cardPageLen) {
|
|
106
119
|
this.hasContent = false;
|
|
107
120
|
}
|
|
@@ -120,6 +133,7 @@ export default {
|
|
|
120
133
|
this.cardPageNum*this.cardPageLen,
|
|
121
134
|
this.cardPageNum*this.cardPageLen + this.cardPageLen
|
|
122
135
|
);
|
|
136
|
+
console.warn(`无效卡张数:${this.cardOrgList.length} 张,页码:第 ${this.cardPageNum} 页`);
|
|
123
137
|
this.handleCardComputed().then().catch();
|
|
124
138
|
if(this.cardComputedList.length < this.cardPageLen) {
|
|
125
139
|
this.hasContent = false;
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
<!-- #endif -->
|
|
19
19
|
<view class="jfb-base-card-entry__body">
|
|
20
20
|
<view class="jfb-base-card-entry__body-cut">
|
|
21
|
-
<template v-if="
|
|
21
|
+
<template v-if="isQrCode">
|
|
22
22
|
<view
|
|
23
23
|
class="jfb-base-card-entry__body-cut-item"
|
|
24
24
|
@click="handleScan"
|
|
@@ -383,7 +383,7 @@ import extsMixins from "@/mixins/extsMixins";
|
|
|
383
383
|
import colorCardMixins from "@/mixins/colorCardMixins";
|
|
384
384
|
import cardListMixins from "@/mixins/cardListMixins";
|
|
385
385
|
import { mapState, mapActions } from "vuex";
|
|
386
|
-
import { getContainerPropsValue, isWechat } from "@/utils/xd.base";
|
|
386
|
+
import { getContainerPropsValue, isWechat,isQrCode } from "@/utils/xd.base";
|
|
387
387
|
import XdNoticeBar from "@/components/XdNoticeBar/XdNoticeBar";
|
|
388
388
|
import { Base64 } from "js-base64";
|
|
389
389
|
const Color = require("color");
|
|
@@ -434,7 +434,6 @@ export default {
|
|
|
434
434
|
noticeStatus: false,
|
|
435
435
|
loadingCardList: true,
|
|
436
436
|
|
|
437
|
-
isWx: true,
|
|
438
437
|
cutIndex: 1,
|
|
439
438
|
tabIndex: 1,
|
|
440
439
|
isBack: null, //是否使用返回键
|
|
@@ -454,6 +453,7 @@ export default {
|
|
|
454
453
|
showDisabled: 'Y',
|
|
455
454
|
showCardList: false,
|
|
456
455
|
showIndex:false,
|
|
456
|
+
isQrCode: false,
|
|
457
457
|
|
|
458
458
|
//活动
|
|
459
459
|
dialogEvent: false,
|
|
@@ -466,7 +466,7 @@ export default {
|
|
|
466
466
|
this.isPreview = this.$configProject.isPreview;
|
|
467
467
|
|
|
468
468
|
//#ifdef H5
|
|
469
|
-
this.
|
|
469
|
+
this.isQrCode = isQrCode(this);
|
|
470
470
|
if (!this.$configProject.isPreview) {
|
|
471
471
|
jfbRootExec("getH5WxAuthorize", {
|
|
472
472
|
vm: this,
|
|
@@ -592,9 +592,7 @@ export default {
|
|
|
592
592
|
this.$xdHideLoading();
|
|
593
593
|
//#ifdef MP-WEIXIN
|
|
594
594
|
if (this.jfbAuthorize !== null) {
|
|
595
|
-
this.jfbAuthorize.
|
|
596
|
-
expires: res["card_expire_in"] / 60 / 60,
|
|
597
|
-
});
|
|
595
|
+
this.jfbAuthorize.setCardToken(res);
|
|
598
596
|
this.handleToApp(entry);
|
|
599
597
|
}
|
|
600
598
|
//#endif
|
|
@@ -171,7 +171,7 @@ export default {
|
|
|
171
171
|
return this.fixedStyle({ height: 0, zIndex: 111 });
|
|
172
172
|
},
|
|
173
173
|
isShowBalance(){
|
|
174
|
-
if(this.info.is_expired === "Y"){
|
|
174
|
+
if(this.info && this.info.is_expired === "Y"){
|
|
175
175
|
return this.is_show_balance === "Y";
|
|
176
176
|
}
|
|
177
177
|
return true;
|
|
@@ -492,6 +492,7 @@ export default {
|
|
|
492
492
|
height: unit(320, rpx);
|
|
493
493
|
display: flex;
|
|
494
494
|
align-items: center;
|
|
495
|
+
justify-content: center;
|
|
495
496
|
}
|
|
496
497
|
}
|
|
497
498
|
}
|
|
@@ -226,9 +226,7 @@
|
|
|
226
226
|
this.$xdHideLoading();
|
|
227
227
|
//#ifdef MP-WEIXIN
|
|
228
228
|
if (this.jfbAuthorize !== null) {
|
|
229
|
-
this.jfbAuthorize.
|
|
230
|
-
expires: res["card_expire_in"] / 60 / 60,
|
|
231
|
-
});
|
|
229
|
+
this.jfbAuthorize.setCardToken(res);
|
|
232
230
|
}
|
|
233
231
|
//#endif
|
|
234
232
|
|
|
@@ -175,9 +175,7 @@
|
|
|
175
175
|
this.$xdHideLoading();
|
|
176
176
|
//#ifdef MP-WEIXIN
|
|
177
177
|
if (this.jfbAuthorize !== null) {
|
|
178
|
-
this.jfbAuthorize.
|
|
179
|
-
expires: res["card_expire_in"] / 60 / 60,
|
|
180
|
-
});
|
|
178
|
+
this.jfbAuthorize.setCardToken(res);
|
|
181
179
|
}
|
|
182
180
|
//#endif
|
|
183
181
|
|
|
@@ -136,10 +136,17 @@
|
|
|
136
136
|
return item;
|
|
137
137
|
}
|
|
138
138
|
|
|
139
|
-
let jumpUrl =
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
139
|
+
let jumpUrl = path;
|
|
140
|
+
|
|
141
|
+
//域名相同并且应用路径不相同时候处理
|
|
142
|
+
if(host === this.projectAttr.host
|
|
143
|
+
&& this.projectAttr['deploy_dir'] !== dir
|
|
144
|
+
){
|
|
145
|
+
jumpUrl = `//${host}/${dir}${path}`;
|
|
146
|
+
//#ifdef MP-WEIXIN
|
|
147
|
+
jumpUrl = `https:${jumpUrl}`;
|
|
148
|
+
//#endif
|
|
149
|
+
}
|
|
143
150
|
|
|
144
151
|
if(item['redirect_data']['fixed_business_code'] === '') {
|
|
145
152
|
item['redirect_data']['path'] = `${jumpUrl}?x-common=${nsp}&vs=${new Date().getTime()}`
|
|
@@ -149,6 +156,7 @@
|
|
|
149
156
|
}
|
|
150
157
|
return item;
|
|
151
158
|
});
|
|
159
|
+
console.log( this.entryList)
|
|
152
160
|
if(res.list.length === 1) this.toLink(this.entryList[0]);
|
|
153
161
|
if(res.list.length === 0) {
|
|
154
162
|
this.$xdAlert({content: '当前票券暂无支持服务'})
|
|
@@ -23,6 +23,18 @@ module.exports = [
|
|
|
23
23
|
phone_number_collect_url: ['收集手机号地址', 'String', '是'],
|
|
24
24
|
}
|
|
25
25
|
},
|
|
26
|
+
{
|
|
27
|
+
mapFnName: 'userBaseLoginIcb',
|
|
28
|
+
title: '工行e生活登录',
|
|
29
|
+
path: '/passport/v1/user/login-icbc',
|
|
30
|
+
isRule: false,
|
|
31
|
+
data: {
|
|
32
|
+
encrypted_params: ['用户登录信息', 'String', '必选'],
|
|
33
|
+
provider_id: ['登录方式id', 'Number', '必选'],
|
|
34
|
+
},
|
|
35
|
+
isConsole: true,
|
|
36
|
+
disabled: true,
|
|
37
|
+
},
|
|
26
38
|
{
|
|
27
39
|
mapFnName: 'phoneLogin',
|
|
28
40
|
title: "手机号登录",
|
|
@@ -539,6 +539,18 @@ export default {
|
|
|
539
539
|
},
|
|
540
540
|
inline: false,
|
|
541
541
|
},
|
|
542
|
-
|
|
542
|
+
{
|
|
543
|
+
label: '小程序手机号授权登录地址:', //label
|
|
544
|
+
ele: 'xd-select-pages-path', //package 名称
|
|
545
|
+
valueKey: 'mpAuthPhoneUrl', //form[valueKey]
|
|
546
|
+
groupKey: 'advanced',
|
|
547
|
+
placeholder: '请选择跳转地址',
|
|
548
|
+
value: null,
|
|
549
|
+
setting: {
|
|
550
|
+
router: XdBus.getParentApi('getPagesTree'),
|
|
551
|
+
},
|
|
552
|
+
notice: "首次快捷登录,将自动跳转至该地址",
|
|
553
|
+
inline: false,
|
|
554
|
+
},
|
|
543
555
|
]
|
|
544
556
|
}
|
|
@@ -30,8 +30,7 @@
|
|
|
30
30
|
type="primary"
|
|
31
31
|
radius="20rpx"
|
|
32
32
|
@click="doLoginAuth"
|
|
33
|
-
|
|
34
|
-
>
|
|
33
|
+
>{{h5FastLoginName}}</xd-button>
|
|
35
34
|
<!-- #endif -->
|
|
36
35
|
<!--#ifdef MP-->
|
|
37
36
|
<xd-button
|
|
@@ -50,8 +49,7 @@
|
|
|
50
49
|
type="primary"
|
|
51
50
|
radius="20rpx"
|
|
52
51
|
@click="doLoginAccount"
|
|
53
|
-
|
|
54
|
-
</xd-button>
|
|
52
|
+
>账号登录</xd-button>
|
|
55
53
|
</view>
|
|
56
54
|
|
|
57
55
|
<view class="protocol">
|
|
@@ -98,7 +96,7 @@
|
|
|
98
96
|
:border="true"
|
|
99
97
|
paddingBetween="40"
|
|
100
98
|
>
|
|
101
|
-
<xd-form-item class="form-item" label="手机号" content-align="left">
|
|
99
|
+
<xd-form-item class="form-item" label="手机号" :labelWidth="160" content-align="left">
|
|
102
100
|
<xd-form-input
|
|
103
101
|
v-model="accountForm.phone_number"
|
|
104
102
|
placeholder="请输入11位手机号"
|
|
@@ -107,6 +105,7 @@
|
|
|
107
105
|
<xd-form-item
|
|
108
106
|
v-if="accountLoginType === 'phone'"
|
|
109
107
|
label="验证码"
|
|
108
|
+
:labelWidth="160"
|
|
110
109
|
content-align="left"
|
|
111
110
|
>
|
|
112
111
|
<view class="flex align-center">
|
|
@@ -125,6 +124,7 @@
|
|
|
125
124
|
<xd-form-item
|
|
126
125
|
v-if="accountLoginType === 'pwd'"
|
|
127
126
|
label="密码"
|
|
127
|
+
:labelWidth="160"
|
|
128
128
|
content-align="left"
|
|
129
129
|
>
|
|
130
130
|
<xd-form-input
|
|
@@ -217,6 +217,7 @@ import {
|
|
|
217
217
|
getAllPath,
|
|
218
218
|
getDomainAllPath,
|
|
219
219
|
getLocalJumpOutSiteCallbackUrl,
|
|
220
|
+
isThirdLogin
|
|
220
221
|
} from "@/utils/xd.base";
|
|
221
222
|
|
|
222
223
|
export default {
|
|
@@ -236,6 +237,7 @@ export default {
|
|
|
236
237
|
//体验模式
|
|
237
238
|
dialogPreview: false,
|
|
238
239
|
previewAccout: '',
|
|
240
|
+
h5FastLoginName:'快捷登录',
|
|
239
241
|
|
|
240
242
|
showStep: 1,
|
|
241
243
|
panel_1_checked: "",
|
|
@@ -283,10 +285,11 @@ export default {
|
|
|
283
285
|
isDebugPreview: false,
|
|
284
286
|
|
|
285
287
|
isFastLoginStatus: false,
|
|
288
|
+
mpAuthPhoneUrl: "",
|
|
286
289
|
};
|
|
287
290
|
},
|
|
288
291
|
computed: {
|
|
289
|
-
...mapState(["jfbAuthorize","siteInfo"]),
|
|
292
|
+
...mapState(["jfbAuthorize","siteInfo",'loginParams']),
|
|
290
293
|
panelIsChecked() {
|
|
291
294
|
return this.panel_1_checked.includes(1);
|
|
292
295
|
},
|
|
@@ -316,7 +319,7 @@ export default {
|
|
|
316
319
|
this.init(this.container);
|
|
317
320
|
this.base = this.jfbAuthorize.getBasePath(this);
|
|
318
321
|
this.site_logo = getServiceUrl(this.projectAttr["site_logo"]);
|
|
319
|
-
this.$xdLog.setProject('JfbBaseLogin', 'JfbBaseLogin.create.done')
|
|
322
|
+
this.$xdLog.setProject('JfbBaseLogin', 'JfbBaseLogin.create.done');
|
|
320
323
|
},
|
|
321
324
|
|
|
322
325
|
methods: {
|
|
@@ -352,7 +355,10 @@ export default {
|
|
|
352
355
|
this.$xdShowLoading({});
|
|
353
356
|
try{
|
|
354
357
|
const res = await this.loginPreview(this.previewAccout);
|
|
355
|
-
if(res)
|
|
358
|
+
if(res){
|
|
359
|
+
this.jfbAuthorize.setAllToken(res);
|
|
360
|
+
this.jfbAuthorize.setCardToken(res['login_card_result'])
|
|
361
|
+
}
|
|
356
362
|
this.toHomeAfterLogin();
|
|
357
363
|
this.$xdHideLoading();
|
|
358
364
|
}catch (e){
|
|
@@ -362,35 +368,20 @@ export default {
|
|
|
362
368
|
|
|
363
369
|
|
|
364
370
|
onJfbLoad(options) {
|
|
371
|
+
this.$xdLog.setProject('JfbBaseLogin', 'JfbBaseLogin.onJfbLoad.start')
|
|
365
372
|
this.redirect_url = options.redirect_url ? Base64.decode(options.redirect_url): '';
|
|
366
373
|
this.isDebugPreview = options['x-test'] === 'jfb-tiyan';
|
|
367
374
|
// #ifdef MP-WEIXIN
|
|
368
375
|
this.authWxMpListProviders();
|
|
369
376
|
// #endif
|
|
370
|
-
|
|
377
|
+
|
|
371
378
|
// #ifdef H5
|
|
372
|
-
try{
|
|
373
|
-
|
|
374
|
-
}catch (error) {
|
|
379
|
+
try{ this.authH5ListProviders();}
|
|
380
|
+
catch (error) {
|
|
375
381
|
this.$xdLog.setProject('JfbBaseLogin', 'JfbBaseLogin.onJfbLoad.error');
|
|
376
382
|
this.$xdLog.setARMSError(error);
|
|
377
383
|
}
|
|
378
384
|
//#endif
|
|
379
|
-
|
|
380
|
-
// if (options.isDebug === "1") {
|
|
381
|
-
// getAllPath(this, "main/play/index");
|
|
382
|
-
// getDomainAllPath(this, "main/play/index");
|
|
383
|
-
// getLocalJumpOutSiteCallbackUrl(
|
|
384
|
-
// this,
|
|
385
|
-
// { customParams: 1 },
|
|
386
|
-
// false,
|
|
387
|
-
// "main/play/index"
|
|
388
|
-
// );
|
|
389
|
-
//
|
|
390
|
-
// getAllPath(this);
|
|
391
|
-
// getDomainAllPath(this);
|
|
392
|
-
// getLocalJumpOutSiteCallbackUrl(this, { customParams: 1 }, false);
|
|
393
|
-
// }
|
|
394
385
|
},
|
|
395
386
|
|
|
396
387
|
/**
|
|
@@ -415,6 +406,7 @@ export default {
|
|
|
415
406
|
this.phone_number_collect_url = getContainerPropsValue(value, "content.phone_number_collect_url", {value: ''}).value;
|
|
416
407
|
this.forget_pwd_url = getContainerPropsValue(value, "content.forget_pwd_url", {value: ''}).value;
|
|
417
408
|
this.error_callback_url = getContainerPropsValue(value, "content.error_url", {value: ''}).value;
|
|
409
|
+
this.mpAuthPhoneUrl = getContainerPropsValue(value, "content.mpAuthPhoneUrl", {value: '/system/login/wxauthorize'}).value;
|
|
418
410
|
this.isPreview = getContainerPropsValue(value, "content.isPreview", 'N');
|
|
419
411
|
},
|
|
420
412
|
|
|
@@ -425,6 +417,11 @@ export default {
|
|
|
425
417
|
if (res.quick_enabled) {
|
|
426
418
|
this.hasAuthLogin = true;
|
|
427
419
|
this.quickLogin = res.quick;
|
|
420
|
+
|
|
421
|
+
//工行处理
|
|
422
|
+
if(this.quickLogin.login_platform_code === 'icbc') {
|
|
423
|
+
this.h5FastLoginName = '工银e生活登录'
|
|
424
|
+
}
|
|
428
425
|
}
|
|
429
426
|
if (res.others.length > 0) {
|
|
430
427
|
this.hasAccountLogin = true;
|
|
@@ -482,23 +479,28 @@ export default {
|
|
|
482
479
|
},
|
|
483
480
|
})
|
|
484
481
|
.then((res) => {
|
|
482
|
+
let { redirect_url, callback_url } = this;
|
|
483
|
+
//if (redirect_url) redirect_url = redirect_url;
|
|
484
|
+
let url = Base64.encodeURI(redirect_url || callback_url || this.settings.index);
|
|
485
485
|
//需要授权操作
|
|
486
486
|
if (res.auth_code) {
|
|
487
|
-
let { redirect_url, callback_url } = this;
|
|
488
|
-
if (redirect_url)
|
|
489
|
-
redirect_url = redirect_url;
|
|
490
|
-
let url = Base64.encodeURI(
|
|
491
|
-
redirect_url || callback_url || this.settings.index
|
|
492
|
-
);
|
|
493
487
|
this.$xdUniHelper.navigateTo({
|
|
494
|
-
url:
|
|
488
|
+
url: `${this.mpAuthPhoneUrl}?auth_code=${res.auth_code}&provider_id=${this.quickLogin.provider_id}&url=${url}`,
|
|
495
489
|
});
|
|
496
490
|
}
|
|
497
491
|
//无需授权直接进行登录
|
|
498
492
|
else {
|
|
499
493
|
if (this.jfbAuthorize !== null) {
|
|
500
494
|
this.jfbAuthorize.setAllToken(res["login_info"], () => {
|
|
501
|
-
|
|
495
|
+
//需要收集手机号码
|
|
496
|
+
if(res['is_collect_phone_number'] === 'Y'){
|
|
497
|
+
this.$xdUniHelper.navigateTo({
|
|
498
|
+
url: `${this.mpAuthPhoneUrl}?provider_id=${this.quickLogin.provider_id}&url=${url}`,
|
|
499
|
+
});
|
|
500
|
+
}
|
|
501
|
+
else{
|
|
502
|
+
this.toHomeAfterLogin();
|
|
503
|
+
}
|
|
502
504
|
});
|
|
503
505
|
}
|
|
504
506
|
}
|
|
@@ -550,12 +552,12 @@ export default {
|
|
|
550
552
|
};
|
|
551
553
|
|
|
552
554
|
this.$xdLog.setProject('JfbBaseLogin', 'JfbBaseLogin.onJfbLoad.loading..');
|
|
553
|
-
|
|
554
555
|
jfbRootExec("listSiteProvider", {
|
|
555
556
|
vm: this,
|
|
556
557
|
data: params,
|
|
557
558
|
})
|
|
558
559
|
.then((res) => {
|
|
560
|
+
console.log('listSiteProvider',res)
|
|
559
561
|
this.handleAuthResult(res);
|
|
560
562
|
})
|
|
561
563
|
.catch((error) => {
|
|
@@ -603,12 +605,59 @@ export default {
|
|
|
603
605
|
setAccountLoginType(type) {
|
|
604
606
|
this.accountLoginType = type;
|
|
605
607
|
},
|
|
608
|
+
|
|
609
|
+
/**
|
|
610
|
+
* @description 工行e生活处理
|
|
611
|
+
*/
|
|
612
|
+
icbcLogin(){
|
|
613
|
+
//无三方用户登录信息
|
|
614
|
+
if(!this.loginParams) {
|
|
615
|
+
this.status = false;
|
|
616
|
+
console.warn(`无三方用户登录信息`);
|
|
617
|
+
throw new Error('无三方用户登录信息');
|
|
618
|
+
}
|
|
619
|
+
|
|
620
|
+
console.warn(`LoginParams.use: ${this.loginParams}`)
|
|
621
|
+
this.$xdShowLoading({});
|
|
622
|
+
jfbRootExec("userBaseLoginIcb", {
|
|
623
|
+
vm: this,
|
|
624
|
+
data:{
|
|
625
|
+
encrypted_params: this.loginParams,
|
|
626
|
+
provider_id: this.quickLogin.provider_id
|
|
627
|
+
},
|
|
628
|
+
})
|
|
629
|
+
.then(res=>{
|
|
630
|
+
this.$xdHideLoading();
|
|
631
|
+
this.$xdUniHelper.redirectTo({
|
|
632
|
+
url: this.redirect_url || this.$settings.index,
|
|
633
|
+
},false, true);
|
|
634
|
+
})
|
|
635
|
+
.catch(err=>{
|
|
636
|
+
this.$xdHideLoading();
|
|
637
|
+
console.error(err);
|
|
638
|
+
})
|
|
639
|
+
},
|
|
640
|
+
|
|
606
641
|
//h5授权登录
|
|
607
642
|
doLoginAuth() {
|
|
608
643
|
if(this.isFastLoginStatus) return;
|
|
609
644
|
this.isFastLoginStatus = true;
|
|
610
|
-
|
|
611
|
-
|
|
645
|
+
|
|
646
|
+
//工行处理
|
|
647
|
+
if(this.quickLogin && this.quickLogin.login_platform_code === 'icbc'){
|
|
648
|
+
window['ICBC_SDK']['merLogin']((res)=>{
|
|
649
|
+
console.log('ICBC_SDK',res);
|
|
650
|
+
this.icbcLogin(res)
|
|
651
|
+
})
|
|
652
|
+
return;
|
|
653
|
+
}
|
|
654
|
+
|
|
655
|
+
//跳转到第三方进行授权
|
|
656
|
+
if(this.quickLogin.is_redirect === 'Y') {
|
|
657
|
+
const { redirect_url } = this.quickLogin;
|
|
658
|
+
location.href = redirect_url;
|
|
659
|
+
}
|
|
660
|
+
|
|
612
661
|
},
|
|
613
662
|
|
|
614
663
|
//小程序授权登录
|
|
@@ -707,9 +756,9 @@ export default {
|
|
|
707
756
|
});
|
|
708
757
|
}
|
|
709
758
|
},
|
|
759
|
+
|
|
710
760
|
toHomeAfterLogin() {
|
|
711
761
|
let { redirect_url, callback_url } = this;
|
|
712
|
-
if (redirect_url) redirect_url = redirect_url;
|
|
713
762
|
this.$xdUniHelper.redirectTo({
|
|
714
763
|
url: redirect_url || callback_url || this.settings.index,
|
|
715
764
|
});
|
|
@@ -767,7 +816,7 @@ export default {
|
|
|
767
816
|
padding: 40rpx 70rpx;
|
|
768
817
|
}
|
|
769
818
|
.form-item {
|
|
770
|
-
|
|
819
|
+
::v-deep .uni-forms-item {
|
|
771
820
|
padding-left: unit(30rpx) !important;
|
|
772
821
|
}
|
|
773
822
|
}
|
|
@@ -777,6 +826,12 @@ export default {
|
|
|
777
826
|
margin-right: unit(20,rpx);
|
|
778
827
|
}
|
|
779
828
|
.panel-login-auth {
|
|
829
|
+
/deep/ .uni-forms-item__label {
|
|
830
|
+
.label-text {
|
|
831
|
+
font-size: 26rpx;
|
|
832
|
+
color: #a6a6a6;
|
|
833
|
+
}
|
|
834
|
+
}
|
|
780
835
|
.logo-wrap {
|
|
781
836
|
text-align: center;
|
|
782
837
|
margin: unit(165,rpx) 0;
|
|
@@ -35,7 +35,6 @@
|
|
|
35
35
|
data() {
|
|
36
36
|
return {
|
|
37
37
|
|
|
38
|
-
//todo
|
|
39
38
|
}
|
|
40
39
|
},
|
|
41
40
|
watch: {
|
|
@@ -45,50 +44,18 @@
|
|
|
45
44
|
},
|
|
46
45
|
created() {
|
|
47
46
|
this.init(this.container);
|
|
48
|
-
|
|
49
|
-
//todo
|
|
50
47
|
},
|
|
51
48
|
methods: {
|
|
52
49
|
onJfbLoad(options) {
|
|
53
50
|
|
|
54
|
-
// jfbRootExec('baiduUserLogin', {
|
|
55
|
-
|
|
56
|
-
// vm: this,// data: {
|
|
57
|
-
|
|
58
|
-
// account: 'gaoshiyong',// password: '123456789',// type: 3,// ...options
|
|
59
|
-
|
|
60
|
-
// }
|
|
61
|
-
|
|
62
|
-
// }).then().catch()
|
|
63
51
|
},
|
|
64
52
|
/**
|
|
65
53
|
* @description 监听事件变化
|
|
66
54
|
* @param container {object} 业务组件对象自己
|
|
67
55
|
*/
|
|
68
56
|
init(container) {
|
|
69
|
-
|
|
70
|
-
//this.bgcolor = getContainerPropsValue(container, 'content.bgcolor', '#fff');
|
|
71
|
-
|
|
72
|
-
//this.height = getContainerPropsValue(container, 'content.height', 10);
|
|
73
|
-
},
|
|
74
|
-
onJfbScroll(options) {
|
|
75
|
-
console.log('event.onJfbScroll', options)
|
|
76
|
-
},
|
|
77
|
-
onJfbReachBottom(options) {
|
|
78
|
-
console.log('event.onJfbReachBottom', options)
|
|
79
|
-
},
|
|
80
|
-
onJfbShow(options) {
|
|
81
|
-
console.log('event.onJfbShow', options)
|
|
82
|
-
},
|
|
83
|
-
onJfbHide(options) {
|
|
84
|
-
console.log('event.onJfbHide', options)
|
|
85
|
-
},
|
|
86
|
-
onJfbBack(options) {
|
|
87
|
-
console.log('event.onJfbBack', options)
|
|
88
|
-
},
|
|
89
|
-
onJfbCustomEvent(options) {
|
|
90
|
-
console.log('event.onJfbReachBottom', options)
|
|
91
57
|
},
|
|
58
|
+
|
|
92
59
|
}
|
|
93
60
|
}
|
|
94
61
|
|
|
@@ -239,8 +239,8 @@
|
|
|
239
239
|
:key="Dindex"
|
|
240
240
|
class="jfb-base-order-detail__body-delivery-bottom-item"
|
|
241
241
|
>
|
|
242
|
-
<view
|
|
243
|
-
<
|
|
242
|
+
<view style="width: 130rpx;display: flex;">
|
|
243
|
+
<view v-html="Ditem.label"></view>
|
|
244
244
|
<text v-if="Ditem.label">:</text>
|
|
245
245
|
</view>
|
|
246
246
|
<view v-html="Ditem.value"></view>
|
|
@@ -563,10 +563,10 @@
|
|
|
563
563
|
class="jfb-base-order-detail__body-order"
|
|
564
564
|
>
|
|
565
565
|
<view :style="{ fontWeight: item.style }">
|
|
566
|
-
<view
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
>
|
|
566
|
+
<view style="display: flex;">
|
|
567
|
+
<view v-html="item.label"></view>
|
|
568
|
+
<text v-if="item.label">:</text>
|
|
569
|
+
</view>
|
|
570
570
|
<view v-html="item.value"></view>
|
|
571
571
|
</view>
|
|
572
572
|
<view
|
|
@@ -96,7 +96,7 @@
|
|
|
96
96
|
<view
|
|
97
97
|
class="jfb-base-order-list__body-order-item-content"
|
|
98
98
|
v-for="(Sitem, Sindex) in item.products"
|
|
99
|
-
:key="
|
|
99
|
+
:key="Sitem.key"
|
|
100
100
|
v-if="(item['isOpen'] === false && Sindex < showLen) || item['isOpen']">
|
|
101
101
|
<image
|
|
102
102
|
:src="Sitem.product_thumb"
|
|
@@ -175,7 +175,7 @@
|
|
|
175
175
|
class="jfb-base-order-list__body-order-item-pay"
|
|
176
176
|
v-if="item.buttons.length"
|
|
177
177
|
>
|
|
178
|
-
<view v-for="(btn,index) in item.buttons" :key="btn.
|
|
178
|
+
<view v-for="(btn,index) in item.buttons" :key="btn.key">
|
|
179
179
|
<xd-button
|
|
180
180
|
:type="getBtnType(btn.action)"
|
|
181
181
|
size="mini"
|
|
@@ -457,12 +457,17 @@ export default {
|
|
|
457
457
|
console.log(res.list, "list");
|
|
458
458
|
let list = res.list.map((item) => {
|
|
459
459
|
item["isOpen"] = false;
|
|
460
|
-
item.products = item.products.map((prod) => {
|
|
460
|
+
item.products = item.products.map((prod, i) => {
|
|
461
|
+
prod['key'] = prod.product_id + i;
|
|
461
462
|
prod["product_thumb"] = prod.product_thumb
|
|
462
463
|
? getServiceUrl(prod.product_thumb)
|
|
463
464
|
: "";
|
|
464
465
|
return prod;
|
|
465
466
|
});
|
|
467
|
+
item.buttons = item.buttons.map((btn, i) => {
|
|
468
|
+
btn["key"] = btn.action + i;
|
|
469
|
+
return btn;
|
|
470
|
+
})
|
|
466
471
|
item["created_time_text"] = this.$xdUniHelper.getDate(
|
|
467
472
|
item["created_time"] * 1000
|
|
468
473
|
).fullTime;
|