ts-glitter 21.5.2 → 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/headers/sy-02.js +1 -1
- package/lowcode/public-components/headers/sy-02.ts +1 -1
- package/lowcode/public-components/headers/sy-03.js +1 -1
- package/lowcode/public-components/headers/sy-03.ts +1 -1
- package/lowcode/public-components/headers/sy-04.js +1 -1
- package/lowcode/public-components/headers/sy-04.ts +1 -1
- package/lowcode/public-components/headers/sy-05.js +1 -2
- package/lowcode/public-components/headers/sy-05.ts +1 -1
- 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/product/pd-class.js +1 -1
- package/lowcode/public-components/product/pd-class.ts +1 -1
- 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
|
@@ -6,328 +6,342 @@ import { Language } from '../../glitter-base/global/language.js';
|
|
|
6
6
|
const html = String.raw;
|
|
7
7
|
|
|
8
8
|
interface ShipmentObject {
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
type: string;
|
|
10
|
+
value: number;
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
interface LineItem {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
14
|
+
id: number;
|
|
15
|
+
sku: string;
|
|
16
|
+
spec: string[];
|
|
17
|
+
count: number;
|
|
18
|
+
title: string;
|
|
19
|
+
rebate: number;
|
|
20
|
+
collection: any[];
|
|
21
|
+
sale_price: number;
|
|
22
|
+
shipment_obj: ShipmentObject;
|
|
23
|
+
preview_image: string;
|
|
24
|
+
discount_price: number;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
interface UserInfo {
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
28
|
+
name: string;
|
|
29
|
+
email: string;
|
|
30
|
+
phone: string;
|
|
31
|
+
shipment: string;
|
|
32
|
+
send_type: string;
|
|
33
|
+
CVSAddress: string;
|
|
34
|
+
CVSStoreID: string;
|
|
35
|
+
CVSStoreName: string;
|
|
36
|
+
CVSTelephone: string;
|
|
37
|
+
invoice_type: string;
|
|
38
|
+
shipment_info: string;
|
|
39
|
+
invoice_method: string;
|
|
40
|
+
MerchantTradeNo: string;
|
|
41
|
+
LogisticsSubType: string;
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
interface PaymentInfoATM {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
45
|
+
text: string;
|
|
46
|
+
bank_code: string;
|
|
47
|
+
bank_name: string;
|
|
48
|
+
bank_user: string;
|
|
49
|
+
bank_account: string;
|
|
50
50
|
}
|
|
51
51
|
|
|
52
52
|
interface PaymentInfoLinePay {
|
|
53
|
-
|
|
53
|
+
text: string;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
56
|
interface PaymentSetting {
|
|
57
|
-
|
|
57
|
+
TYPE: string;
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
interface UseRebateInfo {
|
|
61
|
-
|
|
61
|
+
point: number;
|
|
62
62
|
}
|
|
63
63
|
|
|
64
64
|
interface OffLineSupport {
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
65
|
+
atm: boolean;
|
|
66
|
+
line: boolean;
|
|
67
|
+
cash_on_delivery: boolean;
|
|
68
68
|
}
|
|
69
69
|
|
|
70
70
|
interface CustomerInfo {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
71
|
+
name: string;
|
|
72
|
+
email: string;
|
|
73
|
+
phone: string;
|
|
74
|
+
payment_select: string;
|
|
75
75
|
}
|
|
76
76
|
|
|
77
77
|
interface ShipmentSelector {
|
|
78
|
-
|
|
79
|
-
|
|
78
|
+
name: string;
|
|
79
|
+
value: string;
|
|
80
80
|
}
|
|
81
81
|
|
|
82
82
|
interface OrderData {
|
|
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
|
-
|
|
83
|
+
email: string;
|
|
84
|
+
total: number;
|
|
85
|
+
method: string;
|
|
86
|
+
rebate: number;
|
|
87
|
+
orderID: string;
|
|
88
|
+
discount: number;
|
|
89
|
+
progress: string;
|
|
90
|
+
give_away: any[];
|
|
91
|
+
lineItems: LineItem[];
|
|
92
|
+
user_info: UserInfo;
|
|
93
|
+
code_array: any[];
|
|
94
|
+
use_rebate: number;
|
|
95
|
+
use_wallet: number;
|
|
96
|
+
user_email: string;
|
|
97
|
+
orderSource: string;
|
|
98
|
+
voucherList: any[];
|
|
99
|
+
orderStatus: string;
|
|
100
|
+
shipment_fee: number;
|
|
101
|
+
customer_info: CustomerInfo;
|
|
102
|
+
shipment_info: string;
|
|
103
|
+
useRebateInfo: UseRebateInfo;
|
|
104
|
+
payment_setting: PaymentSetting;
|
|
105
|
+
user_rebate_sum: number;
|
|
106
|
+
custom_form_data: any;
|
|
107
|
+
off_line_support: OffLineSupport;
|
|
108
|
+
payment_info_atm: PaymentInfoATM;
|
|
109
|
+
shipment_support: string[];
|
|
110
|
+
shipment_selector: ShipmentSelector[];
|
|
111
|
+
custom_form_format: any[];
|
|
112
|
+
payment_info_line_pay: PaymentInfoLinePay;
|
|
113
|
+
proof_purchase?: string;
|
|
114
114
|
}
|
|
115
115
|
|
|
116
116
|
interface CartOrder {
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
117
|
+
id: number;
|
|
118
|
+
cart_token: string;
|
|
119
|
+
status: number;
|
|
120
|
+
email: string;
|
|
121
|
+
orderData: OrderData;
|
|
122
|
+
created_time: string;
|
|
123
|
+
index: number;
|
|
124
124
|
}
|
|
125
125
|
|
|
126
126
|
export class UMOrderList {
|
|
127
|
-
|
|
127
|
+
static main(gvc: GVC, widget: any, subData: any) {
|
|
128
|
+
const glitter = gvc.glitter;
|
|
129
|
+
const vm = {
|
|
130
|
+
dataList: [] as CartOrder[],
|
|
131
|
+
amount: 0,
|
|
132
|
+
oldestText: '',
|
|
133
|
+
};
|
|
134
|
+
const ids = {
|
|
135
|
+
view: glitter.getUUID(),
|
|
136
|
+
};
|
|
137
|
+
const loadings = {
|
|
138
|
+
view: true,
|
|
139
|
+
};
|
|
128
140
|
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
oldestText: '',
|
|
134
|
-
};
|
|
135
|
-
const ids = {
|
|
136
|
-
view: glitter.getUUID(),
|
|
137
|
-
};
|
|
138
|
-
const loadings = {
|
|
139
|
-
view: true,
|
|
140
|
-
};
|
|
141
|
+
let changePage = (index: string, type: 'page' | 'home', subData: any) => {};
|
|
142
|
+
gvc.glitter.getModule(new URL('./official_event/page/change-page.js', gvc.glitter.root_path).href, cl => {
|
|
143
|
+
changePage = cl.changePage;
|
|
144
|
+
});
|
|
141
145
|
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
+
return gvc.bindView({
|
|
147
|
+
bind: ids.view,
|
|
148
|
+
view: () => {
|
|
149
|
+
if (loadings.view) {
|
|
150
|
+
return UmClass.spinner();
|
|
151
|
+
} else {
|
|
152
|
+
const isWebsite = document.body.clientWidth > 768;
|
|
153
|
+
return html`
|
|
154
|
+
<div class="row mx-auto">
|
|
155
|
+
<div class="col-12">
|
|
156
|
+
<div class="w-100 align-items-center d-flex py-3 pb-lg-3 pt-lg-0" style="gap:10px;">
|
|
157
|
+
<div
|
|
158
|
+
class="d-none d-lg-flex"
|
|
159
|
+
style="background: #FF9705;background: #FF9705;width:4px;height: 20px;"
|
|
160
|
+
onclick="${gvc.event(() => {
|
|
161
|
+
gvc.glitter.getModule(
|
|
162
|
+
new URL(gvc.glitter.root_path + 'official_event/page/change-page.js', import.meta.url).href,
|
|
163
|
+
cl => {
|
|
164
|
+
cl.changePage('account_userinfo', 'home', {});
|
|
165
|
+
}
|
|
166
|
+
);
|
|
167
|
+
})}"
|
|
168
|
+
></div>
|
|
169
|
+
<div
|
|
170
|
+
class="d-flex d-lg-none align-items-center justify-content-center"
|
|
171
|
+
style="width:20px;height: 20px;"
|
|
172
|
+
onclick="${gvc.event(() => {
|
|
173
|
+
gvc.glitter.getModule(
|
|
174
|
+
new URL(gvc.glitter.root_path + 'official_event/page/change-page.js', import.meta.url).href,
|
|
175
|
+
cl => {
|
|
176
|
+
cl.changePage('account_userinfo', 'home', {});
|
|
177
|
+
}
|
|
178
|
+
);
|
|
179
|
+
})}"
|
|
180
|
+
>
|
|
181
|
+
<i class="fa-solid fa-angle-left fs-4"></i>
|
|
182
|
+
</div>
|
|
183
|
+
<div class="um-info-title fw-bold " style="font-size: 24px;">${Language.text('order_history')}</div>
|
|
184
|
+
</div>
|
|
185
|
+
</div>
|
|
186
|
+
<div class="col-12" style="min-height: 500px;">
|
|
187
|
+
<div class="mx-auto orderList">
|
|
188
|
+
${(() => {
|
|
189
|
+
if (vm.dataList.length === 0) {
|
|
190
|
+
return html`<div
|
|
191
|
+
class="d-flex align-items-center justify-content-center flex-column w-100 mx-auto"
|
|
192
|
+
>
|
|
193
|
+
<lottie-player
|
|
194
|
+
style="max-width: 100%;width: 300px;"
|
|
195
|
+
src="https://assets10.lottiefiles.com/packages/lf20_rc6CDU.json"
|
|
196
|
+
speed="1"
|
|
197
|
+
loop="true"
|
|
198
|
+
background="transparent"
|
|
199
|
+
></lottie-player>
|
|
200
|
+
<span class="mb-5 fs-5">${Language.text('no_current_orders')}</span>
|
|
201
|
+
</div>`;
|
|
202
|
+
}
|
|
146
203
|
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
<div class="d-flex d-lg-none align-items-center justify-content-center" style="width:20px;height: 20px;" onclick="${gvc.event(()=>{
|
|
165
|
-
gvc.glitter.getModule(new URL(gvc.glitter.root_path+'official_event/page/change-page.js', import.meta.url).href, (cl) => {
|
|
166
|
-
cl.changePage('account_userinfo', 'home', {})
|
|
167
|
-
})
|
|
168
|
-
})}">
|
|
169
|
-
<i class="fa-solid fa-angle-left fs-4"></i>
|
|
170
|
-
</div>
|
|
171
|
-
<div class="um-info-title fw-bold " style="font-size: 24px;">${Language.text('order_history')}</div>
|
|
172
|
-
</div>
|
|
173
|
-
</div>
|
|
174
|
-
<div class="col-12 " style="min-height: 500px;">
|
|
175
|
-
<div class="mx-auto orderList">
|
|
176
|
-
${(() => {
|
|
177
|
-
if (vm.dataList.length === 0) {
|
|
178
|
-
return html`<div class="d-flex align-items-center justify-content-center flex-column w-100 mx-auto">
|
|
179
|
-
<lottie-player
|
|
180
|
-
style="max-width: 100%;width: 300px;"
|
|
181
|
-
src="https://assets10.lottiefiles.com/packages/lf20_rc6CDU.json"
|
|
182
|
-
speed="1"
|
|
183
|
-
loop="true"
|
|
184
|
-
background="transparent"
|
|
185
|
-
></lottie-player>
|
|
186
|
-
<span class="mb-5 fs-5">${Language.text('no_current_orders')}</span>
|
|
187
|
-
</div>`;
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
const header = [
|
|
191
|
-
{
|
|
192
|
-
title: Language.text('order_number'),
|
|
193
|
-
},
|
|
194
|
-
{
|
|
195
|
-
title: Language.text('order_date'),
|
|
196
|
-
},
|
|
197
|
-
{
|
|
198
|
-
title: Language.text('order_amount'),
|
|
199
|
-
},
|
|
200
|
-
{
|
|
201
|
-
title: Language.text('order_status'),
|
|
202
|
-
},
|
|
203
|
-
{
|
|
204
|
-
title: '',
|
|
205
|
-
},
|
|
206
|
-
];
|
|
204
|
+
const header = [
|
|
205
|
+
{
|
|
206
|
+
title: Language.text('order_number'),
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
title: Language.text('order_date'),
|
|
210
|
+
},
|
|
211
|
+
{
|
|
212
|
+
title: Language.text('order_amount'),
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
title: Language.text('order_status'),
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
title: '',
|
|
219
|
+
},
|
|
220
|
+
];
|
|
207
221
|
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
222
|
+
function formatText(item: CartOrder) {
|
|
223
|
+
return [
|
|
224
|
+
item.cart_token ?? Language.text('no_number_order'),
|
|
225
|
+
glitter.ut.dateFormat(new Date(item.created_time), 'yyyy/MM/dd'),
|
|
226
|
+
(item.orderData.total ?? 0).toLocaleString(),
|
|
227
|
+
(() => {
|
|
228
|
+
// 狀態: 已取消, 已完成
|
|
229
|
+
if (item.orderData.orderStatus === '-1') {
|
|
230
|
+
return Language.text('cancelled');
|
|
231
|
+
} else if (item.orderData.orderStatus === '1') {
|
|
232
|
+
return Language.text('completed');
|
|
233
|
+
}
|
|
220
234
|
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
235
|
+
// 付款: 待核款, 已付款, 已退款
|
|
236
|
+
if (item.status === 0) {
|
|
237
|
+
if (item.orderData.proof_purchase) {
|
|
238
|
+
return Language.text('awaiting_verification');
|
|
239
|
+
}
|
|
240
|
+
return Language.text('unpaid');
|
|
241
|
+
} else if (item.status === -2) {
|
|
242
|
+
return Language.text('refunded');
|
|
243
|
+
}
|
|
230
244
|
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
245
|
+
// 配送: 揀貨中, 配送中, 配送完成
|
|
246
|
+
switch (item.orderData.progress) {
|
|
247
|
+
case 'shipping':
|
|
248
|
+
return Language.text('shipping');
|
|
249
|
+
case 'finish':
|
|
250
|
+
return Language.text('delivered');
|
|
251
|
+
default:
|
|
252
|
+
return Language.text('preparing');
|
|
253
|
+
}
|
|
254
|
+
})(),
|
|
255
|
+
html`<div
|
|
256
|
+
class="option px-4 d-flex justify-content-center um-nav-btn um-nav-btn-active"
|
|
257
|
+
onclick="${gvc.event(() => {
|
|
258
|
+
gvc.glitter.setUrlParameter('cart_token', item.cart_token);
|
|
259
|
+
changePage('order_detail', 'page', {});
|
|
260
|
+
})}"
|
|
261
|
+
>
|
|
262
|
+
${Language.text('view')}
|
|
263
|
+
</div>`,
|
|
264
|
+
];
|
|
265
|
+
}
|
|
252
266
|
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
</div>
|
|
263
|
-
${vm.dataList
|
|
264
|
-
.map((item) => {
|
|
265
|
-
return html`<div class="w-100 d-sm-flex py-5 um-td-bar">
|
|
266
|
-
${formatText(item)
|
|
267
|
-
.map((dd, index) => {
|
|
268
|
-
return html`<div class="um-td" style="flex: ${flexList[index]}">${dd}</div>`;
|
|
269
|
-
})
|
|
270
|
-
.join('')}
|
|
271
|
-
</div>`;
|
|
272
|
-
})
|
|
273
|
-
.join('')}
|
|
274
|
-
`;
|
|
275
|
-
}
|
|
276
|
-
|
|
277
|
-
return html`<div class="w-100 d-sm-none mb-3 s162413">
|
|
278
|
-
${vm.dataList
|
|
279
|
-
.map((item) => {
|
|
280
|
-
return html`<div class="um-mobile-area">
|
|
281
|
-
${formatText(item)
|
|
282
|
-
.map((dd, index) => {
|
|
283
|
-
if (header[index].title === '') {
|
|
284
|
-
return dd;
|
|
285
|
-
}
|
|
286
|
-
return html`<div class="um-mobile-text">${header[index].title}: ${dd}</div>`;
|
|
287
|
-
})
|
|
288
|
-
.join('')}
|
|
289
|
-
</div>`;
|
|
290
|
-
})
|
|
291
|
-
.join('')}
|
|
292
|
-
</div> `;
|
|
293
|
-
})()}
|
|
294
|
-
</div>
|
|
295
|
-
</div>
|
|
267
|
+
if (isWebsite) {
|
|
268
|
+
const flexList = [1, 1, 1, 1, 1];
|
|
269
|
+
return html`
|
|
270
|
+
<div class="w-100 d-sm-flex py-4 um-th-bar">
|
|
271
|
+
${header
|
|
272
|
+
.map((item, index) => {
|
|
273
|
+
return html`<div class="um-th" style="flex: ${flexList[index]};">${item.title}</div>`;
|
|
274
|
+
})
|
|
275
|
+
.join('')}
|
|
296
276
|
</div>
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
vm.dataList = [];
|
|
277
|
+
${vm.dataList
|
|
278
|
+
.map(item => {
|
|
279
|
+
return html`<div class="w-100 d-sm-flex py-5 um-td-bar">
|
|
280
|
+
${formatText(item)
|
|
281
|
+
.map((dd, index) => {
|
|
282
|
+
return html`<div class="um-td" style="flex: ${flexList[index]}">${dd}</div>`;
|
|
283
|
+
})
|
|
284
|
+
.join('')}
|
|
285
|
+
</div>`;
|
|
286
|
+
})
|
|
287
|
+
.join('')}
|
|
288
|
+
`;
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
return html`<div class="w-100 d-sm-none mb-3 s162413">
|
|
292
|
+
${vm.dataList
|
|
293
|
+
.map(item => {
|
|
294
|
+
return html`<div class="um-mobile-area">
|
|
295
|
+
${formatText(item)
|
|
296
|
+
.map((dd, index) => {
|
|
297
|
+
if (header[index].title === '') {
|
|
298
|
+
return dd;
|
|
320
299
|
}
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
300
|
+
return html`<div class="um-mobile-text">${header[index].title}: ${dd}</div>`;
|
|
301
|
+
})
|
|
302
|
+
.join('')}
|
|
303
|
+
</div>`;
|
|
304
|
+
})
|
|
305
|
+
.join('')}
|
|
306
|
+
</div> `;
|
|
307
|
+
})()}
|
|
308
|
+
</div>
|
|
309
|
+
</div>
|
|
310
|
+
</div>
|
|
311
|
+
`;
|
|
312
|
+
}
|
|
313
|
+
},
|
|
314
|
+
divCreate: {
|
|
315
|
+
class: '',
|
|
316
|
+
},
|
|
317
|
+
onCreate: () => {
|
|
318
|
+
if (loadings.view) {
|
|
319
|
+
gvc.addMtScript(
|
|
320
|
+
[{ src: `${gvc.glitter.root_path}/jslib/lottie-player.js` }],
|
|
321
|
+
() => {
|
|
322
|
+
ApiShop.getOrder({
|
|
323
|
+
limit: 50,
|
|
324
|
+
page: 0,
|
|
325
|
+
data_from: 'user',
|
|
326
|
+
}).then((res: any) => {
|
|
327
|
+
if (res.result && res.response.data) {
|
|
328
|
+
vm.dataList = res.response.data.map((dd: any, index: number) => {
|
|
329
|
+
dd.index = index;
|
|
330
|
+
return dd;
|
|
331
|
+
});
|
|
332
|
+
} else {
|
|
333
|
+
vm.dataList = [];
|
|
327
334
|
}
|
|
335
|
+
loadings.view = false;
|
|
336
|
+
gvc.notifyDataChange(ids.view);
|
|
337
|
+
});
|
|
328
338
|
},
|
|
329
|
-
|
|
330
|
-
|
|
339
|
+
() => {}
|
|
340
|
+
);
|
|
341
|
+
}
|
|
342
|
+
},
|
|
343
|
+
});
|
|
344
|
+
}
|
|
331
345
|
}
|
|
332
346
|
|
|
333
347
|
(window as any).glitter.setModule(import.meta.url, UMOrderList);
|