@pisell/pisellos 0.0.343 → 0.0.345
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.
|
@@ -2690,41 +2690,35 @@ export var BookingByStepImpl = /*#__PURE__*/function (_BaseModule) {
|
|
|
2690
2690
|
|
|
2691
2691
|
// 与其他资源的时间段求交集
|
|
2692
2692
|
var _loop2 = function _loop2() {
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
|
|
2701
|
-
|
|
2702
|
-
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
|
|
2709
|
-
});
|
|
2693
|
+
var currentResourceSlots = allTimeSlots[i];
|
|
2694
|
+
var intersections = [];
|
|
2695
|
+
|
|
2696
|
+
// 计算当前公共时间段与下一个资源时间段的交集
|
|
2697
|
+
commonSlots.forEach(function (commonSlot) {
|
|
2698
|
+
currentResourceSlots.forEach(function (currentSlot) {
|
|
2699
|
+
var overlapStart = commonSlot.start.isAfter(currentSlot.start) ? commonSlot.start : currentSlot.start;
|
|
2700
|
+
var overlapEnd = commonSlot.end.isBefore(currentSlot.end) ? commonSlot.end : currentSlot.end;
|
|
2701
|
+
|
|
2702
|
+
// 如果有重叠时间且重叠时间大于0
|
|
2703
|
+
if (overlapStart.isBefore(overlapEnd)) {
|
|
2704
|
+
intersections.push({
|
|
2705
|
+
start: overlapStart,
|
|
2706
|
+
end: overlapEnd
|
|
2707
|
+
});
|
|
2708
|
+
}
|
|
2710
2709
|
});
|
|
2711
|
-
|
|
2712
|
-
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
|
|
2721
|
-
};
|
|
2722
|
-
}
|
|
2723
|
-
},
|
|
2724
|
-
_ret2;
|
|
2710
|
+
});
|
|
2711
|
+
if (intersections.length === 0) {
|
|
2712
|
+
console.log("\u8D44\u6E90".concat(i, "\u4E0E\u5F53\u524D\u516C\u5171\u65F6\u95F4\u6BB5\u65E0\u4EA4\u96C6\uFF0C\u8DF3\u8FC7\u8BE5\u8D44\u6E90"));
|
|
2713
|
+
return 1; // continue
|
|
2714
|
+
}
|
|
2715
|
+
commonSlots = intersections;
|
|
2716
|
+
console.log("\u4E0E\u8D44\u6E90".concat(i, "\u6C42\u4EA4\u96C6\u540E\u7684\u516C\u5171\u65F6\u95F4\u6BB5:"), commonSlots.map(function (slot) {
|
|
2717
|
+
return "".concat(slot.start.format('HH:mm'), "-").concat(slot.end.format('HH:mm'));
|
|
2718
|
+
}));
|
|
2719
|
+
};
|
|
2725
2720
|
for (var i = 1; i < allTimeSlots.length; i++) {
|
|
2726
|
-
|
|
2727
|
-
if (_ret2) return _ret2.v;
|
|
2721
|
+
if (_loop2()) continue;
|
|
2728
2722
|
}
|
|
2729
2723
|
|
|
2730
2724
|
// 格式化返回结果
|
|
@@ -2973,10 +2967,10 @@ export var BookingByStepImpl = /*#__PURE__*/function (_BaseModule) {
|
|
|
2973
2967
|
}
|
|
2974
2968
|
});
|
|
2975
2969
|
},
|
|
2976
|
-
|
|
2970
|
+
_ret2;
|
|
2977
2971
|
for (var _i = 0, _Object$entries = Object.entries(itemsByResourceType); _i < _Object$entries.length; _i++) {
|
|
2978
|
-
|
|
2979
|
-
if (
|
|
2972
|
+
_ret2 = _loop3();
|
|
2973
|
+
if (_ret2) return _ret2.v;
|
|
2980
2974
|
}
|
|
2981
2975
|
|
|
2982
2976
|
// 如果有容量问题,找出限制最严格的资源类型,返回其总容量
|
|
@@ -3073,11 +3067,11 @@ export var BookingByStepImpl = /*#__PURE__*/function (_BaseModule) {
|
|
|
3073
3067
|
};
|
|
3074
3068
|
}
|
|
3075
3069
|
},
|
|
3076
|
-
|
|
3070
|
+
_ret3;
|
|
3077
3071
|
for (var _i2 = 0, _Object$entries2 = Object.entries(cartItemsByTimeSlot); _i2 < _Object$entries2.length; _i2++) {
|
|
3078
|
-
|
|
3079
|
-
if (
|
|
3080
|
-
if (
|
|
3072
|
+
_ret3 = _loop4();
|
|
3073
|
+
if (_ret3 === 0) continue;
|
|
3074
|
+
if (_ret3) return _ret3.v;
|
|
3081
3075
|
}
|
|
3082
3076
|
|
|
3083
3077
|
// 全部通过检测,返回成功和最小可用数量
|
|
@@ -3404,10 +3398,10 @@ export var BookingByStepImpl = /*#__PURE__*/function (_BaseModule) {
|
|
|
3404
3398
|
}
|
|
3405
3399
|
});
|
|
3406
3400
|
},
|
|
3407
|
-
|
|
3401
|
+
_ret4;
|
|
3408
3402
|
for (var _i3 = 0, _Object$entries3 = Object.entries(itemsByResourceType); _i3 < _Object$entries3.length; _i3++) {
|
|
3409
|
-
|
|
3410
|
-
if (
|
|
3403
|
+
_ret4 = _loop5();
|
|
3404
|
+
if (_ret4) return _ret4.v;
|
|
3411
3405
|
}
|
|
3412
3406
|
|
|
3413
3407
|
// 如果有容量问题,找出限制最严格的资源类型,返回其总容量
|
|
@@ -3504,11 +3498,11 @@ export var BookingByStepImpl = /*#__PURE__*/function (_BaseModule) {
|
|
|
3504
3498
|
};
|
|
3505
3499
|
}
|
|
3506
3500
|
},
|
|
3507
|
-
|
|
3501
|
+
_ret5;
|
|
3508
3502
|
for (var _i4 = 0, _Object$entries4 = Object.entries(cartItemsByTimeSlot); _i4 < _Object$entries4.length; _i4++) {
|
|
3509
|
-
|
|
3510
|
-
if (
|
|
3511
|
-
if (
|
|
3503
|
+
_ret5 = _loop6();
|
|
3504
|
+
if (_ret5 === 0) continue;
|
|
3505
|
+
if (_ret5) return _ret5.v;
|
|
3512
3506
|
}
|
|
3513
3507
|
|
|
3514
3508
|
// 全部通过检测,返回成功和最小可用数量
|
|
@@ -52,8 +52,8 @@ var onlineStoreConfig = {
|
|
|
52
52
|
method: 'POST',
|
|
53
53
|
transformParams: function transformParams(params) {
|
|
54
54
|
return {
|
|
55
|
-
phone: params.phone,
|
|
56
|
-
country_calling_code: params.country_calling_code
|
|
55
|
+
phone: String(params.phone),
|
|
56
|
+
country_calling_code: String(params.country_calling_code)
|
|
57
57
|
};
|
|
58
58
|
}
|
|
59
59
|
},
|
|
@@ -105,10 +105,10 @@ var onlineStoreConfig = {
|
|
|
105
105
|
method: 'POST',
|
|
106
106
|
transformParams: function transformParams(params) {
|
|
107
107
|
return {
|
|
108
|
-
phone: params.phone,
|
|
108
|
+
phone: String(params.phone),
|
|
109
109
|
password: params.password,
|
|
110
110
|
code: params.code,
|
|
111
|
-
country_calling_code: params.country_calling_code
|
|
111
|
+
country_calling_code: String(params.country_calling_code)
|
|
112
112
|
};
|
|
113
113
|
}
|
|
114
114
|
},
|
|
@@ -135,8 +135,8 @@ var onlineStoreConfig = {
|
|
|
135
135
|
method: 'POST',
|
|
136
136
|
transformParams: function transformParams(params) {
|
|
137
137
|
return {
|
|
138
|
-
phone: params.phone,
|
|
139
|
-
country_calling_code: params.country_calling_code
|
|
138
|
+
phone: String(params.phone),
|
|
139
|
+
country_calling_code: String(params.country_calling_code)
|
|
140
140
|
};
|
|
141
141
|
}
|
|
142
142
|
},
|
|
@@ -145,8 +145,8 @@ var onlineStoreConfig = {
|
|
|
145
145
|
method: 'POST',
|
|
146
146
|
transformParams: function transformParams(params) {
|
|
147
147
|
return {
|
|
148
|
-
phone: params.phone,
|
|
149
|
-
country_calling_code: params.country_calling_code,
|
|
148
|
+
phone: String(params.phone),
|
|
149
|
+
country_calling_code: String(params.country_calling_code),
|
|
150
150
|
code: params.code
|
|
151
151
|
};
|
|
152
152
|
}
|
|
@@ -155,7 +155,9 @@ var onlineStoreConfig = {
|
|
|
155
155
|
url: '/auth/guest/login',
|
|
156
156
|
method: 'POST',
|
|
157
157
|
transformParams: function transformParams(params) {
|
|
158
|
-
return
|
|
158
|
+
return {
|
|
159
|
+
login_channel: params.login_channel
|
|
160
|
+
};
|
|
159
161
|
}
|
|
160
162
|
},
|
|
161
163
|
checkEmailExists: {
|
|
@@ -164,7 +166,6 @@ var onlineStoreConfig = {
|
|
|
164
166
|
transformParams: function transformParams(params) {
|
|
165
167
|
return {
|
|
166
168
|
email: params.email,
|
|
167
|
-
shop_id: params.shop_id,
|
|
168
169
|
sales_channel: 'online_store'
|
|
169
170
|
};
|
|
170
171
|
}
|
|
@@ -175,7 +176,6 @@ var onlineStoreConfig = {
|
|
|
175
176
|
transformParams: function transformParams(params) {
|
|
176
177
|
return {
|
|
177
178
|
email: params.email,
|
|
178
|
-
shop_id: params.shop_id,
|
|
179
179
|
code: params.code
|
|
180
180
|
};
|
|
181
181
|
}
|
|
@@ -185,10 +185,9 @@ var onlineStoreConfig = {
|
|
|
185
185
|
method: 'GET',
|
|
186
186
|
transformParams: function transformParams(params) {
|
|
187
187
|
return {
|
|
188
|
-
phone: params.phone,
|
|
189
|
-
shop_id: params.shop_id,
|
|
188
|
+
phone: String(params.phone),
|
|
190
189
|
code: params.code,
|
|
191
|
-
country_calling_code: params.country_calling_code
|
|
190
|
+
country_calling_code: String(params.country_calling_code)
|
|
192
191
|
};
|
|
193
192
|
}
|
|
194
193
|
},
|
|
@@ -197,9 +196,9 @@ var onlineStoreConfig = {
|
|
|
197
196
|
method: 'POST',
|
|
198
197
|
transformParams: function transformParams(params) {
|
|
199
198
|
return {
|
|
200
|
-
phone: params.phone,
|
|
199
|
+
phone: String(params.phone),
|
|
201
200
|
password: params.password,
|
|
202
|
-
country_calling_code: params.country_calling_code
|
|
201
|
+
country_calling_code: String(params.country_calling_code)
|
|
203
202
|
};
|
|
204
203
|
}
|
|
205
204
|
},
|
|
@@ -217,8 +216,8 @@ var onlineStoreConfig = {
|
|
|
217
216
|
method: 'POST',
|
|
218
217
|
transformParams: function transformParams(params) {
|
|
219
218
|
return {
|
|
220
|
-
phone: params.phone,
|
|
221
|
-
country_calling_code: params.country_calling_code
|
|
219
|
+
phone: String(params.phone),
|
|
220
|
+
country_calling_code: String(params.country_calling_code)
|
|
222
221
|
};
|
|
223
222
|
}
|
|
224
223
|
},
|
|
@@ -266,10 +265,10 @@ var onlineStoreConfig = {
|
|
|
266
265
|
method: 'POST',
|
|
267
266
|
transformParams: function transformParams(params) {
|
|
268
267
|
return {
|
|
269
|
-
phone: params.phone,
|
|
268
|
+
phone: String(params.phone),
|
|
270
269
|
password: params.password,
|
|
271
270
|
code: params.code,
|
|
272
|
-
country_calling_code: params.country_calling_code
|
|
271
|
+
country_calling_code: String(params.country_calling_code)
|
|
273
272
|
};
|
|
274
273
|
}
|
|
275
274
|
},
|
|
@@ -380,8 +379,8 @@ var defaultConfig = {
|
|
|
380
379
|
method: 'POST',
|
|
381
380
|
transformParams: function transformParams(params) {
|
|
382
381
|
return {
|
|
383
|
-
phone: params.phone,
|
|
384
|
-
country_calling_code: params.country_calling_code
|
|
382
|
+
phone: String(params.phone),
|
|
383
|
+
country_calling_code: String(params.country_calling_code)
|
|
385
384
|
};
|
|
386
385
|
}
|
|
387
386
|
},
|
|
@@ -429,10 +428,10 @@ var defaultConfig = {
|
|
|
429
428
|
method: 'POST',
|
|
430
429
|
transformParams: function transformParams(params) {
|
|
431
430
|
return {
|
|
432
|
-
phone: params.phone,
|
|
431
|
+
phone: String(params.phone),
|
|
433
432
|
password: params.password,
|
|
434
433
|
code: params.code,
|
|
435
|
-
country_calling_code: params.country_calling_code
|
|
434
|
+
country_calling_code: String(params.country_calling_code)
|
|
436
435
|
};
|
|
437
436
|
}
|
|
438
437
|
},
|
|
@@ -459,8 +458,8 @@ var defaultConfig = {
|
|
|
459
458
|
method: 'POST',
|
|
460
459
|
transformParams: function transformParams(params) {
|
|
461
460
|
return {
|
|
462
|
-
phone: params.phone,
|
|
463
|
-
country_calling_code: params.country_calling_code
|
|
461
|
+
phone: String(params.phone),
|
|
462
|
+
country_calling_code: String(params.country_calling_code)
|
|
464
463
|
};
|
|
465
464
|
}
|
|
466
465
|
},
|
|
@@ -469,8 +468,8 @@ var defaultConfig = {
|
|
|
469
468
|
method: 'POST',
|
|
470
469
|
transformParams: function transformParams(params) {
|
|
471
470
|
return {
|
|
472
|
-
phone: params.phone,
|
|
473
|
-
country_calling_code: params.country_calling_code,
|
|
471
|
+
phone: String(params.phone),
|
|
472
|
+
country_calling_code: String(params.country_calling_code),
|
|
474
473
|
code: params.code
|
|
475
474
|
};
|
|
476
475
|
}
|
|
@@ -489,8 +488,7 @@ var defaultConfig = {
|
|
|
489
488
|
method: 'GET',
|
|
490
489
|
transformParams: function transformParams(params) {
|
|
491
490
|
return {
|
|
492
|
-
email: params.email
|
|
493
|
-
shop_id: params.shop_id
|
|
491
|
+
email: params.email
|
|
494
492
|
};
|
|
495
493
|
}
|
|
496
494
|
},
|
|
@@ -500,7 +498,6 @@ var defaultConfig = {
|
|
|
500
498
|
transformParams: function transformParams(params) {
|
|
501
499
|
return {
|
|
502
500
|
email: params.email,
|
|
503
|
-
shop_id: params.shop_id,
|
|
504
501
|
code: params.code
|
|
505
502
|
};
|
|
506
503
|
}
|
|
@@ -510,10 +507,9 @@ var defaultConfig = {
|
|
|
510
507
|
method: 'GET',
|
|
511
508
|
transformParams: function transformParams(params) {
|
|
512
509
|
return {
|
|
513
|
-
phone: params.phone,
|
|
514
|
-
shop_id: params.shop_id,
|
|
510
|
+
phone: String(params.phone),
|
|
515
511
|
code: params.code,
|
|
516
|
-
country_calling_code: params.country_calling_code
|
|
512
|
+
country_calling_code: String(params.country_calling_code)
|
|
517
513
|
};
|
|
518
514
|
}
|
|
519
515
|
},
|
|
@@ -522,9 +518,9 @@ var defaultConfig = {
|
|
|
522
518
|
method: 'POST',
|
|
523
519
|
transformParams: function transformParams(params) {
|
|
524
520
|
return {
|
|
525
|
-
phone: params.phone,
|
|
521
|
+
phone: String(params.phone),
|
|
526
522
|
password: params.password,
|
|
527
|
-
country_calling_code: params.country_calling_code
|
|
523
|
+
country_calling_code: String(params.country_calling_code)
|
|
528
524
|
};
|
|
529
525
|
}
|
|
530
526
|
},
|
|
@@ -542,8 +538,8 @@ var defaultConfig = {
|
|
|
542
538
|
method: 'POST',
|
|
543
539
|
transformParams: function transformParams(params) {
|
|
544
540
|
return {
|
|
545
|
-
phone: params.phone,
|
|
546
|
-
country_calling_code: params.country_calling_code
|
|
541
|
+
phone: String(params.phone),
|
|
542
|
+
country_calling_code: String(params.country_calling_code)
|
|
547
543
|
};
|
|
548
544
|
}
|
|
549
545
|
},
|
|
@@ -591,10 +587,10 @@ var defaultConfig = {
|
|
|
591
587
|
method: 'POST',
|
|
592
588
|
transformParams: function transformParams(params) {
|
|
593
589
|
return {
|
|
594
|
-
phone: params.phone,
|
|
590
|
+
phone: String(params.phone),
|
|
595
591
|
password: params.password,
|
|
596
592
|
code: params.code,
|
|
597
|
-
country_calling_code: params.country_calling_code
|
|
593
|
+
country_calling_code: String(params.country_calling_code)
|
|
598
594
|
};
|
|
599
595
|
}
|
|
600
596
|
},
|
|
@@ -1908,12 +1908,12 @@ var BookingByStepImpl = class extends import_BaseModule.BaseModule {
|
|
|
1908
1908
|
}
|
|
1909
1909
|
});
|
|
1910
1910
|
});
|
|
1911
|
+
if (intersections.length === 0) {
|
|
1912
|
+
console.log(`资源${i}与当前公共时间段无交集,跳过该资源`);
|
|
1913
|
+
continue;
|
|
1914
|
+
}
|
|
1911
1915
|
commonSlots = intersections;
|
|
1912
1916
|
console.log(`与资源${i}求交集后的公共时间段:`, commonSlots.map((slot) => `${slot.start.format("HH:mm")}-${slot.end.format("HH:mm")}`));
|
|
1913
|
-
if (commonSlots.length === 0) {
|
|
1914
|
-
console.log("没有找到公共时间段");
|
|
1915
|
-
return [];
|
|
1916
|
-
}
|
|
1917
1917
|
}
|
|
1918
1918
|
const result = commonSlots.map((slot) => ({
|
|
1919
1919
|
startTime: slot.start.format("HH:mm"),
|
|
@@ -46,8 +46,8 @@ var onlineStoreConfig = {
|
|
|
46
46
|
url: "/auth/mobile/sms-register",
|
|
47
47
|
method: "POST",
|
|
48
48
|
transformParams: (params) => ({
|
|
49
|
-
phone: params.phone,
|
|
50
|
-
country_calling_code: params.country_calling_code
|
|
49
|
+
phone: String(params.phone),
|
|
50
|
+
country_calling_code: String(params.country_calling_code)
|
|
51
51
|
})
|
|
52
52
|
},
|
|
53
53
|
sendEmailRegisterLink: {
|
|
@@ -89,10 +89,10 @@ var onlineStoreConfig = {
|
|
|
89
89
|
url: "/auth/mobile/register",
|
|
90
90
|
method: "POST",
|
|
91
91
|
transformParams: (params) => ({
|
|
92
|
-
phone: params.phone,
|
|
92
|
+
phone: String(params.phone),
|
|
93
93
|
password: params.password,
|
|
94
94
|
code: params.code,
|
|
95
|
-
country_calling_code: params.country_calling_code
|
|
95
|
+
country_calling_code: String(params.country_calling_code)
|
|
96
96
|
})
|
|
97
97
|
},
|
|
98
98
|
resendEmailRegisterLink: {
|
|
@@ -113,30 +113,31 @@ var onlineStoreConfig = {
|
|
|
113
113
|
url: "/auth/send-login-msg",
|
|
114
114
|
method: "POST",
|
|
115
115
|
transformParams: (params) => ({
|
|
116
|
-
phone: params.phone,
|
|
117
|
-
country_calling_code: params.country_calling_code
|
|
116
|
+
phone: String(params.phone),
|
|
117
|
+
country_calling_code: String(params.country_calling_code)
|
|
118
118
|
})
|
|
119
119
|
},
|
|
120
120
|
phoneCodeLogin: {
|
|
121
121
|
url: "/auth/mobile-login",
|
|
122
122
|
method: "POST",
|
|
123
123
|
transformParams: (params) => ({
|
|
124
|
-
phone: params.phone,
|
|
125
|
-
country_calling_code: params.country_calling_code,
|
|
124
|
+
phone: String(params.phone),
|
|
125
|
+
country_calling_code: String(params.country_calling_code),
|
|
126
126
|
code: params.code
|
|
127
127
|
})
|
|
128
128
|
},
|
|
129
129
|
guestLogin: {
|
|
130
130
|
url: "/auth/guest/login",
|
|
131
131
|
method: "POST",
|
|
132
|
-
transformParams: (params) =>
|
|
132
|
+
transformParams: (params) => ({
|
|
133
|
+
login_channel: params.login_channel
|
|
134
|
+
})
|
|
133
135
|
},
|
|
134
136
|
checkEmailExists: {
|
|
135
137
|
url: "/auth/email/check-email",
|
|
136
138
|
method: "GET",
|
|
137
139
|
transformParams: (params) => ({
|
|
138
140
|
email: params.email,
|
|
139
|
-
shop_id: params.shop_id,
|
|
140
141
|
sales_channel: "online_store"
|
|
141
142
|
})
|
|
142
143
|
},
|
|
@@ -145,7 +146,6 @@ var onlineStoreConfig = {
|
|
|
145
146
|
method: "GET",
|
|
146
147
|
transformParams: (params) => ({
|
|
147
148
|
email: params.email,
|
|
148
|
-
shop_id: params.shop_id,
|
|
149
149
|
code: params.code
|
|
150
150
|
})
|
|
151
151
|
},
|
|
@@ -153,19 +153,18 @@ var onlineStoreConfig = {
|
|
|
153
153
|
url: "/auth/mobile/check-mobile-code",
|
|
154
154
|
method: "GET",
|
|
155
155
|
transformParams: (params) => ({
|
|
156
|
-
phone: params.phone,
|
|
157
|
-
shop_id: params.shop_id,
|
|
156
|
+
phone: String(params.phone),
|
|
158
157
|
code: params.code,
|
|
159
|
-
country_calling_code: params.country_calling_code
|
|
158
|
+
country_calling_code: String(params.country_calling_code)
|
|
160
159
|
})
|
|
161
160
|
},
|
|
162
161
|
phonePasswordLogin: {
|
|
163
162
|
url: "/auth/mobile/login",
|
|
164
163
|
method: "POST",
|
|
165
164
|
transformParams: (params) => ({
|
|
166
|
-
phone: params.phone,
|
|
165
|
+
phone: String(params.phone),
|
|
167
166
|
password: params.password,
|
|
168
|
-
country_calling_code: params.country_calling_code
|
|
167
|
+
country_calling_code: String(params.country_calling_code)
|
|
169
168
|
})
|
|
170
169
|
},
|
|
171
170
|
sendPasswordResetEmail: {
|
|
@@ -179,8 +178,8 @@ var onlineStoreConfig = {
|
|
|
179
178
|
url: "/auth/mobile/sms-forget",
|
|
180
179
|
method: "POST",
|
|
181
180
|
transformParams: (params) => ({
|
|
182
|
-
phone: params.phone,
|
|
183
|
-
country_calling_code: params.country_calling_code
|
|
181
|
+
phone: String(params.phone),
|
|
182
|
+
country_calling_code: String(params.country_calling_code)
|
|
184
183
|
})
|
|
185
184
|
},
|
|
186
185
|
sendResetPasswordLink: {
|
|
@@ -218,10 +217,10 @@ var onlineStoreConfig = {
|
|
|
218
217
|
url: "/auth/mobile/reset-password",
|
|
219
218
|
method: "POST",
|
|
220
219
|
transformParams: (params) => ({
|
|
221
|
-
phone: params.phone,
|
|
220
|
+
phone: String(params.phone),
|
|
222
221
|
password: params.password,
|
|
223
222
|
code: params.code,
|
|
224
|
-
country_calling_code: params.country_calling_code
|
|
223
|
+
country_calling_code: String(params.country_calling_code)
|
|
225
224
|
})
|
|
226
225
|
},
|
|
227
226
|
verifyCode: {
|
|
@@ -302,8 +301,8 @@ var defaultConfig = {
|
|
|
302
301
|
url: "/auth/send-sms-register",
|
|
303
302
|
method: "POST",
|
|
304
303
|
transformParams: (params) => ({
|
|
305
|
-
phone: params.phone,
|
|
306
|
-
country_calling_code: params.country_calling_code
|
|
304
|
+
phone: String(params.phone),
|
|
305
|
+
country_calling_code: String(params.country_calling_code)
|
|
307
306
|
})
|
|
308
307
|
},
|
|
309
308
|
sendEmailRegisterLink: {
|
|
@@ -341,10 +340,10 @@ var defaultConfig = {
|
|
|
341
340
|
url: "/auth/mobile/register",
|
|
342
341
|
method: "POST",
|
|
343
342
|
transformParams: (params) => ({
|
|
344
|
-
phone: params.phone,
|
|
343
|
+
phone: String(params.phone),
|
|
345
344
|
password: params.password,
|
|
346
345
|
code: params.code,
|
|
347
|
-
country_calling_code: params.country_calling_code
|
|
346
|
+
country_calling_code: String(params.country_calling_code)
|
|
348
347
|
})
|
|
349
348
|
},
|
|
350
349
|
resendEmailRegisterLink: {
|
|
@@ -365,16 +364,16 @@ var defaultConfig = {
|
|
|
365
364
|
url: "/auth/send-sms-login-code",
|
|
366
365
|
method: "POST",
|
|
367
366
|
transformParams: (params) => ({
|
|
368
|
-
phone: params.phone,
|
|
369
|
-
country_calling_code: params.country_calling_code
|
|
367
|
+
phone: String(params.phone),
|
|
368
|
+
country_calling_code: String(params.country_calling_code)
|
|
370
369
|
})
|
|
371
370
|
},
|
|
372
371
|
phoneCodeLogin: {
|
|
373
372
|
url: "/auth/phone-code-login",
|
|
374
373
|
method: "POST",
|
|
375
374
|
transformParams: (params) => ({
|
|
376
|
-
phone: params.phone,
|
|
377
|
-
country_calling_code: params.country_calling_code,
|
|
375
|
+
phone: String(params.phone),
|
|
376
|
+
country_calling_code: String(params.country_calling_code),
|
|
378
377
|
code: params.code
|
|
379
378
|
})
|
|
380
379
|
},
|
|
@@ -389,8 +388,7 @@ var defaultConfig = {
|
|
|
389
388
|
url: "/auth/check-email-exists",
|
|
390
389
|
method: "GET",
|
|
391
390
|
transformParams: (params) => ({
|
|
392
|
-
email: params.email
|
|
393
|
-
shop_id: params.shop_id
|
|
391
|
+
email: params.email
|
|
394
392
|
})
|
|
395
393
|
},
|
|
396
394
|
checkEmailCode: {
|
|
@@ -398,7 +396,6 @@ var defaultConfig = {
|
|
|
398
396
|
method: "GET",
|
|
399
397
|
transformParams: (params) => ({
|
|
400
398
|
email: params.email,
|
|
401
|
-
shop_id: params.shop_id,
|
|
402
399
|
code: params.code
|
|
403
400
|
})
|
|
404
401
|
},
|
|
@@ -406,19 +403,18 @@ var defaultConfig = {
|
|
|
406
403
|
url: "/auth/check-mobile-code",
|
|
407
404
|
method: "GET",
|
|
408
405
|
transformParams: (params) => ({
|
|
409
|
-
phone: params.phone,
|
|
410
|
-
shop_id: params.shop_id,
|
|
406
|
+
phone: String(params.phone),
|
|
411
407
|
code: params.code,
|
|
412
|
-
country_calling_code: params.country_calling_code
|
|
408
|
+
country_calling_code: String(params.country_calling_code)
|
|
413
409
|
})
|
|
414
410
|
},
|
|
415
411
|
phonePasswordLogin: {
|
|
416
412
|
url: "/auth/mobile-password-login",
|
|
417
413
|
method: "POST",
|
|
418
414
|
transformParams: (params) => ({
|
|
419
|
-
phone: params.phone,
|
|
415
|
+
phone: String(params.phone),
|
|
420
416
|
password: params.password,
|
|
421
|
-
country_calling_code: params.country_calling_code
|
|
417
|
+
country_calling_code: String(params.country_calling_code)
|
|
422
418
|
})
|
|
423
419
|
},
|
|
424
420
|
sendPasswordResetEmail: {
|
|
@@ -432,8 +428,8 @@ var defaultConfig = {
|
|
|
432
428
|
url: "/auth/send-password-reset-sms",
|
|
433
429
|
method: "POST",
|
|
434
430
|
transformParams: (params) => ({
|
|
435
|
-
phone: params.phone,
|
|
436
|
-
country_calling_code: params.country_calling_code
|
|
431
|
+
phone: String(params.phone),
|
|
432
|
+
country_calling_code: String(params.country_calling_code)
|
|
437
433
|
})
|
|
438
434
|
},
|
|
439
435
|
sendResetPasswordLink: {
|
|
@@ -471,10 +467,10 @@ var defaultConfig = {
|
|
|
471
467
|
url: "/auth/reset-password-phone",
|
|
472
468
|
method: "POST",
|
|
473
469
|
transformParams: (params) => ({
|
|
474
|
-
phone: params.phone,
|
|
470
|
+
phone: String(params.phone),
|
|
475
471
|
password: params.password,
|
|
476
472
|
code: params.code,
|
|
477
|
-
country_calling_code: params.country_calling_code
|
|
473
|
+
country_calling_code: String(params.country_calling_code)
|
|
478
474
|
})
|
|
479
475
|
},
|
|
480
476
|
verifyCode: {
|