ts-glitter 21.5.3 → 21.5.4
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/lowcode/Entry.js +1 -1
- package/lowcode/Entry.ts +1 -1
- package/lowcode/cms-plugin/account-info.js +79 -67
- package/lowcode/cms-plugin/account-info.ts +327 -311
- package/lowcode/cms-plugin/information/information-module.ts +3 -1
- package/lowcode/cms-plugin/list-header-option.js +1 -0
- package/lowcode/cms-plugin/list-header-option.ts +1 -0
- package/lowcode/cms-plugin/shopping-information.js +468 -0
- package/lowcode/cms-plugin/shopping-information.ts +557 -0
- package/lowcode/cms-plugin/shopping-market-shopee.js +283 -231
- package/lowcode/cms-plugin/shopping-market-shopee.ts +401 -361
- package/lowcode/cms-plugin/shopping-order-manager.js +16 -4
- package/lowcode/cms-plugin/shopping-order-manager.ts +18 -3
- package/lowcode/glitter-base/global/language.js +4 -1
- package/lowcode/glitter-base/global/language.ts +4 -2
- package/lowcode/glitter-base/route/shopee.js +48 -11
- package/lowcode/glitter-base/route/shopee.ts +119 -80
- package/lowcode/glitterBundle/plugins/html-render.js +121 -90
- package/lowcode/glitterBundle/plugins/html-render.ts +367 -318
- package/lowcode/modules/image-library.js +2 -3
- package/lowcode/modules/image-library.ts +21 -7
- package/lowcode/public-components/checkout/index.js +90 -41
- package/lowcode/public-components/checkout/index.ts +101 -49
- package/lowcode/public-components/footer/footer-initial.js +11 -2
- package/lowcode/public-components/footer/footer-initial.ts +29 -18
- package/lowcode/public-components/headers/header-class.js +47 -35
- package/lowcode/public-components/headers/header-class.ts +54 -38
- package/lowcode/public-components/layout-plugin/social-links-01.js +122 -3
- package/lowcode/public-components/layout-plugin/social-links-01.ts +135 -10
- package/lowcode/public-components/product/pd-card-01.js +23 -14
- package/lowcode/public-components/product/pd-card-01.ts +25 -14
- package/lowcode/public-components/product/pd-card-02.js +23 -16
- package/lowcode/public-components/product/pd-card-02.ts +25 -16
- package/lowcode/public-components/product/pd-card-03.js +25 -16
- package/lowcode/public-components/product/pd-card-03.ts +27 -16
- package/lowcode/public-components/terms-related/index.js +13 -2
- package/lowcode/public-components/terms-related/index.ts +15 -2
- package/lowcode/public-components/user-manager/um-class.js +490 -501
- package/lowcode/public-components/user-manager/um-class.ts +872 -882
- package/lowcode/public-components/user-manager/um-info.js +41 -40
- package/lowcode/public-components/user-manager/um-info.ts +54 -56
- package/lowcode/public-components/user-manager/um-login.js +10 -13
- package/lowcode/public-components/user-manager/um-login.ts +15 -23
- package/lowcode/public-components/user-manager/um-orderlist.js +60 -51
- package/lowcode/public-components/user-manager/um-orderlist.ts +289 -275
- package/lowcode/public-components/user-manager/um-rebate.js +104 -82
- package/lowcode/public-components/user-manager/um-rebate.ts +294 -267
- package/lowcode/public-components/user-manager/um-receive.js +582 -0
- package/lowcode/public-components/user-manager/um-receive.ts +599 -0
- package/lowcode/public-components/user-manager/um-wishlist.js +72 -68
- package/lowcode/public-components/user-manager/um-wishlist.ts +240 -230
- package/package.json +1 -1
- package/src/api-public/controllers/shopee.js +17 -0
- package/src/api-public/controllers/shopee.js.map +1 -1
- package/src/api-public/controllers/shopee.ts +32 -0
- package/src/api-public/services/monitor.d.ts +1 -0
- package/src/api-public/services/post.js +17 -7
- package/src/api-public/services/post.js.map +1 -1
- package/src/api-public/services/rebate.js +2 -11
- package/src/api-public/services/rebate.js.map +1 -1
- package/src/api-public/services/rebate.ts +5 -12
- package/src/api-public/services/shopee.d.ts +23 -2
- package/src/api-public/services/shopee.js +230 -111
- package/src/api-public/services/shopee.js.map +1 -1
- package/src/api-public/services/shopee.ts +1012 -838
- package/src/api-public/services/user.js +2 -2
- package/src/api-public/services/user.js.map +1 -1
- package/src/api-public/services/user.ts +3 -3
- package/src/index.js +17 -7
- package/src/index.js.map +1 -1
- package/src/modules/tool.d.ts +4 -4
- package/src/modules/tool.js +2 -1
- package/src/modules/tool.js.map +1 -1
- package/src/services/backend-service.js +17 -7
- package/src/services/backend-service.js.map +1 -1
- package/src/services/template.d.ts +1 -1
- package/src/services/template.js +24 -18
- package/src/services/template.js.map +1 -1
- package/src/services/template.ts +34 -37
|
@@ -25,323 +25,339 @@ export class AccountInfo {
|
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
return html` <div
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
>
|
|
31
|
-
<li
|
|
32
|
-
class="breadcrumb-item "
|
|
33
|
-
style="margin-top: 0px;color:#292218;"
|
|
34
|
-
onclick="${gvc.event(() => {
|
|
35
|
-
gvc.glitter.href = '/index';
|
|
36
|
-
})}"
|
|
28
|
+
class="breadcrumb mb-0 d-flex align-items-center pt-4 pb-5 d-none d-lg-flex"
|
|
29
|
+
style="cursor:pointer; gap:10px;"
|
|
37
30
|
>
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
document.body.clientWidth
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
31
|
+
<li
|
|
32
|
+
class="breadcrumb-item "
|
|
33
|
+
style="margin-top: 0px;color:#292218;"
|
|
34
|
+
onclick="${gvc.event(() => {
|
|
35
|
+
gvc.glitter.href = '/index';
|
|
36
|
+
})}"
|
|
37
|
+
>
|
|
38
|
+
${Language.text('home_page')}
|
|
39
|
+
</li>
|
|
40
|
+
<i class="fa-solid fa-angle-right" aria-hidden="true"></i>
|
|
41
|
+
<li class="breadcrumb-item " style="margin-top: 0px;color:#292218;">
|
|
42
|
+
${Language.text('account_user_info')}
|
|
43
|
+
</li>
|
|
44
|
+
</div>
|
|
45
|
+
<div
|
|
46
|
+
class="d-flex flex-column-reverse flex-lg-row "
|
|
47
|
+
style="gap:${document.body.clientWidth > 800 ? 76 : 18}px;"
|
|
48
|
+
>
|
|
49
|
+
${(() => {
|
|
50
|
+
if (
|
|
51
|
+
['account_edit', 'recipient_info', 'order_list', 'voucher-list', 'rebate', 'wishlist'].includes(
|
|
52
|
+
gvc.glitter.getUrlParameter('page')
|
|
53
|
+
) &&
|
|
54
|
+
document.body.clientWidth < 800
|
|
55
|
+
) {
|
|
56
|
+
return ``;
|
|
57
|
+
} else {
|
|
58
|
+
return html` <div
|
|
59
|
+
class="d-flex flex-column align-items-start ${document.body.clientWidth > 800
|
|
60
|
+
? ``
|
|
61
|
+
: `border rounded-3 w-100 py-2 px-3`}"
|
|
62
|
+
style="min-width:190px;width:190px;gap:4px;"
|
|
63
|
+
>
|
|
64
|
+
${[
|
|
65
|
+
{
|
|
66
|
+
title: Language.text('account_user_info'),
|
|
67
|
+
event: gvc.event(() => {
|
|
68
|
+
gvc.glitter.href = '/account_userinfo';
|
|
69
|
+
}),
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
title: Language.text('member_info'),
|
|
73
|
+
event: gvc.event(() => {
|
|
74
|
+
gvc.glitter.href = '/account_edit';
|
|
75
|
+
}),
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
title: Language.text('recipient_info'),
|
|
79
|
+
event: gvc.event(() => {
|
|
80
|
+
gvc.glitter.href = '/recipient_info';
|
|
81
|
+
}),
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
title: Language.text('order_history'),
|
|
85
|
+
event: gvc.event(() => {
|
|
86
|
+
gvc.glitter.href = '/order_list';
|
|
87
|
+
}),
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
title: `${Language.text('my')}${glitter.share.rebateConfig.title || Language.text('shopping_credit')}`,
|
|
91
|
+
event: gvc.event(() => {
|
|
92
|
+
gvc.glitter.href = '/rebate';
|
|
93
|
+
}),
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
title: Language.text('my_coupons'),
|
|
97
|
+
event: gvc.event(() => {
|
|
98
|
+
gvc.glitter.href = '/voucher-list';
|
|
99
|
+
}),
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
title: Language.text('wishlist'),
|
|
103
|
+
event: gvc.event(() => {
|
|
104
|
+
gvc.glitter.href = '/wishlist';
|
|
105
|
+
}),
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
title: Language.text('reset_password'),
|
|
109
|
+
event: gvc.event(async () => {
|
|
110
|
+
const dialog = new ShareDialog(gvc.glitter);
|
|
111
|
+
dialog.dataLoading({ visible: true });
|
|
112
|
+
const userData: any = await UmClass.getUserData(gvc);
|
|
113
|
+
dialog.dataLoading({ visible: false });
|
|
114
|
+
UmClass.dialog({
|
|
115
|
+
gvc: gvc,
|
|
116
|
+
title: Language.text('reset_password_event'),
|
|
117
|
+
tag: '',
|
|
118
|
+
innerHTML: (gvc: GVC) => {
|
|
119
|
+
let update_vm = {
|
|
120
|
+
verify_code: '',
|
|
121
|
+
pwd: '',
|
|
122
|
+
};
|
|
123
|
+
let get_verify_timer = 0;
|
|
124
|
+
let repeat_pwd = '';
|
|
125
|
+
return [
|
|
126
|
+
html` <div class="tx_normal fw-normal mb-1">${Language.text('password')}</div>`,
|
|
127
|
+
html`<input
|
|
128
|
+
class="bgw-input"
|
|
129
|
+
type="password"
|
|
130
|
+
placeholder="${Language.text('please_enter_password')}"
|
|
131
|
+
oninput="${gvc.event(e => {
|
|
132
|
+
update_vm.pwd = e.value;
|
|
133
|
+
})}"
|
|
134
|
+
value="${update_vm.pwd}"
|
|
135
|
+
/>`,
|
|
136
|
+
html` <div class="tx_normal fw-normal mt-2 mb-1">
|
|
137
|
+
${Language.text('confirm_password')}
|
|
138
|
+
</div>`,
|
|
139
|
+
html`<input
|
|
140
|
+
class="bgw-input mb-2"
|
|
141
|
+
type="password"
|
|
142
|
+
placeholder="${Language.text('please_enter_password_again')}"
|
|
143
|
+
oninput="${gvc.event(e => {
|
|
144
|
+
repeat_pwd = e.value;
|
|
145
|
+
})}"
|
|
146
|
+
value="${repeat_pwd}"
|
|
147
|
+
/>`,
|
|
148
|
+
gvc.bindView(() => {
|
|
149
|
+
const id = gvc.glitter.getUUID();
|
|
150
|
+
return {
|
|
151
|
+
bind: id,
|
|
152
|
+
view: () => {
|
|
153
|
+
return html`${Language.text('reset_password_verification_code')}
|
|
154
|
+
${UmClass.style_components.blueNote(
|
|
155
|
+
get_verify_timer
|
|
156
|
+
? `${Language.text('verification_code_sent_to')}『${userData.userData.email}』`
|
|
157
|
+
: Language.text('get_verification_code'),
|
|
158
|
+
gvc.event(() => {
|
|
159
|
+
if (!get_verify_timer) {
|
|
160
|
+
const dialog = new ShareDialog(gvc.glitter);
|
|
161
|
+
dialog.dataLoading({ visible: true });
|
|
162
|
+
ApiUser.emailVerify(
|
|
163
|
+
userData.userData.email,
|
|
164
|
+
(window as any).appName
|
|
165
|
+
).then(async r => {
|
|
166
|
+
dialog.dataLoading({ visible: false });
|
|
167
|
+
get_verify_timer = 60;
|
|
168
|
+
gvc.notifyDataChange(id);
|
|
169
|
+
});
|
|
170
|
+
}
|
|
171
|
+
})
|
|
172
|
+
)}`;
|
|
173
|
+
},
|
|
174
|
+
divCreate: {
|
|
175
|
+
class: `d-flex flex-column`,
|
|
176
|
+
style: `gap:3px;`,
|
|
177
|
+
},
|
|
178
|
+
onCreate: () => {
|
|
179
|
+
if (get_verify_timer > 0) {
|
|
180
|
+
get_verify_timer--;
|
|
181
|
+
setTimeout(() => {
|
|
160
182
|
gvc.notifyDataChange(id);
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
)
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
}
|
|
178
|
-
},
|
|
179
|
-
};
|
|
180
|
-
}),
|
|
181
|
-
html`<input
|
|
182
|
-
class="bgw-input mt-2 mb-4"
|
|
183
|
-
type="text"
|
|
184
|
-
placeholder="${Language.text('please_enter_verification_code')}"
|
|
185
|
-
oninput="${gvc.event((e, event) => {
|
|
186
|
-
update_vm.verify_code = e.value;
|
|
187
|
-
})}"
|
|
188
|
-
value="${update_vm.verify_code}"
|
|
189
|
-
/>`,
|
|
190
|
-
html` <div class="d-flex align-items-center justify-content-end pt-2 border-top mx-n3">
|
|
191
|
-
<div
|
|
192
|
-
class="um-nav-btn um-nav-btn-active d-flex align-items-center justify-content-center"
|
|
193
|
-
style="cursor:pointer;"
|
|
194
|
-
type="button"
|
|
195
|
-
onclick="${gvc.event(() => {
|
|
196
|
-
if (update_vm.pwd.length < 8) {
|
|
197
|
-
dialog.errorMessage({ text: Language.text('password_min_length') });
|
|
198
|
-
return;
|
|
199
|
-
}
|
|
200
|
-
if (repeat_pwd !== update_vm.pwd) {
|
|
201
|
-
dialog.errorMessage({ text: Language.text('please_confirm_password_again') });
|
|
202
|
-
return;
|
|
203
|
-
}
|
|
204
|
-
dialog.dataLoading({ visible: true });
|
|
205
|
-
ApiUser.updateUserData({
|
|
206
|
-
userData: update_vm,
|
|
207
|
-
}).then(res => {
|
|
208
|
-
dialog.dataLoading({ visible: false });
|
|
209
|
-
if (!res.result && res.response.data.msg === 'email-verify-false') {
|
|
210
|
-
dialog.errorMessage({
|
|
211
|
-
text: Language.text('email_verification_code_incorrect'),
|
|
212
|
-
});
|
|
213
|
-
} else if (!res.result && res.response.data.msg === 'phone-verify-false') {
|
|
214
|
-
dialog.errorMessage({
|
|
215
|
-
text: Language.text('sms_verification_code_incorrect'),
|
|
216
|
-
});
|
|
217
|
-
} else if (!res.result && res.response.data.msg === 'phone-exists') {
|
|
218
|
-
dialog.errorMessage({ text: Language.text('phone_number_already_exists') });
|
|
219
|
-
} else if (!res.result && res.response.data.msg === 'email-exists') {
|
|
220
|
-
dialog.errorMessage({ text: Language.text('email_already_exists') });
|
|
221
|
-
} else if (!res.result) {
|
|
222
|
-
dialog.errorMessage({ text: Language.text('update_exception') });
|
|
223
|
-
} else {
|
|
224
|
-
dialog.successMessage({ text: Language.text('change_success') });
|
|
225
|
-
gvc.closeDialog();
|
|
226
|
-
}
|
|
227
|
-
});
|
|
228
|
-
})}"
|
|
183
|
+
}, 1000);
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
};
|
|
187
|
+
}),
|
|
188
|
+
html`<input
|
|
189
|
+
class="bgw-input mt-2 mb-4"
|
|
190
|
+
type="text"
|
|
191
|
+
placeholder="${Language.text('please_enter_verification_code')}"
|
|
192
|
+
oninput="${gvc.event((e, event) => {
|
|
193
|
+
update_vm.verify_code = e.value;
|
|
194
|
+
})}"
|
|
195
|
+
value="${update_vm.verify_code}"
|
|
196
|
+
/>`,
|
|
197
|
+
html` <div
|
|
198
|
+
class="d-flex align-items-center justify-content-end pt-2 border-top mx-n3"
|
|
229
199
|
>
|
|
230
|
-
<
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
200
|
+
<div
|
|
201
|
+
class="um-nav-btn um-nav-btn-active d-flex align-items-center justify-content-center"
|
|
202
|
+
style="cursor:pointer;"
|
|
203
|
+
type="button"
|
|
204
|
+
onclick="${gvc.event(() => {
|
|
205
|
+
if (update_vm.pwd.length < 8) {
|
|
206
|
+
dialog.errorMessage({ text: Language.text('password_min_length') });
|
|
207
|
+
return;
|
|
208
|
+
}
|
|
209
|
+
if (repeat_pwd !== update_vm.pwd) {
|
|
210
|
+
dialog.errorMessage({ text: Language.text('please_confirm_password_again') });
|
|
211
|
+
return;
|
|
212
|
+
}
|
|
213
|
+
dialog.dataLoading({ visible: true });
|
|
214
|
+
ApiUser.updateUserData({
|
|
215
|
+
userData: update_vm,
|
|
216
|
+
}).then(res => {
|
|
217
|
+
dialog.dataLoading({ visible: false });
|
|
218
|
+
if (!res.result && res.response.data.msg === 'email-verify-false') {
|
|
219
|
+
dialog.errorMessage({
|
|
220
|
+
text: Language.text('email_verification_code_incorrect'),
|
|
221
|
+
});
|
|
222
|
+
} else if (!res.result && res.response.data.msg === 'phone-verify-false') {
|
|
223
|
+
dialog.errorMessage({
|
|
224
|
+
text: Language.text('sms_verification_code_incorrect'),
|
|
225
|
+
});
|
|
226
|
+
} else if (!res.result && res.response.data.msg === 'phone-exists') {
|
|
227
|
+
dialog.errorMessage({ text: Language.text('phone_number_already_exists') });
|
|
228
|
+
} else if (!res.result && res.response.data.msg === 'email-exists') {
|
|
229
|
+
dialog.errorMessage({ text: Language.text('email_already_exists') });
|
|
230
|
+
} else if (!res.result) {
|
|
231
|
+
dialog.errorMessage({ text: Language.text('update_exception') });
|
|
232
|
+
} else {
|
|
233
|
+
dialog.successMessage({ text: Language.text('change_success') });
|
|
234
|
+
gvc.closeDialog();
|
|
235
|
+
}
|
|
236
|
+
});
|
|
237
|
+
})}"
|
|
238
|
+
>
|
|
239
|
+
<span class="tx_700_white">${Language.text('confirm_reset')}</span>
|
|
240
|
+
</div>
|
|
241
|
+
</div>`,
|
|
242
|
+
].join('');
|
|
243
|
+
},
|
|
244
|
+
});
|
|
245
|
+
}),
|
|
234
246
|
},
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
}
|
|
247
|
+
{
|
|
248
|
+
title: Language.text('delete_account'),
|
|
249
|
+
event: gvc.event(async () => {
|
|
250
|
+
const dialog = new ShareDialog(gvc.glitter);
|
|
251
|
+
dialog.checkYesOrNot({
|
|
252
|
+
text: Language.text('delete_account_c'),
|
|
253
|
+
callback: response => {
|
|
254
|
+
if (response) {
|
|
255
|
+
dialog.successMessage({ text: Language.text('request_submit') });
|
|
256
|
+
}
|
|
257
|
+
},
|
|
258
|
+
});
|
|
259
|
+
}),
|
|
248
260
|
},
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
}
|
|
261
|
+
{
|
|
262
|
+
title: Language.text('logout'),
|
|
263
|
+
event: gvc.event(() => {
|
|
264
|
+
const dialog = new ShareDialog(gvc.glitter);
|
|
265
|
+
dialog.checkYesOrNot({
|
|
266
|
+
text: Language.text('check_logout'),
|
|
267
|
+
callback: response => {
|
|
268
|
+
if (response) {
|
|
269
|
+
GlobalUser.token = '';
|
|
270
|
+
gvc.glitter.href = '/index';
|
|
271
|
+
}
|
|
272
|
+
},
|
|
273
|
+
});
|
|
274
|
+
}),
|
|
263
275
|
},
|
|
276
|
+
]
|
|
277
|
+
.map(dd => {
|
|
278
|
+
return html`<div
|
|
279
|
+
class="d-flex align-items-center w-100"
|
|
280
|
+
style="cursor:pointer; height: 30px; font-size: 16px; font-style: normal; font-weight: 400; color:${g_css.title};"
|
|
281
|
+
onclick="${dd.event}"
|
|
282
|
+
>
|
|
283
|
+
${dd.title}
|
|
284
|
+
</div>`;
|
|
285
|
+
})
|
|
286
|
+
.join(`${document.body.clientWidth > 800 ? `` : `<div class="w-100 border-top my-1"></div>`}`)}
|
|
287
|
+
</div>`;
|
|
288
|
+
}
|
|
289
|
+
})()}
|
|
290
|
+
${gvc.bindView(() => {
|
|
291
|
+
return {
|
|
292
|
+
bind: gvc.glitter.getUUID(),
|
|
293
|
+
view: () => {
|
|
294
|
+
return new Promise((resolve, reject) => {
|
|
295
|
+
switch (gvc.glitter.getUrlParameter('page')) {
|
|
296
|
+
case 'rebate':
|
|
297
|
+
gvc.glitter.getModule(
|
|
298
|
+
gvc.glitter.root_path + `public-components/user-manager/um-rebate.js`,
|
|
299
|
+
res => {
|
|
300
|
+
resolve(res.main(gvc, {}, {}));
|
|
301
|
+
}
|
|
302
|
+
);
|
|
303
|
+
break;
|
|
304
|
+
case 'account_userinfo':
|
|
305
|
+
gvc.glitter.getModule(
|
|
306
|
+
gvc.glitter.root_path + `public-components/user-manager/um-info.js`,
|
|
307
|
+
res => {
|
|
308
|
+
resolve(res.main(gvc, {}, {}));
|
|
309
|
+
}
|
|
310
|
+
);
|
|
311
|
+
break;
|
|
312
|
+
case 'recipient_info':
|
|
313
|
+
gvc.glitter.getModule(
|
|
314
|
+
gvc.glitter.root_path + `public-components/user-manager/um-receive.js`,
|
|
315
|
+
res => {
|
|
316
|
+
resolve(res.main(gvc, {}, {}));
|
|
317
|
+
}
|
|
318
|
+
);
|
|
319
|
+
break;
|
|
320
|
+
case 'account_edit':
|
|
321
|
+
gvc.glitter.getModule(
|
|
322
|
+
gvc.glitter.root_path + `public-components/user-manager/um-info.js`,
|
|
323
|
+
res => {
|
|
324
|
+
resolve(res.edit(gvc, {}, {}));
|
|
325
|
+
}
|
|
326
|
+
);
|
|
327
|
+
break;
|
|
328
|
+
case 'order_list':
|
|
329
|
+
gvc.glitter.getModule(
|
|
330
|
+
gvc.glitter.root_path + `public-components/user-manager/um-orderlist.js`,
|
|
331
|
+
res => {
|
|
332
|
+
resolve(res.main(gvc, {}, {}));
|
|
333
|
+
}
|
|
334
|
+
);
|
|
335
|
+
break;
|
|
336
|
+
case 'wishlist':
|
|
337
|
+
gvc.glitter.getModule(
|
|
338
|
+
gvc.glitter.root_path + `public-components/user-manager/um-wishlist.js`,
|
|
339
|
+
res => {
|
|
340
|
+
resolve(res.main(gvc, {}, {}));
|
|
341
|
+
}
|
|
342
|
+
);
|
|
343
|
+
break;
|
|
344
|
+
case 'voucher-list':
|
|
345
|
+
gvc.glitter.getModule(
|
|
346
|
+
gvc.glitter.root_path + `public-components/user-manager/um-voucher.js`,
|
|
347
|
+
res => {
|
|
348
|
+
resolve(res.main(gvc, {}, {}));
|
|
349
|
+
}
|
|
350
|
+
);
|
|
351
|
+
break;
|
|
352
|
+
}
|
|
264
353
|
});
|
|
265
|
-
}
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
font-size: 16px;
|
|
273
|
-
font-style: normal;
|
|
274
|
-
font-weight: 400;
|
|
275
|
-
color:${g_css.title};" onclick="${dd.event}">${dd.title}</div>`;
|
|
276
|
-
})
|
|
277
|
-
.join(`${document.body.clientWidth > 800 ? `` : `<div class="w-100 border-top my-1"></div>`}`)}
|
|
278
|
-
</div>`;
|
|
279
|
-
}
|
|
280
|
-
})()}
|
|
281
|
-
${gvc.bindView(() => {
|
|
282
|
-
return {
|
|
283
|
-
bind: gvc.glitter.getUUID(),
|
|
284
|
-
view: () => {
|
|
285
|
-
return new Promise((resolve, reject) => {
|
|
286
|
-
switch (gvc.glitter.getUrlParameter('page')) {
|
|
287
|
-
case 'rebate':
|
|
288
|
-
gvc.glitter.getModule(
|
|
289
|
-
gvc.glitter.root_path + `public-components/user-manager/um-rebate.js`,
|
|
290
|
-
res => {
|
|
291
|
-
resolve(res.main(gvc, {}, {}));
|
|
292
|
-
}
|
|
293
|
-
);
|
|
294
|
-
break;
|
|
295
|
-
case 'account_userinfo':
|
|
296
|
-
gvc.glitter.getModule(
|
|
297
|
-
gvc.glitter.root_path + `public-components/user-manager/um-info.js`,
|
|
298
|
-
res => {
|
|
299
|
-
resolve(res.main(gvc, {}, {}));
|
|
300
|
-
}
|
|
301
|
-
);
|
|
302
|
-
break;
|
|
303
|
-
case 'account_edit':
|
|
304
|
-
gvc.glitter.getModule(
|
|
305
|
-
gvc.glitter.root_path + `public-components/user-manager/um-info.js`,
|
|
306
|
-
res => {
|
|
307
|
-
resolve(res.edit(gvc, {}, {}));
|
|
308
|
-
}
|
|
309
|
-
);
|
|
310
|
-
break;
|
|
311
|
-
case 'order_list':
|
|
312
|
-
gvc.glitter.getModule(
|
|
313
|
-
gvc.glitter.root_path + `public-components/user-manager/um-orderlist.js`,
|
|
314
|
-
res => {
|
|
315
|
-
resolve(res.main(gvc, {}, {}));
|
|
316
|
-
}
|
|
317
|
-
);
|
|
318
|
-
break;
|
|
319
|
-
case 'wishlist':
|
|
320
|
-
gvc.glitter.getModule(
|
|
321
|
-
gvc.glitter.root_path + `public-components/user-manager/um-wishlist.js`,
|
|
322
|
-
res => {
|
|
323
|
-
resolve(res.main(gvc, {}, {}));
|
|
324
|
-
}
|
|
325
|
-
);
|
|
326
|
-
break;
|
|
327
|
-
case 'voucher-list':
|
|
328
|
-
gvc.glitter.getModule(
|
|
329
|
-
gvc.glitter.root_path + `public-components/user-manager/um-voucher.js`,
|
|
330
|
-
res => {
|
|
331
|
-
resolve(res.main(gvc, {}, {}));
|
|
332
|
-
}
|
|
333
|
-
);
|
|
334
|
-
break;
|
|
335
|
-
}
|
|
336
|
-
});
|
|
337
|
-
},
|
|
338
|
-
divCreate: {
|
|
339
|
-
class: `flex-fill`,
|
|
340
|
-
},
|
|
341
|
-
};
|
|
342
|
-
})}
|
|
343
|
-
|
|
344
|
-
</div>`;
|
|
354
|
+
},
|
|
355
|
+
divCreate: {
|
|
356
|
+
class: `flex-fill`,
|
|
357
|
+
},
|
|
358
|
+
};
|
|
359
|
+
})}
|
|
360
|
+
</div>`;
|
|
345
361
|
},
|
|
346
362
|
divCreate: {
|
|
347
363
|
class: `mx-auto px-3 px-lg-0 pb-5`,
|
|
@@ -349,7 +365,7 @@ color:${g_css.title};" onclick="${dd.event}">${dd.title}</div>`;
|
|
|
349
365
|
},
|
|
350
366
|
};
|
|
351
367
|
}),
|
|
352
|
-
` <div style="height:${glitter.share.bottom_inset || 0}px;"></div
|
|
368
|
+
` <div style="height:${glitter.share.bottom_inset || 0}px;"></div>`,
|
|
353
369
|
];
|
|
354
370
|
}
|
|
355
371
|
}
|