ts-glitter 20.3.2 → 20.3.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/backend-manager/bg-product.js +21 -15
- package/lowcode/backend-manager/bg-product.ts +32 -22
- package/lowcode/backend-manager/bg-widget.ts +1 -1
- package/lowcode/cms-plugin/model/order.d.ts +1 -0
- package/lowcode/cms-plugin/module/order-setting.js +118 -22
- package/lowcode/cms-plugin/module/order-setting.ts +133 -22
- package/lowcode/cms-plugin/order/order-module.js +366 -0
- package/lowcode/cms-plugin/order/order-module.ts +404 -0
- package/lowcode/cms-plugin/shopping-order-manager.js +21 -9
- package/lowcode/cms-plugin/shopping-order-manager.ts +21 -9
- package/lowcode/css/editor.css +14 -0
- package/package.json +1 -1
- package/src/api-public/controllers/ai-points.js.map +1 -1
- package/src/api-public/controllers/index.js.map +1 -1
- package/src/api-public/controllers/track.js.map +1 -1
- package/src/api-public/services/filter-protect-data.js.map +1 -1
- package/src/api-public/services/shopping.d.ts +6 -0
- package/src/api-public/services/shopping.js +158 -123
- package/src/api-public/services/shopping.js.map +1 -1
- package/src/api-public/services/shopping.ts +204 -166
- package/src/api-public/services/user.js.map +1 -1
- package/src/controllers/backend-server.js.map +1 -1
- package/src/firebase/message.js +2 -1
- package/src/firebase/message.js.map +1 -1
- package/src/helper/glitter-util.d.ts +1 -0
- package/src/helper/glitter-util.js.map +1 -1
- package/src/modules/caught-error.js.map +1 -1
- package/src/modules/firebase.js.map +1 -1
- package/src/services/app.js +1 -1
- package/src/services/app.ts +1 -1
- package/src/services/backend-service.js +1 -1
- package/src/services/backend-service.js.map +5 -1
- package/src/services/backend-service.ts +1 -1
- package/src/services/ios-release.js.map +1 -1
- package/src/services/release.js.map +1 -1
- package/src/services/saas-table-check.js +2 -2
- package/src/services/saas-table-check.js.map +1 -1
- package/src/services/template.js.map +1 -1
- package/src/api-public/services/product-migrate.js +0 -9
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import { GVC } from '../../glitterBundle/GVController.js';
|
|
2
2
|
import { ShareDialog } from '../../glitterBundle/dialog/ShareDialog.js';
|
|
3
3
|
import { BgWidget } from '../../backend-manager/bg-widget.js';
|
|
4
|
+
import { BgProduct } from '../../backend-manager/bg-product.js';
|
|
4
5
|
import { ApiDelivery } from '../../glitter-base/route/delivery.js';
|
|
6
|
+
import { ApiShop } from '../../glitter-base/route/shopping.js';
|
|
5
7
|
import { PaymentConfig } from '../../glitter-base/global/payment-config.js';
|
|
6
8
|
import { ShipmentConfig } from '../../glitter-base/global/shipment-config.js';
|
|
7
9
|
import { PaymentPage } from '../pos-pages/payment-page.js';
|
|
10
|
+
import { PosFunction } from '../pos-pages/pos-function.js';
|
|
8
11
|
|
|
9
12
|
const html = String.raw;
|
|
10
13
|
|
|
@@ -341,4 +344,405 @@ export class OrderModule {
|
|
|
341
344
|
value: 0,
|
|
342
345
|
};
|
|
343
346
|
}
|
|
347
|
+
|
|
348
|
+
static editOrderLineItems(gvc: GVC, orderData: Order, callback: () => void) {
|
|
349
|
+
const id = gvc.glitter.getUUID();
|
|
350
|
+
const dialog = new ShareDialog(gvc.glitter);
|
|
351
|
+
const cloneData = structuredClone(orderData);
|
|
352
|
+
|
|
353
|
+
function getNewItem(id: number, product: any, variant: any) {
|
|
354
|
+
return {
|
|
355
|
+
id: id,
|
|
356
|
+
sku: variant.sku,
|
|
357
|
+
spec: variant.spec,
|
|
358
|
+
count: 1,
|
|
359
|
+
stock: variant.stockList
|
|
360
|
+
? Number(Object.values(variant.stockList).reduce((sum, val: any) => sum + val.count, 0))
|
|
361
|
+
: 0,
|
|
362
|
+
times: 0,
|
|
363
|
+
title: product.content.title,
|
|
364
|
+
rebate: 0,
|
|
365
|
+
weight: Number(variant.weight),
|
|
366
|
+
is_gift: false,
|
|
367
|
+
is_hidden: false,
|
|
368
|
+
stockList: variant.stockList,
|
|
369
|
+
sale_price: variant.sale_price,
|
|
370
|
+
origin_price: variant.origin_price,
|
|
371
|
+
preview_image: variant.preview_image,
|
|
372
|
+
discount_price: 0,
|
|
373
|
+
is_add_on_items: false,
|
|
374
|
+
show_understocking: variant.show_understocking,
|
|
375
|
+
deduction_log: (() => {
|
|
376
|
+
const obj: any = {};
|
|
377
|
+
const stockKey = Object.keys(variant.stockList).find(key => variant.stockList[key]?.count > 0);
|
|
378
|
+
if (stockKey) {
|
|
379
|
+
obj[stockKey] = 1;
|
|
380
|
+
}
|
|
381
|
+
return obj;
|
|
382
|
+
})(),
|
|
383
|
+
};
|
|
384
|
+
}
|
|
385
|
+
|
|
386
|
+
function showTag(color: string, text: string) {
|
|
387
|
+
return html` <div class="product-show-tag" style="background: ${color};">${text}</div> `;
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
function getLineItemSubtotal(lineItems: LineItem[]) {
|
|
391
|
+
return lineItems
|
|
392
|
+
.map(dd => Number(dd.count) * Number(dd.sale_price))
|
|
393
|
+
.reduce((accumulator, currentValue) => accumulator + currentValue, 0);
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
return BgWidget.settingDialog({
|
|
397
|
+
gvc,
|
|
398
|
+
title: '編輯訂單明細',
|
|
399
|
+
width: 800,
|
|
400
|
+
height: 600,
|
|
401
|
+
innerHTML: gvc => {
|
|
402
|
+
return gvc.bindView({
|
|
403
|
+
bind: id,
|
|
404
|
+
view: () => {
|
|
405
|
+
const subtotal = getLineItemSubtotal(orderData.orderData.lineItems);
|
|
406
|
+
|
|
407
|
+
return html`<div class="d-flex flex-column">
|
|
408
|
+
${orderData.orderData.lineItems
|
|
409
|
+
.filter((dd: any) => dd.count > 0)
|
|
410
|
+
.map((dd: any) => {
|
|
411
|
+
function countInput() {
|
|
412
|
+
return BgWidget.editeInput({
|
|
413
|
+
gvc,
|
|
414
|
+
title: '',
|
|
415
|
+
default: `${dd.count}`,
|
|
416
|
+
placeHolder: '',
|
|
417
|
+
callback: (value: string) => {
|
|
418
|
+
const n = Number(value);
|
|
419
|
+
if (isNaN(n) || n < 0) {
|
|
420
|
+
dialog.errorMessage({ text: '請填寫大於 0 的數值' });
|
|
421
|
+
return;
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
const storeKeys = Object.keys(dd.deduction_log || {});
|
|
425
|
+
if (storeKeys.length > 0) {
|
|
426
|
+
let selectStore = '';
|
|
427
|
+
for (const key of storeKeys) {
|
|
428
|
+
if (dd.deduction_log[key] === 0) {
|
|
429
|
+
delete dd.deduction_log[key];
|
|
430
|
+
} else if (!selectStore && dd.deduction_log[key] > 0) {
|
|
431
|
+
selectStore = key;
|
|
432
|
+
}
|
|
433
|
+
}
|
|
434
|
+
|
|
435
|
+
if (selectStore) {
|
|
436
|
+
dd.deduction_log[selectStore] = n;
|
|
437
|
+
}
|
|
438
|
+
}
|
|
439
|
+
|
|
440
|
+
dd.count = n;
|
|
441
|
+
gvc.notifyDataChange(id);
|
|
442
|
+
},
|
|
443
|
+
style: 'width: 64px;',
|
|
444
|
+
});
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
return html`<div class="d-flex align-items-center gap-1">
|
|
448
|
+
<div
|
|
449
|
+
class="d-flex flex-column align-items-center justify-content-center"
|
|
450
|
+
style="gap: 5px; margin-right: 12px;"
|
|
451
|
+
>
|
|
452
|
+
${BgWidget.validImageBox({
|
|
453
|
+
gvc,
|
|
454
|
+
image: dd.preview_image,
|
|
455
|
+
width: 60,
|
|
456
|
+
class: 'border rounded',
|
|
457
|
+
style: '',
|
|
458
|
+
})}
|
|
459
|
+
</div>
|
|
460
|
+
<div class="d-flex flex-column">
|
|
461
|
+
${dd.is_hidden
|
|
462
|
+
? html`<div style="width:auto;">${BgWidget.secondaryInsignia('隱形商品')}</div>`
|
|
463
|
+
: ''}
|
|
464
|
+
<div class="tx_700 d-flex align-items-center" style="gap:4px;">
|
|
465
|
+
<div>${dd.title}</div>
|
|
466
|
+
${dd.is_gift ? html`<div>${showTag('#FFE9B2', '贈品')}</div>` : ''}
|
|
467
|
+
${dd.is_add_on_items ? html`<div>${showTag('#D8E7EC', '加購品')}</div>` : ''}
|
|
468
|
+
${dd.pre_order ? html`<div>${showTag('#D8E7EC', '預購')}</div>` : ''}
|
|
469
|
+
</div>
|
|
470
|
+
${dd.spec.length > 0 ? BgWidget.grayNote(dd.spec.join(', ')) : ''}
|
|
471
|
+
${BgWidget.grayNote(`存貨單位 (SKU):${dd.sku && dd.sku.length > 0 ? dd.sku : '無'}`)}
|
|
472
|
+
</div>
|
|
473
|
+
<div class="flex-fill"></div>
|
|
474
|
+
<div class="tx_normal_16 d-none d-lg-flex justify-content-end" style="min-width: 80px;">
|
|
475
|
+
<div class="d-flex align-items-center gap-2">
|
|
476
|
+
$${dd.sale_price.toLocaleString()} × ${countInput()}
|
|
477
|
+
</div>
|
|
478
|
+
</div>
|
|
479
|
+
<div
|
|
480
|
+
class="tx_normal d-sm-none d-flex flex-column"
|
|
481
|
+
style="display: flex;justify-content: end;${document.body.clientWidth > 800
|
|
482
|
+
? 'width: 110px'
|
|
483
|
+
: 'width: 140px'}"
|
|
484
|
+
>
|
|
485
|
+
<div>$${dd.sale_price.toLocaleString()} × ${countInput()}</div>
|
|
486
|
+
</div>
|
|
487
|
+
<div
|
|
488
|
+
class="tx_normal d-none d-sm-flex"
|
|
489
|
+
style="display: flex;justify-content: end;${document.body.clientWidth > 800
|
|
490
|
+
? 'width: 110px'
|
|
491
|
+
: ''}"
|
|
492
|
+
>
|
|
493
|
+
$${(dd.sale_price * dd.count).toLocaleString()}
|
|
494
|
+
</div>
|
|
495
|
+
<div
|
|
496
|
+
class="hoverBtn d-flex align-items-center justify-content-center fs-6"
|
|
497
|
+
style="width: 24px; height: 24px;"
|
|
498
|
+
onclick="${gvc.event(() => {
|
|
499
|
+
const findData = orderData.orderData.lineItems.find(item => {
|
|
500
|
+
return item.id === dd.id && item.spec.join('') === dd.spec.join('');
|
|
501
|
+
});
|
|
502
|
+
if (findData) {
|
|
503
|
+
findData.count = 0;
|
|
504
|
+
Object.keys(findData.deduction_log).map(key => {
|
|
505
|
+
findData.deduction_log[key] = 0;
|
|
506
|
+
});
|
|
507
|
+
}
|
|
508
|
+
gvc.notifyDataChange(id);
|
|
509
|
+
})}"
|
|
510
|
+
>
|
|
511
|
+
<i class="fa-sharp fa-regular fa-trash"></i>
|
|
512
|
+
</div>
|
|
513
|
+
</div>`;
|
|
514
|
+
})
|
|
515
|
+
.join(html` <div style="margin-top: 12px;"></div>`)}
|
|
516
|
+
<div class="d-flex align-items-center justify-content-center">
|
|
517
|
+
<div style="width: 50px;">
|
|
518
|
+
${BgWidget.plusButton({
|
|
519
|
+
title: '新增商品',
|
|
520
|
+
event: gvc.event(() => {
|
|
521
|
+
return BgProduct.productsDialog({
|
|
522
|
+
gvc,
|
|
523
|
+
title: '新增商品',
|
|
524
|
+
default: [],
|
|
525
|
+
with_variants: true,
|
|
526
|
+
callback: async (dataArray: any) => {
|
|
527
|
+
const specArray: { id: string; spec: string }[] = [];
|
|
528
|
+
|
|
529
|
+
const idSet = new Set(
|
|
530
|
+
dataArray.map((data: string) => {
|
|
531
|
+
const id = data.split('-')[0];
|
|
532
|
+
const spec = data.substring(data.indexOf('-') + 1);
|
|
533
|
+
specArray.push({ id, spec });
|
|
534
|
+
return id;
|
|
535
|
+
})
|
|
536
|
+
);
|
|
537
|
+
|
|
538
|
+
dialog.dataLoading({ visible: true });
|
|
539
|
+
|
|
540
|
+
await ApiShop.getProduct({
|
|
541
|
+
page: 0,
|
|
542
|
+
limit: 99999,
|
|
543
|
+
id_list: [...idSet].join(','),
|
|
544
|
+
status: 'inRange',
|
|
545
|
+
}).then(r => {
|
|
546
|
+
setTimeout(() => dialog.dataLoading({ visible: false }), 100);
|
|
547
|
+
|
|
548
|
+
if (r.result && r.response.total > 0) {
|
|
549
|
+
const productMap: Map<string, any> = new Map(
|
|
550
|
+
r.response.data.map((product: any) => [`${product.id}`, product])
|
|
551
|
+
);
|
|
552
|
+
|
|
553
|
+
specArray.forEach(specData => {
|
|
554
|
+
const product = productMap.get(`${specData.id}`);
|
|
555
|
+
if (!product) {
|
|
556
|
+
return;
|
|
557
|
+
}
|
|
558
|
+
|
|
559
|
+
const variant = product.content.variants.find(
|
|
560
|
+
(variant: any) => variant.spec.join('-') === specData.spec
|
|
561
|
+
);
|
|
562
|
+
if (!variant) {
|
|
563
|
+
return;
|
|
564
|
+
}
|
|
565
|
+
|
|
566
|
+
const lineItemData = orderData.orderData.lineItems.find(item => {
|
|
567
|
+
return (
|
|
568
|
+
item.id === Number(specData.id) && item.spec.join('') === variant.spec.join('')
|
|
569
|
+
);
|
|
570
|
+
});
|
|
571
|
+
|
|
572
|
+
if (lineItemData) {
|
|
573
|
+
// 原陣列就有的商品
|
|
574
|
+
lineItemData.count++;
|
|
575
|
+
if (Object.keys(lineItemData.deduction_log || {}).length > 0) {
|
|
576
|
+
const key = Object.keys(lineItemData.deduction_log)[0];
|
|
577
|
+
lineItemData.deduction_log[key]++;
|
|
578
|
+
}
|
|
579
|
+
} else {
|
|
580
|
+
// 新增的商品
|
|
581
|
+
const itemObject = getNewItem(Number(specData.id), product, variant);
|
|
582
|
+
orderData.orderData.lineItems.push(itemObject);
|
|
583
|
+
}
|
|
584
|
+
});
|
|
585
|
+
}
|
|
586
|
+
gvc.notifyDataChange(id);
|
|
587
|
+
});
|
|
588
|
+
},
|
|
589
|
+
});
|
|
590
|
+
}),
|
|
591
|
+
})}
|
|
592
|
+
</div>
|
|
593
|
+
</div>
|
|
594
|
+
${BgWidget.horizontalLine()}
|
|
595
|
+
${[
|
|
596
|
+
{
|
|
597
|
+
title: '小計',
|
|
598
|
+
description: `${orderData.orderData.lineItems
|
|
599
|
+
.map(dd => Number(dd.count))
|
|
600
|
+
.reduce((accumulator, currentValue) => accumulator + currentValue, 0)} 件商品`,
|
|
601
|
+
total: `$${subtotal.toLocaleString()}`,
|
|
602
|
+
},
|
|
603
|
+
{
|
|
604
|
+
title: '運費',
|
|
605
|
+
description: '',
|
|
606
|
+
total: `$${orderData.orderData.shipment_fee.toLocaleString()}`,
|
|
607
|
+
},
|
|
608
|
+
...(orderData.orderData.use_rebate
|
|
609
|
+
? [
|
|
610
|
+
{
|
|
611
|
+
title: '回饋金',
|
|
612
|
+
description: '',
|
|
613
|
+
total: `- $${orderData.orderData.use_rebate.toLocaleString()}`,
|
|
614
|
+
},
|
|
615
|
+
]
|
|
616
|
+
: []),
|
|
617
|
+
...(orderData.orderData.use_wallet && `${orderData.orderData.use_wallet}` !== '0'
|
|
618
|
+
? [
|
|
619
|
+
{
|
|
620
|
+
title: '錢包',
|
|
621
|
+
description: `使用錢包扣款`,
|
|
622
|
+
total: `- $${orderData.orderData.use_wallet.toLocaleString()}`,
|
|
623
|
+
},
|
|
624
|
+
]
|
|
625
|
+
: []),
|
|
626
|
+
...orderData.orderData.voucherList.map((dd: any) => {
|
|
627
|
+
const descHTML = html` <div
|
|
628
|
+
style="color: #8D8D8D; font-size: 14px; white-space: nowrap; text-overflow: ellipsis;"
|
|
629
|
+
>
|
|
630
|
+
${dd.title}
|
|
631
|
+
</div>`;
|
|
632
|
+
const rebackMaps: Record<string, { title: string; description: string; total: string }> = {
|
|
633
|
+
add_on_items: {
|
|
634
|
+
title: '加購優惠',
|
|
635
|
+
description: descHTML,
|
|
636
|
+
total: '-',
|
|
637
|
+
},
|
|
638
|
+
giveaway: {
|
|
639
|
+
title: '滿額贈送',
|
|
640
|
+
description: descHTML,
|
|
641
|
+
total: '-',
|
|
642
|
+
},
|
|
643
|
+
rebate: {
|
|
644
|
+
title: '回饋購物金',
|
|
645
|
+
description: descHTML,
|
|
646
|
+
total: `${dd.rebate_total} 點`,
|
|
647
|
+
},
|
|
648
|
+
default: {
|
|
649
|
+
title: dd.id == 0 ? '手動調整' : '折扣',
|
|
650
|
+
description: descHTML,
|
|
651
|
+
total: (() => {
|
|
652
|
+
const status = dd.discount_total > 0;
|
|
653
|
+
const isMinus = status ? '-' : '';
|
|
654
|
+
const isNegative = status ? 1 : -1;
|
|
655
|
+
return `${isMinus} $${(dd.discount_total * isNegative).toLocaleString()}`;
|
|
656
|
+
})(),
|
|
657
|
+
},
|
|
658
|
+
};
|
|
659
|
+
|
|
660
|
+
return rebackMaps[dd.reBackType] ?? rebackMaps.default;
|
|
661
|
+
}),
|
|
662
|
+
{
|
|
663
|
+
title: html`<span class="tx_700">總金額</span>`,
|
|
664
|
+
description: '',
|
|
665
|
+
total: html`<span class="tx_700"
|
|
666
|
+
>$${(
|
|
667
|
+
subtotal -
|
|
668
|
+
orderData.orderData.discount +
|
|
669
|
+
orderData.orderData.shipment_fee -
|
|
670
|
+
orderData.orderData.use_rebate
|
|
671
|
+
).toLocaleString()}</span
|
|
672
|
+
>`,
|
|
673
|
+
},
|
|
674
|
+
]
|
|
675
|
+
.map(dd => {
|
|
676
|
+
return html` <div class="d-flex align-items-center justify-content-end">
|
|
677
|
+
<div class="tx_normal_16" style="text-align: end;">${dd.title} ${dd.description ?? ''}</div>
|
|
678
|
+
<div class="tx_normal" style="width: 114px;display: flex;justify-content: end;">${dd.total}</div>
|
|
679
|
+
</div>`;
|
|
680
|
+
})
|
|
681
|
+
.join(BgWidget.mbContainer(18))}
|
|
682
|
+
${`${orderData.orderData.orderStatus ?? 0}` === '0'
|
|
683
|
+
? html`<div class="d-flex justify-content-end mt-3">
|
|
684
|
+
${BgWidget.blueNote(
|
|
685
|
+
'手動調整訂單價格',
|
|
686
|
+
gvc.event(() => {
|
|
687
|
+
PosFunction.manualDiscount({
|
|
688
|
+
gvc,
|
|
689
|
+
orderDetail: orderData.orderData,
|
|
690
|
+
reload: voucher => {
|
|
691
|
+
orderData.orderData.total -= voucher.discount_total;
|
|
692
|
+
orderData.orderData.discount += voucher.discount_total;
|
|
693
|
+
gvc.notifyDataChange(id);
|
|
694
|
+
},
|
|
695
|
+
});
|
|
696
|
+
})
|
|
697
|
+
)}
|
|
698
|
+
</div>`
|
|
699
|
+
: ''}
|
|
700
|
+
</div>`;
|
|
701
|
+
},
|
|
702
|
+
});
|
|
703
|
+
},
|
|
704
|
+
footer_html: footerGVC => {
|
|
705
|
+
return [
|
|
706
|
+
BgWidget.cancel(
|
|
707
|
+
footerGVC.event(() => {
|
|
708
|
+
orderData = cloneData;
|
|
709
|
+
footerGVC.closeDialog();
|
|
710
|
+
})
|
|
711
|
+
),
|
|
712
|
+
BgWidget.save(
|
|
713
|
+
footerGVC.event(() => {
|
|
714
|
+
function updateEvent() {
|
|
715
|
+
// 重新計算總金額
|
|
716
|
+
orderData.orderData.total =
|
|
717
|
+
getLineItemSubtotal(orderData.orderData.lineItems) -
|
|
718
|
+
orderData.orderData.discount +
|
|
719
|
+
orderData.orderData.shipment_fee -
|
|
720
|
+
orderData.orderData.use_rebate;
|
|
721
|
+
|
|
722
|
+
dialog.dataLoading({ visible: true });
|
|
723
|
+
|
|
724
|
+
ApiShop.putOrder({
|
|
725
|
+
id: `${orderData.id}`,
|
|
726
|
+
order_data: orderData.orderData,
|
|
727
|
+
}).then(() => {
|
|
728
|
+
dialog.dataLoading({ visible: false });
|
|
729
|
+
footerGVC.closeDialog();
|
|
730
|
+
callback();
|
|
731
|
+
});
|
|
732
|
+
}
|
|
733
|
+
|
|
734
|
+
dialog.checkYesOrNot({
|
|
735
|
+
text: '此操作將會直接更新訂單明細,確定要更新嗎?',
|
|
736
|
+
callback: bool => bool && updateEvent(),
|
|
737
|
+
});
|
|
738
|
+
}),
|
|
739
|
+
'更新'
|
|
740
|
+
),
|
|
741
|
+
].join('');
|
|
742
|
+
},
|
|
743
|
+
closeCallback: () => {
|
|
744
|
+
orderData = cloneData;
|
|
745
|
+
},
|
|
746
|
+
});
|
|
747
|
+
}
|
|
344
748
|
}
|
|
@@ -1292,7 +1292,7 @@ export class ShoppingOrderManager {
|
|
|
1292
1292
|
BgWidget.editeInput({
|
|
1293
1293
|
gvc: gvc,
|
|
1294
1294
|
title: '出貨單號碼',
|
|
1295
|
-
default: shipnumber !== null && shipnumber !== void 0 ? shipnumber : ''
|
|
1295
|
+
default: `${shipnumber !== null && shipnumber !== void 0 ? shipnumber : ''}`,
|
|
1296
1296
|
callback: text => {
|
|
1297
1297
|
shipnumber = text;
|
|
1298
1298
|
},
|
|
@@ -1781,7 +1781,23 @@ export class ShoppingOrderManager {
|
|
|
1781
1781
|
})}
|
|
1782
1782
|
</div>
|
|
1783
1783
|
</div>
|
|
1784
|
-
<div class="
|
|
1784
|
+
<div class="d-flex align-items-center justify-content-between mt-3 mb-2">
|
|
1785
|
+
<div class="tx_700">訂單明細</div>
|
|
1786
|
+
${BgWidget.customButton({
|
|
1787
|
+
button: {
|
|
1788
|
+
color: 'gray',
|
|
1789
|
+
size: 'sm',
|
|
1790
|
+
},
|
|
1791
|
+
text: {
|
|
1792
|
+
name: '編輯明細',
|
|
1793
|
+
},
|
|
1794
|
+
event: gvc.event(() => {
|
|
1795
|
+
OrderModule.editOrderLineItems(gvc, structuredClone(orderData), () => {
|
|
1796
|
+
gvc.notifyDataChange(vm.id);
|
|
1797
|
+
});
|
|
1798
|
+
}),
|
|
1799
|
+
})}
|
|
1800
|
+
</div>
|
|
1785
1801
|
${BgWidget.horizontalLine()}
|
|
1786
1802
|
<div class="d-flex flex-column">
|
|
1787
1803
|
${orderData.orderData.lineItems
|
|
@@ -1791,11 +1807,7 @@ export class ShoppingOrderManager {
|
|
|
1791
1807
|
view: () => {
|
|
1792
1808
|
function showTag(color, text) {
|
|
1793
1809
|
return html `
|
|
1794
|
-
<div
|
|
1795
|
-
style="background:${color};display: flex;height: 22px;padding: 4px 6px;justify-content: center;align-items: center;gap: 10px;border-radius: 7px;font-size: 14px;font-style: normal;font-weight: 400;white-space: nowrap;"
|
|
1796
|
-
>
|
|
1797
|
-
${text}
|
|
1798
|
-
</div>
|
|
1810
|
+
<div class="product-show-tag" style="background:${color};">${text}</div>
|
|
1799
1811
|
`;
|
|
1800
1812
|
}
|
|
1801
1813
|
return html ` <div
|
|
@@ -2148,7 +2160,7 @@ export class ShoppingOrderManager {
|
|
|
2148
2160
|
(() => {
|
|
2149
2161
|
var _a, _b;
|
|
2150
2162
|
if (orderData.orderData.customer_info.payment_select === 'ecPay') {
|
|
2151
|
-
const cash_flow =
|
|
2163
|
+
const cash_flow = orderData.orderData.cash_flow || {};
|
|
2152
2164
|
return html ` <div
|
|
2153
2165
|
style="display: flex;flex-direction: column;align-items: flex-start;gap: 12px;align-self: stretch;"
|
|
2154
2166
|
>
|
|
@@ -2230,7 +2242,7 @@ export class ShoppingOrderManager {
|
|
|
2230
2242
|
</div>`;
|
|
2231
2243
|
}
|
|
2232
2244
|
else if (orderData.orderData.customer_info.payment_select === 'paynow') {
|
|
2233
|
-
const cash_flow =
|
|
2245
|
+
const cash_flow = orderData.orderData.cash_flow || {};
|
|
2234
2246
|
return html `
|
|
2235
2247
|
<div
|
|
2236
2248
|
style="display: flex;flex-direction: column;align-items: flex-start;gap: 12px;align-self: stretch;"
|
|
@@ -1428,7 +1428,7 @@ export class ShoppingOrderManager {
|
|
|
1428
1428
|
BgWidget.editeInput({
|
|
1429
1429
|
gvc: gvc,
|
|
1430
1430
|
title: '出貨單號碼',
|
|
1431
|
-
default:
|
|
1431
|
+
default: `${shipnumber ?? ''}`,
|
|
1432
1432
|
callback: text => {
|
|
1433
1433
|
shipnumber = text;
|
|
1434
1434
|
},
|
|
@@ -1978,7 +1978,23 @@ export class ShoppingOrderManager {
|
|
|
1978
1978
|
})}
|
|
1979
1979
|
</div>
|
|
1980
1980
|
</div>
|
|
1981
|
-
<div class="
|
|
1981
|
+
<div class="d-flex align-items-center justify-content-between mt-3 mb-2">
|
|
1982
|
+
<div class="tx_700">訂單明細</div>
|
|
1983
|
+
${BgWidget.customButton({
|
|
1984
|
+
button: {
|
|
1985
|
+
color: 'gray',
|
|
1986
|
+
size: 'sm',
|
|
1987
|
+
},
|
|
1988
|
+
text: {
|
|
1989
|
+
name: '編輯明細',
|
|
1990
|
+
},
|
|
1991
|
+
event: gvc.event(() => {
|
|
1992
|
+
OrderModule.editOrderLineItems(gvc, structuredClone(orderData), () => {
|
|
1993
|
+
gvc.notifyDataChange(vm.id);
|
|
1994
|
+
});
|
|
1995
|
+
}),
|
|
1996
|
+
})}
|
|
1997
|
+
</div>
|
|
1982
1998
|
${BgWidget.horizontalLine()}
|
|
1983
1999
|
<div class="d-flex flex-column">
|
|
1984
2000
|
${orderData.orderData.lineItems
|
|
@@ -1988,11 +2004,7 @@ export class ShoppingOrderManager {
|
|
|
1988
2004
|
view: () => {
|
|
1989
2005
|
function showTag(color: string, text: string) {
|
|
1990
2006
|
return html`
|
|
1991
|
-
<div
|
|
1992
|
-
style="background:${color};display: flex;height: 22px;padding: 4px 6px;justify-content: center;align-items: center;gap: 10px;border-radius: 7px;font-size: 14px;font-style: normal;font-weight: 400;white-space: nowrap;"
|
|
1993
|
-
>
|
|
1994
|
-
${text}
|
|
1995
|
-
</div>
|
|
2007
|
+
<div class="product-show-tag" style="background:${color};">${text}</div>
|
|
1996
2008
|
`;
|
|
1997
2009
|
}
|
|
1998
2010
|
|
|
@@ -2352,7 +2364,7 @@ export class ShoppingOrderManager {
|
|
|
2352
2364
|
</div>`,
|
|
2353
2365
|
(() => {
|
|
2354
2366
|
if (orderData.orderData.customer_info.payment_select === 'ecPay') {
|
|
2355
|
-
const cash_flow =
|
|
2367
|
+
const cash_flow = orderData.orderData.cash_flow || {};
|
|
2356
2368
|
return html` <div
|
|
2357
2369
|
style="display: flex;flex-direction: column;align-items: flex-start;gap: 12px;align-self: stretch;"
|
|
2358
2370
|
>
|
|
@@ -2438,7 +2450,7 @@ export class ShoppingOrderManager {
|
|
|
2438
2450
|
</div>
|
|
2439
2451
|
</div>`;
|
|
2440
2452
|
} else if (orderData.orderData.customer_info.payment_select === 'paynow') {
|
|
2441
|
-
const cash_flow =
|
|
2453
|
+
const cash_flow = orderData.orderData.cash_flow || {};
|
|
2442
2454
|
return html`
|
|
2443
2455
|
<div
|
|
2444
2456
|
style="display: flex;flex-direction: column;align-items: flex-start;gap: 12px;align-self: stretch;"
|
package/lowcode/css/editor.css
CHANGED
|
@@ -1040,6 +1040,20 @@ h6 {
|
|
|
1040
1040
|
margin: 0 0.25rem;
|
|
1041
1041
|
}
|
|
1042
1042
|
|
|
1043
|
+
.product-show-tag {
|
|
1044
|
+
display: flex;
|
|
1045
|
+
height: 22px;
|
|
1046
|
+
padding: 4px 6px;
|
|
1047
|
+
justify-content: center;
|
|
1048
|
+
align-items: center;
|
|
1049
|
+
gap: 10px;
|
|
1050
|
+
border-radius: 7px;
|
|
1051
|
+
font-size: 14px;
|
|
1052
|
+
font-style: normal;
|
|
1053
|
+
font-weight: 400;
|
|
1054
|
+
white-space: nowrap;
|
|
1055
|
+
}
|
|
1056
|
+
|
|
1043
1057
|
/* insignia fill */
|
|
1044
1058
|
|
|
1045
1059
|
.insignia {
|
package/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai-points.js","sourceRoot":"","sources":["ai-points.ts"],"names":[],"mappings":";;;;AAAA,sDAA8B;AAC9B,oDAA4B;AAC5B,sEAA8C;AAC9C,wEAAgD;AAChD,4EAA2C;AAC3C,gEAAyD;AACzD,wEAAkE;AAClE,2EAAgE;AAChE,4DAAqD;AACrD,6DAAoD;AACpD,uDAA+C;AAE/C,MAAM,MAAM,GAAmB,iBAAO,CAAC,MAAM,EAAE,CAAC;AAIhD,MAAM,CAAC,GAAG,CAAC,GAAG,EAAE,KAAK,EAAE,GAAoB,EAAE,IAAsB,EAAE,EAAE;IACnE,IAAI
|
|
1
|
+
{"version":3,"file":"ai-points.js","sourceRoot":"","sources":["ai-points.ts"],"names":[],"mappings":";;;;AAAA,sDAA8B;AAC9B,oDAA4B;AAC5B,sEAA8C;AAC9C,wEAAgD;AAChD,4EAA2C;AAC3C,gEAAyD;AACzD,wEAAkE;AAClE,2EAAgE;AAChE,4DAAqD;AACrD,6DAAoD;AACpD,uDAA+C;AAE/C,MAAM,MAAM,GAAmB,iBAAO,CAAC,MAAM,EAAE,CAAC;AAIhD,MAAM,C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