@pmcretail/mapper-library 0.0.49 → 0.0.52

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.
Files changed (32) hide show
  1. package/README.md +24 -24
  2. package/bundles/pmcretail-mapper-library.umd.js +4379 -4373
  3. package/bundles/pmcretail-mapper-library.umd.js.map +1 -1
  4. package/esm2015/lib/RJ-mapper.class.js +877 -877
  5. package/esm2015/lib/TransactionDocumentBuilder.js +1244 -1244
  6. package/esm2015/lib/WebReturn-mapper.class.js +326 -326
  7. package/esm2015/lib/WebReturnMagento2RestV1.class.js +275 -269
  8. package/esm2015/lib/WebReturnSalesforceMapper.class.js +409 -409
  9. package/esm2015/lib/basket.service.js +527 -527
  10. package/esm2015/lib/mapper-library.component.js +26 -26
  11. package/esm2015/lib/mapper-library.model.js +41 -41
  12. package/esm2015/lib/mapper-library.module.js +21 -21
  13. package/esm2015/lib/number-util.service.js +42 -42
  14. package/esm2015/pmcretail-mapper-library.js +4 -4
  15. package/esm2015/public-api.js +10 -10
  16. package/fesm2015/pmcretail-mapper-library.js +3743 -3737
  17. package/fesm2015/pmcretail-mapper-library.js.map +1 -1
  18. package/lib/RJ-mapper.class.d.ts +80 -80
  19. package/lib/TransactionDocumentBuilder.d.ts +271 -271
  20. package/lib/WebReturn-mapper.class.d.ts +27 -27
  21. package/lib/WebReturnMagento2RestV1.class.d.ts +30 -30
  22. package/lib/WebReturnMagento2RestV1.class.d.ts.map +1 -1
  23. package/lib/WebReturnSalesforceMapper.class.d.ts +35 -35
  24. package/lib/basket.service.d.ts +105 -105
  25. package/lib/mapper-library.component.d.ts +8 -8
  26. package/lib/mapper-library.model.d.ts +702 -701
  27. package/lib/mapper-library.model.d.ts.map +1 -1
  28. package/lib/mapper-library.module.d.ts +7 -7
  29. package/lib/number-util.service.d.ts +13 -13
  30. package/package.json +2 -2
  31. package/pmcretail-mapper-library.d.ts +5 -5
  32. package/public-api.d.ts +6 -6
@@ -1,702 +1,703 @@
1
- export declare enum TRANSACTION_TYPE {
2
- SALE = "SALE",
3
- REFUND = "REFUND",
4
- SALE_REFUND = "SALE_REFUND",
5
- SALE_EXCHANGE = "SALE_EXCHANGE",
6
- VOID = "VOID",
7
- WEB_RETURNS = "WEB_RETURNS"
8
- }
9
- export interface ItemDiscount {
10
- trnDiscountsPortion: number;
11
- trnPromotionsPortion: number;
12
- refundPortion: number;
13
- currentRefundPortion?: number;
14
- }
15
- export declare enum DELIVERY_METHODS {
16
- DELIVERY = 1,
17
- DROP_SHIP = 2,
18
- COLLECT_FROM_STORE = 3,
19
- SHIP_TO_STORE = 4
20
- }
21
- export interface ProductChange {
22
- itemLineId?: number;
23
- SKU: string;
24
- quantity: number;
25
- selectedPrice?: number;
26
- lineDiscount?: LineDiscount;
27
- linePromotions?: LinePromotions;
28
- exchange?: Exchange;
29
- refundedQuantity?: number;
30
- refundPromotionalQuantity?: number;
31
- refunded?: boolean;
32
- refundedTotal?: number;
33
- refundedReason?: string;
34
- refundedReasonDescription?: string;
35
- isChecked?: boolean;
36
- sealed?: boolean;
37
- isLastExchanged?: boolean;
38
- }
39
- /**
40
- * Product
41
- */
42
- export interface Product extends ProductChange {
43
- itemLineId?: number;
44
- status: number;
45
- subGroup: number;
46
- brand: string;
47
- currency: string;
48
- category: string;
49
- countryofOrigin: string;
50
- productId: string;
51
- productType: number;
52
- name?: string;
53
- imageUrls: [string];
54
- isImageFailToLoad?: boolean;
55
- size: string;
56
- type: string;
57
- season: number;
58
- productGroup: number;
59
- styleCode: string;
60
- nodeStructure: NodeStructure[];
61
- barcode: string;
62
- price: Price[];
63
- colour: string;
64
- description: string;
65
- totalLinePrice: number;
66
- total: number;
67
- addedInBasket?: boolean;
68
- selectedVAT?: number;
69
- selectedVATCode?: string;
70
- selectedRRPPrice?: number;
71
- lineDiscount?: LineDiscount;
72
- exchange?: Exchange;
73
- refundPromotionalQuantity?: number;
74
- exchangeReason?: string;
75
- exchangeQuantity?: number;
76
- itemDiscounts: ItemDiscount;
77
- giftCardNumberIssued?: string;
78
- giftCardAmount?: number;
79
- giftCardRecipientEmail?: string;
80
- giftCardExpiryDate?: string;
81
- giftCardRecipientName?: string;
82
- giftCard?: boolean;
83
- discountable: boolean;
84
- excludePromotion: boolean;
85
- categories: Categories[];
86
- descriptions: Descriptions[];
87
- barcodes: string[];
88
- externalId: string;
89
- createdDate: string;
90
- updatedDate: string;
91
- createdBy: string;
92
- updatedBy: string;
93
- attributes: CoreAttribute[];
94
- id: string;
95
- long_description: string;
96
- isWebOrder?: boolean;
97
- fullfilmentId: string;
98
- fullfilmentLocationName?: string;
99
- deliveryMethod?: string;
100
- deliveryGroup?: string;
101
- selectedInventory?: InventoryInfo;
102
- leadTime?: leadTime;
103
- }
104
- export interface leadTime {
105
- type: string;
106
- value: string;
107
- }
108
- export interface Exchange {
109
- exchangeId: number;
110
- lineItemId: number;
111
- reason: string;
112
- quantity: number;
113
- newItems: Product[];
114
- }
115
- export interface Categories {
116
- id: string;
117
- parentId: string;
118
- name: string;
119
- categoryId: string;
120
- status: boolean;
121
- }
122
- export interface Descriptions {
123
- name: string;
124
- countryCode: string;
125
- value: string;
126
- }
127
- export interface CoreAttribute {
128
- name: string;
129
- value: string;
130
- searchable: boolean;
131
- countryCode: string;
132
- }
133
- /**
134
- * Basket
135
- */
136
- export interface Basket {
137
- subsidiaryId?: string;
138
- products: Product[];
139
- transactionDiscount: any[];
140
- quantity: number;
141
- total: number;
142
- saleTotal: number;
143
- discountTotal?: number;
144
- transactionId?: string;
145
- offlineTransactionId?: string;
146
- baseCurrency: string;
147
- basketTotal?: number;
148
- refundTotal?: number;
149
- transactionPromotion?: TransactionPromotion[];
150
- customer?: any;
151
- exchange?: Exchange[];
152
- inStoreFlag?: boolean;
153
- }
154
- /**
155
- * Price
156
- */
157
- export interface Price {
158
- VAT: number;
159
- VATCode: string;
160
- salesPrice: number;
161
- currencyCode: string;
162
- RRPPrice: number;
163
- }
164
- /**
165
- * Node structure
166
- */
167
- interface NodeStructure {
168
- status: boolean;
169
- name: string;
170
- nodeType: string;
171
- isOverride: boolean;
172
- nodeId: string;
173
- parentId: string;
174
- }
175
- /**
176
- * Line Discount
177
- */
178
- export interface LineDiscount {
179
- itemLineId: string;
180
- discountAmount: number;
181
- discountType: string;
182
- name?: string;
183
- unitPrice: number;
184
- discountedLinePrice?: number;
185
- priceManagerOverride?: UserOverride;
186
- priceOverrideReasonCode?: string;
187
- priceOverrideReasonName?: string;
188
- priceOverrideAmount?: number;
189
- percentageDiscountManagerOverride?: UserOverride;
190
- percentageDiscountReasonCode?: string;
191
- percentageDiscountReasonName?: string;
192
- percentageDiscountValue?: number;
193
- }
194
- /**
195
- * User Override
196
- */
197
- export interface UserOverride {
198
- userId: string;
199
- automaticApprove: string;
200
- originalUserId: string;
201
- }
202
- /**
203
- * line Promotions
204
- */
205
- export interface LinePromotions {
206
- trigger: Trigger[];
207
- itemLineId: number;
208
- promotionId: string;
209
- displayText: string;
210
- promotionType: string;
211
- promotionAmount: number;
212
- name: string;
213
- promotionInfo: string;
214
- promotionLinePrice: number;
215
- refunded?: boolean;
216
- }
217
- /**
218
- * trigger
219
- */
220
- export interface Trigger {
221
- itemLineId: string;
222
- quantity?: number;
223
- totalQuantity?: number;
224
- linePromotionAmount?: number;
225
- promotionAmount?: number;
226
- refundedReason?: string;
227
- refundedReasonDescription?: string;
228
- promotionId?: string;
229
- }
230
- /**
231
- * Transaction Promotion
232
- */
233
- export interface TransactionPromotion {
234
- displayText: string;
235
- name: string;
236
- promotionAmount: number;
237
- promotionId: string;
238
- promotionInfo: string;
239
- promotionType: string;
240
- itemLineIds: number[];
241
- type?: string;
242
- subLevelType?: PROMOTION_LEVEL;
243
- trigger?: Trigger[];
244
- couponCode?: string;
245
- }
246
- export interface RefundProductChange {
247
- itemLineId?: number;
248
- refundedQuantity?: number;
249
- refundedPromotionalQuantity?: number;
250
- refundTotal?: number;
251
- refundedReason?: string;
252
- refundedReasonDescription?: string;
253
- refundWithPromotion: boolean;
254
- isLastExchanged?: boolean;
255
- }
256
- export interface InventoryInfo {
257
- storeName: string;
258
- storeId: string;
259
- quantityAvailable: number;
260
- quantityRequired: number;
261
- }
262
- export interface InventoryRequestInfo extends InventoryInfo {
263
- requestedQuantity: number;
264
- requestedAction: DELIVERY_METHODS;
265
- }
266
- export interface DeliveryInfo {
267
- groups: DeliveryGroupInfo[];
268
- }
269
- export interface DeliveryGroupInfo {
270
- groupNumber: number;
271
- items: Product[];
272
- estimate?: Estimate;
273
- }
274
- export interface Estimate {
275
- type: string;
276
- value: string;
277
- }
278
- export interface TransactionDocument {
279
- transactionId?: string;
280
- subsidiaryId?: string;
281
- offlineTransactionId?: string;
282
- transactionRef?: string;
283
- dateTime?: string;
284
- orgCode: string;
285
- storeId: string;
286
- storeNodeId: string;
287
- storeNodeStructure: string;
288
- deviceId: string;
289
- terminalId: string;
290
- initiatingModule: string;
291
- export: boolean;
292
- userId?: string;
293
- userName?: string;
294
- customer?: Customer;
295
- basket: any;
296
- basketSummary: BasketSummary;
297
- baseCurrency: string;
298
- splitPayment?: boolean;
299
- isPaymentCompleted?: boolean;
300
- paymentDetails?: any;
301
- type?: string;
302
- operationStatus?: string;
303
- createdAt?: string;
304
- updatedAt?: string;
305
- transCompletedAt?: string;
306
- id?: string;
307
- saleTotal?: number;
308
- reasonCode?: string;
309
- reasonDescription?: string;
310
- override?: UserOverride;
311
- originalTransId?: string;
312
- originalExternalId?: string;
313
- apiResponse?: APIResponse;
314
- unreferencedRefund?: boolean;
315
- giftedReceipt?: boolean;
316
- currentTransactionDetails?: any;
317
- isChecked?: boolean;
318
- externalTransactionDetails?: externalTransactionDetails[];
319
- refundRequest?: any[];
320
- isInStoreOrder?: boolean;
321
- }
322
- export interface APIResponse {
323
- internalId?: number;
324
- tranid?: string;
325
- }
326
- export interface CurrentTransactionDetails {
327
- products: Product[];
328
- lineDiscount?: LineDiscount[];
329
- linePromotion?: LinePromotions[];
330
- transactionPromotion?: TransactionPromotion[];
331
- transactionDiscount?: TransactionDiscount[];
332
- basketSummary?: BasketSummary;
333
- taxBreakdown?: TaxBreakdown;
334
- totalTaxSummary?: TotalTaxSummary[];
335
- }
336
- export interface BasketSummary {
337
- totalItems?: number;
338
- saleTotal?: number;
339
- VATTotal?: number;
340
- discountTotal?: number;
341
- basketTotal?: number;
342
- refundTotal?: number;
343
- shippingTotal?: number;
344
- basketTotalWithShippingTotal?: number;
345
- inStore?: BasketSummaryDetails;
346
- webOrder?: BasketSummaryDetails;
347
- cnc?: BasketSummaryDetails;
348
- }
349
- export interface BasketSummaryDetails {
350
- totalItems?: number;
351
- saleTotal?: number;
352
- VATTotal?: number;
353
- discountTotal?: number;
354
- basketTotal?: number;
355
- refundTotal?: number;
356
- shippingTotal?: number;
357
- basketTotalWithShippingTotal?: number;
358
- }
359
- export interface TransactionDiscount {
360
- discountAmount: number;
361
- discountType: String;
362
- reasonCode: string;
363
- override?: UserOverride;
364
- itemLineIds?: number[];
365
- }
366
- export interface TBasket {
367
- products: TProduct[];
368
- lineDiscount: LineDiscount[];
369
- exchange: Exchange[];
370
- linePromotion: LinePromotions[];
371
- transactionPromotion?: TransactionPromotion[];
372
- transactionDiscount?: TransactionDiscount[];
373
- taxBreakdown?: TaxBreakdown;
374
- totalTaxSummary?: TotalTaxSummary[];
375
- }
376
- export interface TExchange {
377
- exchangeId?: number;
378
- lineItemId?: number;
379
- reason?: string;
380
- quantity?: number;
381
- newItems?: TNewItems[];
382
- }
383
- export interface TNewItems {
384
- lineItemId: number;
385
- Quantity: number;
386
- }
387
- export interface TProduct {
388
- itemLineId: string;
389
- SKU: string;
390
- description: string;
391
- imageUrls: [string];
392
- price: number;
393
- taxCode?: string;
394
- taxPercent?: string;
395
- quantity: number;
396
- refundedQuantity?: number;
397
- refundedPromotionalQuantity?: number;
398
- refunded?: boolean;
399
- refundedTotal?: number;
400
- refundedReason?: string;
401
- refundedReasonDescription?: string;
402
- selectedRRPPrice?: number;
403
- totalLinePrice: number;
404
- barCode?: string;
405
- barcodes?: string[];
406
- flagged?: boolean;
407
- exchange?: Exchange;
408
- excludePromotion: boolean;
409
- discountable?: boolean;
410
- itemDiscounts?: ItemDiscounts;
411
- isLastExchanged?: boolean;
412
- fullfilmentId: string;
413
- fullfilmentLocationName: string;
414
- deliveryMethod?: string;
415
- deliveryGroup?: string;
416
- giftCardNumberIssued?: string;
417
- giftCardAmount?: number;
418
- giftCardRecipientEmail?: string;
419
- giftCardExpiryDate?: string;
420
- giftCardRecipientName?: string;
421
- giftCard?: boolean;
422
- currency?: string;
423
- isWebOrder?: boolean;
424
- leadTime?: leadTime;
425
- lineDiscount?: any;
426
- attributes?: CoreAttribute[];
427
- }
428
- export interface ItemDiscounts {
429
- trnDiscountsPortion: number;
430
- trnPromotionsPortion: number;
431
- refundPortion: number;
432
- }
433
- export interface Customer {
434
- id: string;
435
- title?: string;
436
- firstName: string;
437
- lastName: string;
438
- email: string;
439
- postCode: string;
440
- telephone?: string;
441
- billingAddress?: Address | Address[] | any;
442
- shippingAddress?: Address | Address[] | any;
443
- shipmentDetails?: ShipmentDetails[];
444
- addressDetail?: string;
445
- noCustomerSelected?: boolean;
446
- externalId?: string;
447
- }
448
- export interface Address {
449
- id?: string;
450
- countryCode?: string;
451
- address1?: string;
452
- address2?: string;
453
- address3?: string;
454
- city?: string;
455
- county?: string;
456
- postCode?: string;
457
- country?: string;
458
- }
459
- export interface ShipmentDetails {
460
- id?: string;
461
- deliveryGroup?: string;
462
- }
463
- export interface PaymentDetails {
464
- cardNumber?: any;
465
- sqNo?: number;
466
- result?: string;
467
- currency: string;
468
- amount: string;
469
- authcode?: string;
470
- pan?: string;
471
- cardType?: string;
472
- transactionDate?: string;
473
- mid?: string;
474
- tid?: string;
475
- cvm?: string;
476
- hostReferenceId?: string;
477
- aid?: string;
478
- receiptNo?: string;
479
- expirydate?: string;
480
- transactionReference: string;
481
- applicationVersion?: string;
482
- entryMethod?: string;
483
- transactionType: string;
484
- totalamount: string;
485
- paymentType?: string;
486
- }
487
- export interface TaxBreakdown {
488
- taxLines: TaxLine[];
489
- totalTaxableAmount: number;
490
- }
491
- export interface TotalTaxSummary {
492
- VATCode: string;
493
- VAT: number;
494
- PreTaxSum: number;
495
- TaxSum: number;
496
- TXrateSum: number;
497
- }
498
- export interface TaxLine {
499
- itemLineId: number;
500
- taxableAmount: number;
501
- taxLineTotal: number;
502
- VAT: number;
503
- VATCode: string;
504
- PreTax: number;
505
- }
506
- export declare enum DISCOUNTTYPE {
507
- PERCENT = "Percent",
508
- AMOUNT = "AMOUNT"
509
- }
510
- export interface TransactionInfo {
511
- shippingId?: string;
512
- externalShippingId?: string;
513
- invoiceId?: string;
514
- }
515
- export interface Coupons {
516
- name?: string;
517
- id?: string;
518
- }
519
- export interface externalTransactionDetails {
520
- uniqueId?: string;
521
- providerType?: string;
522
- details?: TransactionInfo;
523
- coupons?: Coupons[];
524
- }
525
- export declare enum INITIATING_MODULE {
526
- EBASKET = "eBasket"
527
- }
528
- export interface pendingMethod {
529
- _type?: string;
530
- type?: string;
531
- message?: string;
532
- path?: string;
533
- details?: ShipmentId;
534
- }
535
- export interface ShipmentId {
536
- shipmentId?: string;
537
- }
538
- export interface CustomerAddress {
539
- _type?: string;
540
- email?: string;
541
- address1?: string;
542
- city?: string;
543
- country_code?: string;
544
- first_name?: string;
545
- full_name?: string;
546
- id?: string;
547
- last_name?: string;
548
- phone?: string;
549
- salutation?: string;
550
- c_area?: string;
551
- c_email?: string;
552
- c_phoneWhatsApp?: string;
553
- c_strValue?: string;
554
- postal_code?: string;
555
- }
556
- export interface CustomerInfo {
557
- _type?: string;
558
- customer_id?: string;
559
- email?: string;
560
- }
561
- export interface GroupedTaxItem {
562
- _type?: string;
563
- tax_rate?: number;
564
- tax_value?: number;
565
- }
566
- export interface additionalNotes {
567
- _type?: string;
568
- link?: string;
569
- }
570
- export interface ProductItem {
571
- _type?: string;
572
- adjusted_tax?: number;
573
- base_price?: number;
574
- bonus_product_line_item?: boolean;
575
- gift?: boolean;
576
- item_id?: string;
577
- item_text?: string;
578
- price?: number;
579
- price_adjustments?: PriceAdjustment[];
580
- price_after_item_discount?: number;
581
- price_after_order_discount?: number;
582
- product_id?: string;
583
- product_name?: string;
584
- quantity?: number;
585
- shipment_id?: string;
586
- tax?: number;
587
- tax_basis?: number;
588
- tax_class_id?: string;
589
- tax_rate?: number;
590
- c_osuObjectData?: string;
591
- }
592
- export interface ShippingMethod {
593
- _type?: string;
594
- description?: string;
595
- id?: string;
596
- name?: string;
597
- price?: number;
598
- c_approachingThresholdMessage?: string;
599
- c_estimatedArrivalTime?: string;
600
- c_isEmail?: boolean;
601
- c_storePickupEnabled?: boolean;
602
- c_thresholdValue?: number;
603
- }
604
- export interface shipment {
605
- _type?: string;
606
- adjusted_merchandize_total_tax?: number;
607
- adjusted_shipping_total_tax?: number;
608
- gift?: boolean;
609
- merchandize_total_tax?: number;
610
- product_sub_total?: number;
611
- product_total?: number;
612
- shipment_id?: string;
613
- shipment_total?: number;
614
- shipping_address?: CustomerAddress;
615
- shipping_method?: ShippingMethod;
616
- shipping_status?: string;
617
- shipping_total?: number;
618
- shipping_total_tax?: number;
619
- tax_total?: number;
620
- c_fromStoreId?: string;
621
- }
622
- export interface ShippingItem {
623
- _type?: string;
624
- adjusted_tax?: number;
625
- base_price?: number;
626
- item_id?: string;
627
- item_text?: string;
628
- price?: number;
629
- price_after_item_discount?: number;
630
- shipment_id?: string;
631
- tax?: number;
632
- tax_basis?: number;
633
- tax_class_id?: string;
634
- tax_rate?: number;
635
- }
636
- export interface AppliedDiscount {
637
- _type?: string;
638
- amount?: number;
639
- percentage?: number;
640
- type?: string;
641
- }
642
- export interface PriceAdjustment {
643
- _type?: string;
644
- applied_discount?: AppliedDiscount;
645
- coupon_code?: string;
646
- creation_date?: string;
647
- custom?: boolean;
648
- item_text?: string;
649
- last_modified?: string;
650
- manual?: boolean;
651
- price?: number;
652
- price_adjustment_id?: string;
653
- promotion_id?: string;
654
- promotion_link?: string;
655
- }
656
- export interface OrderDetails {
657
- _v?: string;
658
- _type?: string;
659
- _resource_state?: string;
660
- _flash?: pendingMethod[];
661
- adjusted_merchandize_total_tax?: number;
662
- adjusted_shipping_total_tax?: number;
663
- agent_basket?: boolean;
664
- basket_id?: string;
665
- billing_address?: CustomerAddress;
666
- channel_type?: string;
667
- creation_date?: string;
668
- currency?: string;
669
- customer_info?: CustomerInfo;
670
- grouped_tax_items?: GroupedTaxItem[];
671
- last_modified?: string;
672
- merchandize_total_tax?: number;
673
- notes?: additionalNotes;
674
- order_price_adjustments?: PriceAdjustment[];
675
- order_no?: string;
676
- order_total?: number;
677
- product_items?: ProductItem[];
678
- product_sub_total?: number;
679
- product_total?: number;
680
- shipments?: shipment[];
681
- shipping_items?: ShippingItem[];
682
- shipping_total?: number;
683
- shipping_total_tax?: number;
684
- taxation?: string;
685
- tax_rounded_at_group?: boolean;
686
- tax_total?: number;
687
- c_isInStoreOrder?: boolean;
688
- }
689
- export declare enum PROVIDERS {
690
- SALESFORCE = "Salesforce",
691
- MAGENTO = "Magento",
692
- MAGENTO2 = "Magento2"
693
- }
694
- export declare enum PROMOTION_LEVEL {
695
- LINE = "LINE",
696
- TRANSACTION = "TRANSACTION"
697
- }
698
- export declare enum PROMOTION_TYPE {
699
- COUPON = "COUPON"
700
- }
701
- export {};
1
+ export declare enum TRANSACTION_TYPE {
2
+ SALE = "SALE",
3
+ REFUND = "REFUND",
4
+ SALE_REFUND = "SALE_REFUND",
5
+ SALE_EXCHANGE = "SALE_EXCHANGE",
6
+ VOID = "VOID",
7
+ WEB_RETURNS = "WEB_RETURNS"
8
+ }
9
+ export interface ItemDiscount {
10
+ trnDiscountsPortion: number;
11
+ trnPromotionsPortion: number;
12
+ refundPortion: number;
13
+ currentRefundPortion?: number;
14
+ }
15
+ export declare enum DELIVERY_METHODS {
16
+ DELIVERY = 1,
17
+ DROP_SHIP = 2,
18
+ COLLECT_FROM_STORE = 3,
19
+ SHIP_TO_STORE = 4
20
+ }
21
+ export interface ProductChange {
22
+ itemLineId?: number;
23
+ SKU: string;
24
+ quantity: number;
25
+ selectedPrice?: number;
26
+ lineDiscount?: LineDiscount;
27
+ linePromotions?: LinePromotions;
28
+ exchange?: Exchange;
29
+ refundedQuantity?: number;
30
+ refundPromotionalQuantity?: number;
31
+ refunded?: boolean;
32
+ refundedTotal?: number;
33
+ refundedReason?: string;
34
+ refundedReasonDescription?: string;
35
+ isChecked?: boolean;
36
+ sealed?: boolean;
37
+ isLastExchanged?: boolean;
38
+ }
39
+ /**
40
+ * Product
41
+ */
42
+ export interface Product extends ProductChange {
43
+ itemLineId?: number;
44
+ status: number;
45
+ subGroup: number;
46
+ brand: string;
47
+ currency: string;
48
+ category: string;
49
+ countryofOrigin: string;
50
+ productId: string;
51
+ productType: number;
52
+ name?: string;
53
+ imageUrls: [string];
54
+ isImageFailToLoad?: boolean;
55
+ size: string;
56
+ type: string;
57
+ season: number;
58
+ productGroup: number;
59
+ styleCode: string;
60
+ nodeStructure: NodeStructure[];
61
+ barcode: string;
62
+ price: Price[];
63
+ colour: string;
64
+ description: string;
65
+ totalLinePrice: number;
66
+ total: number;
67
+ addedInBasket?: boolean;
68
+ selectedVAT?: number;
69
+ selectedVATCode?: string;
70
+ selectedRRPPrice?: number;
71
+ lineDiscount?: LineDiscount;
72
+ exchange?: Exchange;
73
+ refundPromotionalQuantity?: number;
74
+ exchangeReason?: string;
75
+ exchangeQuantity?: number;
76
+ itemDiscounts: ItemDiscount;
77
+ giftCardNumberIssued?: string;
78
+ giftCardAmount?: number;
79
+ giftCardRecipientEmail?: string;
80
+ giftCardExpiryDate?: string;
81
+ giftCardRecipientName?: string;
82
+ giftCard?: boolean;
83
+ discountable: boolean;
84
+ excludePromotion: boolean;
85
+ categories: Categories[];
86
+ descriptions: Descriptions[];
87
+ barcodes: string[];
88
+ externalId: string;
89
+ createdDate: string;
90
+ updatedDate: string;
91
+ createdBy: string;
92
+ updatedBy: string;
93
+ attributes: CoreAttribute[];
94
+ id: string;
95
+ long_description: string;
96
+ isWebOrder?: boolean;
97
+ fullfilmentId: string;
98
+ fullfilmentLocationName?: string;
99
+ deliveryMethod?: string;
100
+ deliveryGroup?: string;
101
+ selectedInventory?: InventoryInfo;
102
+ leadTime?: leadTime;
103
+ }
104
+ export interface leadTime {
105
+ type: string;
106
+ value: string;
107
+ }
108
+ export interface Exchange {
109
+ exchangeId: number;
110
+ lineItemId: number;
111
+ reason: string;
112
+ quantity: number;
113
+ newItems: Product[];
114
+ }
115
+ export interface Categories {
116
+ id: string;
117
+ parentId: string;
118
+ name: string;
119
+ categoryId: string;
120
+ status: boolean;
121
+ }
122
+ export interface Descriptions {
123
+ name: string;
124
+ countryCode: string;
125
+ value: string;
126
+ }
127
+ export interface CoreAttribute {
128
+ name: string;
129
+ value: string;
130
+ searchable: boolean;
131
+ countryCode: string;
132
+ }
133
+ /**
134
+ * Basket
135
+ */
136
+ export interface Basket {
137
+ subsidiaryId?: string;
138
+ products: Product[];
139
+ transactionDiscount: any[];
140
+ quantity: number;
141
+ total: number;
142
+ saleTotal: number;
143
+ discountTotal?: number;
144
+ transactionId?: string;
145
+ offlineTransactionId?: string;
146
+ baseCurrency: string;
147
+ basketTotal?: number;
148
+ refundTotal?: number;
149
+ transactionPromotion?: TransactionPromotion[];
150
+ customer?: any;
151
+ exchange?: Exchange[];
152
+ inStoreFlag?: boolean;
153
+ }
154
+ /**
155
+ * Price
156
+ */
157
+ export interface Price {
158
+ VAT: number;
159
+ VATCode: string;
160
+ salesPrice: number;
161
+ currencyCode: string;
162
+ RRPPrice: number;
163
+ }
164
+ /**
165
+ * Node structure
166
+ */
167
+ interface NodeStructure {
168
+ status: boolean;
169
+ name: string;
170
+ nodeType: string;
171
+ isOverride: boolean;
172
+ nodeId: string;
173
+ parentId: string;
174
+ }
175
+ /**
176
+ * Line Discount
177
+ */
178
+ export interface LineDiscount {
179
+ itemLineId: string;
180
+ discountAmount: number;
181
+ discountType: string;
182
+ name?: string;
183
+ unitPrice: number;
184
+ discountedLinePrice?: number;
185
+ priceManagerOverride?: UserOverride;
186
+ priceOverrideReasonCode?: string;
187
+ priceOverrideReasonName?: string;
188
+ priceOverrideAmount?: number;
189
+ percentageDiscountManagerOverride?: UserOverride;
190
+ percentageDiscountReasonCode?: string;
191
+ percentageDiscountReasonName?: string;
192
+ percentageDiscountValue?: number;
193
+ }
194
+ /**
195
+ * User Override
196
+ */
197
+ export interface UserOverride {
198
+ userId: string;
199
+ automaticApprove: string;
200
+ originalUserId: string;
201
+ }
202
+ /**
203
+ * line Promotions
204
+ */
205
+ export interface LinePromotions {
206
+ trigger: Trigger[];
207
+ itemLineId: number;
208
+ promotionId: string;
209
+ displayText: string;
210
+ promotionType: string;
211
+ promotionAmount: number;
212
+ name: string;
213
+ promotionInfo: string;
214
+ promotionLinePrice: number;
215
+ refunded?: boolean;
216
+ }
217
+ /**
218
+ * trigger
219
+ */
220
+ export interface Trigger {
221
+ itemLineId: string;
222
+ quantity?: number;
223
+ totalQuantity?: number;
224
+ linePromotionAmount?: number;
225
+ promotionAmount?: number;
226
+ refundedReason?: string;
227
+ refundedReasonDescription?: string;
228
+ promotionId?: string;
229
+ }
230
+ /**
231
+ * Transaction Promotion
232
+ */
233
+ export interface TransactionPromotion {
234
+ displayText: string;
235
+ name: string;
236
+ promotionAmount: number;
237
+ promotionId: string;
238
+ promotionInfo: string;
239
+ promotionType: string;
240
+ itemLineIds: number[];
241
+ type?: string;
242
+ subLevelType?: PROMOTION_LEVEL;
243
+ trigger?: Trigger[];
244
+ couponCode?: string;
245
+ }
246
+ export interface RefundProductChange {
247
+ itemLineId?: number;
248
+ refundedQuantity?: number;
249
+ refundedPromotionalQuantity?: number;
250
+ refundTotal?: number;
251
+ refundedReason?: string;
252
+ refundedReasonDescription?: string;
253
+ refundWithPromotion: boolean;
254
+ isLastExchanged?: boolean;
255
+ }
256
+ export interface InventoryInfo {
257
+ storeName: string;
258
+ storeId: string;
259
+ quantityAvailable: number;
260
+ quantityRequired: number;
261
+ }
262
+ export interface InventoryRequestInfo extends InventoryInfo {
263
+ requestedQuantity: number;
264
+ requestedAction: DELIVERY_METHODS;
265
+ }
266
+ export interface DeliveryInfo {
267
+ groups: DeliveryGroupInfo[];
268
+ }
269
+ export interface DeliveryGroupInfo {
270
+ groupNumber: number;
271
+ items: Product[];
272
+ estimate?: Estimate;
273
+ }
274
+ export interface Estimate {
275
+ type: string;
276
+ value: string;
277
+ }
278
+ export interface TransactionDocument {
279
+ transactionId?: string;
280
+ subsidiaryId?: string;
281
+ offlineTransactionId?: string;
282
+ transactionRef?: string;
283
+ dateTime?: string;
284
+ orgCode: string;
285
+ storeId: string;
286
+ storeNodeId: string;
287
+ storeNodeStructure: string;
288
+ deviceId: string;
289
+ terminalId: string;
290
+ initiatingModule: string;
291
+ export: boolean;
292
+ userId?: string;
293
+ userName?: string;
294
+ customer?: Customer;
295
+ basket: any;
296
+ basketSummary: BasketSummary;
297
+ baseCurrency: string;
298
+ splitPayment?: boolean;
299
+ isPaymentCompleted?: boolean;
300
+ paymentDetails?: any;
301
+ type?: string;
302
+ operationStatus?: string;
303
+ createdAt?: string;
304
+ updatedAt?: string;
305
+ transCompletedAt?: string;
306
+ id?: string;
307
+ saleTotal?: number;
308
+ reasonCode?: string;
309
+ reasonDescription?: string;
310
+ override?: UserOverride;
311
+ originalTransId?: string;
312
+ originalExternalId?: string;
313
+ apiResponse?: APIResponse;
314
+ unreferencedRefund?: boolean;
315
+ giftedReceipt?: boolean;
316
+ currentTransactionDetails?: any;
317
+ isChecked?: boolean;
318
+ externalTransactionDetails?: externalTransactionDetails[];
319
+ refundRequest?: any[];
320
+ isInStoreOrder?: boolean;
321
+ }
322
+ export interface APIResponse {
323
+ internalId?: number;
324
+ tranid?: string;
325
+ }
326
+ export interface CurrentTransactionDetails {
327
+ products: Product[];
328
+ lineDiscount?: LineDiscount[];
329
+ linePromotion?: LinePromotions[];
330
+ transactionPromotion?: TransactionPromotion[];
331
+ transactionDiscount?: TransactionDiscount[];
332
+ basketSummary?: BasketSummary;
333
+ taxBreakdown?: TaxBreakdown;
334
+ totalTaxSummary?: TotalTaxSummary[];
335
+ }
336
+ export interface BasketSummary {
337
+ totalItems?: number;
338
+ saleTotal?: number;
339
+ VATTotal?: number;
340
+ discountTotal?: number;
341
+ basketTotal?: number;
342
+ refundTotal?: number;
343
+ shippingTotal?: number;
344
+ basketTotalWithShippingTotal?: number;
345
+ inStore?: BasketSummaryDetails;
346
+ webOrder?: BasketSummaryDetails;
347
+ cnc?: BasketSummaryDetails;
348
+ }
349
+ export interface BasketSummaryDetails {
350
+ totalItems?: number;
351
+ saleTotal?: number;
352
+ VATTotal?: number;
353
+ discountTotal?: number;
354
+ basketTotal?: number;
355
+ refundTotal?: number;
356
+ shippingTotal?: number;
357
+ basketTotalWithShippingTotal?: number;
358
+ }
359
+ export interface TransactionDiscount {
360
+ discountAmount: number;
361
+ discountType: String;
362
+ reasonCode: string;
363
+ override?: UserOverride;
364
+ itemLineIds?: number[];
365
+ }
366
+ export interface TBasket {
367
+ products: TProduct[];
368
+ lineDiscount: LineDiscount[];
369
+ exchange: Exchange[];
370
+ linePromotion: LinePromotions[];
371
+ transactionPromotion?: TransactionPromotion[];
372
+ transactionDiscount?: TransactionDiscount[];
373
+ taxBreakdown?: TaxBreakdown;
374
+ totalTaxSummary?: TotalTaxSummary[];
375
+ }
376
+ export interface TExchange {
377
+ exchangeId?: number;
378
+ lineItemId?: number;
379
+ reason?: string;
380
+ quantity?: number;
381
+ newItems?: TNewItems[];
382
+ }
383
+ export interface TNewItems {
384
+ lineItemId: number;
385
+ Quantity: number;
386
+ }
387
+ export interface TProduct {
388
+ itemLineId: string;
389
+ SKU: string;
390
+ description: string;
391
+ imageUrls: [string];
392
+ price: number;
393
+ taxCode?: string;
394
+ taxPercent?: string;
395
+ quantity: number;
396
+ refundedQuantity?: number;
397
+ refundedPromotionalQuantity?: number;
398
+ refunded?: boolean;
399
+ refundedTotal?: number;
400
+ refundedReason?: string;
401
+ refundedReasonDescription?: string;
402
+ selectedRRPPrice?: number;
403
+ totalLinePrice: number;
404
+ barCode?: string;
405
+ barcodes?: string[];
406
+ flagged?: boolean;
407
+ exchange?: Exchange;
408
+ excludePromotion: boolean;
409
+ discountable?: boolean;
410
+ itemDiscounts?: ItemDiscounts;
411
+ isLastExchanged?: boolean;
412
+ fullfilmentId: string;
413
+ fullfilmentLocationName: string;
414
+ deliveryMethod?: string;
415
+ deliveryGroup?: string;
416
+ giftCardNumberIssued?: string;
417
+ giftCardAmount?: number;
418
+ giftCardRecipientEmail?: string;
419
+ giftCardExpiryDate?: string;
420
+ giftCardRecipientName?: string;
421
+ giftCard?: boolean;
422
+ currency?: string;
423
+ isWebOrder?: boolean;
424
+ leadTime?: leadTime;
425
+ lineDiscount?: any;
426
+ attributes?: CoreAttribute[];
427
+ }
428
+ export interface ItemDiscounts {
429
+ trnDiscountsPortion: number;
430
+ trnPromotionsPortion: number;
431
+ refundPortion: number;
432
+ }
433
+ export interface Customer {
434
+ id: string;
435
+ customerId?: string;
436
+ title?: string;
437
+ firstName: string;
438
+ lastName: string;
439
+ email: string;
440
+ postCode: string;
441
+ telephone?: string;
442
+ billingAddress?: Address | Address[] | any;
443
+ shippingAddress?: Address | Address[] | any;
444
+ shipmentDetails?: ShipmentDetails[];
445
+ addressDetail?: string;
446
+ noCustomerSelected?: boolean;
447
+ externalId?: string;
448
+ }
449
+ export interface Address {
450
+ id?: string;
451
+ countryCode?: string;
452
+ address1?: string;
453
+ address2?: string;
454
+ address3?: string;
455
+ city?: string;
456
+ county?: string;
457
+ postCode?: string;
458
+ country?: string;
459
+ }
460
+ export interface ShipmentDetails {
461
+ id?: string;
462
+ deliveryGroup?: string;
463
+ }
464
+ export interface PaymentDetails {
465
+ cardNumber?: any;
466
+ sqNo?: number;
467
+ result?: string;
468
+ currency: string;
469
+ amount: string;
470
+ authcode?: string;
471
+ pan?: string;
472
+ cardType?: string;
473
+ transactionDate?: string;
474
+ mid?: string;
475
+ tid?: string;
476
+ cvm?: string;
477
+ hostReferenceId?: string;
478
+ aid?: string;
479
+ receiptNo?: string;
480
+ expirydate?: string;
481
+ transactionReference: string;
482
+ applicationVersion?: string;
483
+ entryMethod?: string;
484
+ transactionType: string;
485
+ totalamount: string;
486
+ paymentType?: string;
487
+ }
488
+ export interface TaxBreakdown {
489
+ taxLines: TaxLine[];
490
+ totalTaxableAmount: number;
491
+ }
492
+ export interface TotalTaxSummary {
493
+ VATCode: string;
494
+ VAT: number;
495
+ PreTaxSum: number;
496
+ TaxSum: number;
497
+ TXrateSum: number;
498
+ }
499
+ export interface TaxLine {
500
+ itemLineId: number;
501
+ taxableAmount: number;
502
+ taxLineTotal: number;
503
+ VAT: number;
504
+ VATCode: string;
505
+ PreTax: number;
506
+ }
507
+ export declare enum DISCOUNTTYPE {
508
+ PERCENT = "Percent",
509
+ AMOUNT = "AMOUNT"
510
+ }
511
+ export interface TransactionInfo {
512
+ shippingId?: string;
513
+ externalShippingId?: string;
514
+ invoiceId?: string;
515
+ }
516
+ export interface Coupons {
517
+ name?: string;
518
+ id?: string;
519
+ }
520
+ export interface externalTransactionDetails {
521
+ uniqueId?: string;
522
+ providerType?: string;
523
+ details?: TransactionInfo;
524
+ coupons?: Coupons[];
525
+ }
526
+ export declare enum INITIATING_MODULE {
527
+ EBASKET = "eBasket"
528
+ }
529
+ export interface pendingMethod {
530
+ _type?: string;
531
+ type?: string;
532
+ message?: string;
533
+ path?: string;
534
+ details?: ShipmentId;
535
+ }
536
+ export interface ShipmentId {
537
+ shipmentId?: string;
538
+ }
539
+ export interface CustomerAddress {
540
+ _type?: string;
541
+ email?: string;
542
+ address1?: string;
543
+ city?: string;
544
+ country_code?: string;
545
+ first_name?: string;
546
+ full_name?: string;
547
+ id?: string;
548
+ last_name?: string;
549
+ phone?: string;
550
+ salutation?: string;
551
+ c_area?: string;
552
+ c_email?: string;
553
+ c_phoneWhatsApp?: string;
554
+ c_strValue?: string;
555
+ postal_code?: string;
556
+ }
557
+ export interface CustomerInfo {
558
+ _type?: string;
559
+ customer_id?: string;
560
+ email?: string;
561
+ }
562
+ export interface GroupedTaxItem {
563
+ _type?: string;
564
+ tax_rate?: number;
565
+ tax_value?: number;
566
+ }
567
+ export interface additionalNotes {
568
+ _type?: string;
569
+ link?: string;
570
+ }
571
+ export interface ProductItem {
572
+ _type?: string;
573
+ adjusted_tax?: number;
574
+ base_price?: number;
575
+ bonus_product_line_item?: boolean;
576
+ gift?: boolean;
577
+ item_id?: string;
578
+ item_text?: string;
579
+ price?: number;
580
+ price_adjustments?: PriceAdjustment[];
581
+ price_after_item_discount?: number;
582
+ price_after_order_discount?: number;
583
+ product_id?: string;
584
+ product_name?: string;
585
+ quantity?: number;
586
+ shipment_id?: string;
587
+ tax?: number;
588
+ tax_basis?: number;
589
+ tax_class_id?: string;
590
+ tax_rate?: number;
591
+ c_osuObjectData?: string;
592
+ }
593
+ export interface ShippingMethod {
594
+ _type?: string;
595
+ description?: string;
596
+ id?: string;
597
+ name?: string;
598
+ price?: number;
599
+ c_approachingThresholdMessage?: string;
600
+ c_estimatedArrivalTime?: string;
601
+ c_isEmail?: boolean;
602
+ c_storePickupEnabled?: boolean;
603
+ c_thresholdValue?: number;
604
+ }
605
+ export interface shipment {
606
+ _type?: string;
607
+ adjusted_merchandize_total_tax?: number;
608
+ adjusted_shipping_total_tax?: number;
609
+ gift?: boolean;
610
+ merchandize_total_tax?: number;
611
+ product_sub_total?: number;
612
+ product_total?: number;
613
+ shipment_id?: string;
614
+ shipment_total?: number;
615
+ shipping_address?: CustomerAddress;
616
+ shipping_method?: ShippingMethod;
617
+ shipping_status?: string;
618
+ shipping_total?: number;
619
+ shipping_total_tax?: number;
620
+ tax_total?: number;
621
+ c_fromStoreId?: string;
622
+ }
623
+ export interface ShippingItem {
624
+ _type?: string;
625
+ adjusted_tax?: number;
626
+ base_price?: number;
627
+ item_id?: string;
628
+ item_text?: string;
629
+ price?: number;
630
+ price_after_item_discount?: number;
631
+ shipment_id?: string;
632
+ tax?: number;
633
+ tax_basis?: number;
634
+ tax_class_id?: string;
635
+ tax_rate?: number;
636
+ }
637
+ export interface AppliedDiscount {
638
+ _type?: string;
639
+ amount?: number;
640
+ percentage?: number;
641
+ type?: string;
642
+ }
643
+ export interface PriceAdjustment {
644
+ _type?: string;
645
+ applied_discount?: AppliedDiscount;
646
+ coupon_code?: string;
647
+ creation_date?: string;
648
+ custom?: boolean;
649
+ item_text?: string;
650
+ last_modified?: string;
651
+ manual?: boolean;
652
+ price?: number;
653
+ price_adjustment_id?: string;
654
+ promotion_id?: string;
655
+ promotion_link?: string;
656
+ }
657
+ export interface OrderDetails {
658
+ _v?: string;
659
+ _type?: string;
660
+ _resource_state?: string;
661
+ _flash?: pendingMethod[];
662
+ adjusted_merchandize_total_tax?: number;
663
+ adjusted_shipping_total_tax?: number;
664
+ agent_basket?: boolean;
665
+ basket_id?: string;
666
+ billing_address?: CustomerAddress;
667
+ channel_type?: string;
668
+ creation_date?: string;
669
+ currency?: string;
670
+ customer_info?: CustomerInfo;
671
+ grouped_tax_items?: GroupedTaxItem[];
672
+ last_modified?: string;
673
+ merchandize_total_tax?: number;
674
+ notes?: additionalNotes;
675
+ order_price_adjustments?: PriceAdjustment[];
676
+ order_no?: string;
677
+ order_total?: number;
678
+ product_items?: ProductItem[];
679
+ product_sub_total?: number;
680
+ product_total?: number;
681
+ shipments?: shipment[];
682
+ shipping_items?: ShippingItem[];
683
+ shipping_total?: number;
684
+ shipping_total_tax?: number;
685
+ taxation?: string;
686
+ tax_rounded_at_group?: boolean;
687
+ tax_total?: number;
688
+ c_isInStoreOrder?: boolean;
689
+ }
690
+ export declare enum PROVIDERS {
691
+ SALESFORCE = "Salesforce",
692
+ MAGENTO = "Magento",
693
+ MAGENTO2 = "Magento2"
694
+ }
695
+ export declare enum PROMOTION_LEVEL {
696
+ LINE = "LINE",
697
+ TRANSACTION = "TRANSACTION"
698
+ }
699
+ export declare enum PROMOTION_TYPE {
700
+ COUPON = "COUPON"
701
+ }
702
+ export {};
702
703
  //# sourceMappingURL=mapper-library.model.d.ts.map