@daffodil/cart 0.77.0 → 0.79.0

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 (162) hide show
  1. package/driver/errors/product-not-found.d.ts +1 -1
  2. package/driver/in-memory/backend/cart/cart.service.d.ts +3 -2
  3. package/driver/in-memory/backend/cart-address/cart-address.service.d.ts +3 -2
  4. package/driver/in-memory/backend/cart-billing-address/cart-billing-address.service.d.ts +3 -2
  5. package/driver/in-memory/backend/cart-coupon/cart-coupon.service.d.ts +3 -2
  6. package/driver/in-memory/backend/cart-items/cart-items.service.d.ts +3 -2
  7. package/driver/in-memory/backend/cart-order/cart-order.service.d.ts +3 -2
  8. package/driver/in-memory/backend/cart-payment/cart-payment.service.d.ts +3 -2
  9. package/driver/in-memory/backend/cart-payment-methods/cart-payment-methods.service.d.ts +3 -2
  10. package/driver/in-memory/backend/cart-root.service.d.ts +7 -25
  11. package/driver/in-memory/backend/cart-shipping-address/cart-shipping-address.service.d.ts +3 -2
  12. package/driver/in-memory/backend/cart-shipping-information/cart-shipping-information.service.d.ts +3 -2
  13. package/driver/in-memory/backend/cart-shipping-methods/cart-shipping-methods.service.d.ts +3 -2
  14. package/driver/in-memory/collection-names.d.ts +11 -0
  15. package/driver/in-memory/drivers/cart/cart.service.d.ts +4 -6
  16. package/driver/in-memory/drivers/cart-address/cart-address.service.d.ts +4 -6
  17. package/driver/in-memory/drivers/cart-billing-address/cart-billing-address.service.d.ts +4 -6
  18. package/driver/in-memory/drivers/cart-coupon/cart-coupon.service.d.ts +4 -6
  19. package/driver/in-memory/drivers/cart-item/cart-item.service.d.ts +4 -6
  20. package/driver/in-memory/drivers/cart-order/cart-order.service.d.ts +4 -6
  21. package/driver/in-memory/drivers/cart-payment/cart-payment.service.d.ts +4 -6
  22. package/driver/in-memory/drivers/cart-payment-methods/cart-payment-methods.service.d.ts +4 -6
  23. package/driver/in-memory/drivers/cart-shipping-address/cart-shipping-address.service.d.ts +4 -6
  24. package/driver/in-memory/drivers/cart-shipping-information/cart-shipping-information.service.d.ts +4 -6
  25. package/driver/in-memory/drivers/cart-shipping-methods/cart-shipping-methods.service.d.ts +4 -6
  26. package/driver/in-memory/injection-tokens/extra-attributes-hook.token.d.ts +1 -20
  27. package/driver/in-memory/public_api.d.ts +1 -0
  28. package/driver/injection-tokens/free-payment-method.d.ts +1 -10
  29. package/driver/injection-tokens/public_api.d.ts +1 -1
  30. package/driver/interfaces/cart-address-service.interface.d.ts +1 -2
  31. package/driver/interfaces/cart-billing-address-service.interface.d.ts +1 -2
  32. package/driver/interfaces/cart-coupon-service.interface.d.ts +1 -2
  33. package/driver/interfaces/cart-item-service.interface.d.ts +1 -2
  34. package/driver/interfaces/cart-order-service.interface.d.ts +1 -2
  35. package/driver/interfaces/cart-payment-methods-service.interface.d.ts +1 -2
  36. package/driver/interfaces/cart-payment-service.interface.d.ts +2 -3
  37. package/driver/interfaces/cart-service.interface.d.ts +2 -3
  38. package/driver/interfaces/cart-shipping-address-service.interface.d.ts +1 -2
  39. package/driver/interfaces/cart-shipping-information-service.interface.d.ts +1 -2
  40. package/driver/interfaces/cart-shipping-methods-service.interface.d.ts +1 -2
  41. package/driver/interfaces/public_api.d.ts +11 -11
  42. package/driver/magento/injection-tokens/cart-mutation-queue.token.d.ts +1 -2
  43. package/driver/magento/injection-tokens/fragments/cart.d.ts +1 -14
  44. package/driver/magento/injection-tokens/public_api.d.ts +3 -3
  45. package/driver/magento/injection-tokens/transforms/cart/token.d.ts +2 -20
  46. package/driver/magento/injection-tokens/transforms/cart-item/token.d.ts +1 -20
  47. package/esm2022/driver/errors/product-not-found.mjs +2 -2
  48. package/esm2022/driver/in-memory/backend/cart/cart.service.mjs +3 -1
  49. package/esm2022/driver/in-memory/backend/cart-address/cart-address.service.mjs +3 -1
  50. package/esm2022/driver/in-memory/backend/cart-billing-address/cart-billing-address.service.mjs +3 -1
  51. package/esm2022/driver/in-memory/backend/cart-coupon/cart-coupon.service.mjs +3 -1
  52. package/esm2022/driver/in-memory/backend/cart-items/cart-items.service.mjs +3 -1
  53. package/esm2022/driver/in-memory/backend/cart-order/cart-order.service.mjs +5 -1
  54. package/esm2022/driver/in-memory/backend/cart-payment/cart-payment.service.mjs +3 -1
  55. package/esm2022/driver/in-memory/backend/cart-payment-methods/cart-payment-methods.service.mjs +5 -1
  56. package/esm2022/driver/in-memory/backend/cart-root.service.mjs +45 -77
  57. package/esm2022/driver/in-memory/backend/cart-shipping-address/cart-shipping-address.service.mjs +3 -1
  58. package/esm2022/driver/in-memory/backend/cart-shipping-information/cart-shipping-information.service.mjs +3 -1
  59. package/esm2022/driver/in-memory/backend/cart-shipping-methods/cart-shipping-methods.service.mjs +3 -1
  60. package/esm2022/driver/in-memory/collection-names.mjs +12 -0
  61. package/esm2022/driver/in-memory/drivers/cart/cart.service.mjs +10 -9
  62. package/esm2022/driver/in-memory/drivers/cart-address/cart-address.service.mjs +10 -9
  63. package/esm2022/driver/in-memory/drivers/cart-billing-address/cart-billing-address.service.mjs +10 -9
  64. package/esm2022/driver/in-memory/drivers/cart-coupon/cart-coupon.service.mjs +10 -9
  65. package/esm2022/driver/in-memory/drivers/cart-driver.module.mjs +16 -46
  66. package/esm2022/driver/in-memory/drivers/cart-item/cart-item.service.mjs +10 -9
  67. package/esm2022/driver/in-memory/drivers/cart-order/cart-order.service.mjs +10 -9
  68. package/esm2022/driver/in-memory/drivers/cart-payment/cart-payment.service.mjs +10 -9
  69. package/esm2022/driver/in-memory/drivers/cart-payment-methods/cart-payment-methods.service.mjs +10 -9
  70. package/esm2022/driver/in-memory/drivers/cart-shipping-address/cart-shipping-address.service.mjs +10 -9
  71. package/esm2022/driver/in-memory/drivers/cart-shipping-information/cart-shipping-information.service.mjs +10 -9
  72. package/esm2022/driver/in-memory/drivers/cart-shipping-methods/cart-shipping-methods.service.mjs +10 -9
  73. package/esm2022/driver/in-memory/injection-tokens/extra-attributes-hook.token.mjs +8 -5
  74. package/esm2022/driver/in-memory/public_api.mjs +2 -1
  75. package/esm2022/driver/injection-tokens/free-payment-method.mjs +5 -11
  76. package/esm2022/driver/injection-tokens/public_api.mjs +2 -2
  77. package/esm2022/driver/interfaces/cart-address-service.interface.mjs +7 -3
  78. package/esm2022/driver/interfaces/cart-billing-address-service.interface.mjs +7 -3
  79. package/esm2022/driver/interfaces/cart-coupon-service.interface.mjs +7 -3
  80. package/esm2022/driver/interfaces/cart-item-service.interface.mjs +7 -3
  81. package/esm2022/driver/interfaces/cart-order-service.interface.mjs +7 -3
  82. package/esm2022/driver/interfaces/cart-payment-methods-service.interface.mjs +7 -3
  83. package/esm2022/driver/interfaces/cart-payment-service.interface.mjs +7 -3
  84. package/esm2022/driver/interfaces/cart-service.interface.mjs +7 -3
  85. package/esm2022/driver/interfaces/cart-shipping-address-service.interface.mjs +7 -3
  86. package/esm2022/driver/interfaces/cart-shipping-information-service.interface.mjs +7 -3
  87. package/esm2022/driver/interfaces/cart-shipping-methods-service.interface.mjs +7 -3
  88. package/esm2022/driver/interfaces/public_api.mjs +12 -12
  89. package/esm2022/driver/magento/cart-driver.module.mjs +13 -46
  90. package/esm2022/driver/magento/injection-tokens/cart-mutation-queue.token.mjs +8 -3
  91. package/esm2022/driver/magento/injection-tokens/fragments/cart.mjs +8 -3
  92. package/esm2022/driver/magento/injection-tokens/public_api.mjs +4 -4
  93. package/esm2022/driver/magento/injection-tokens/transforms/cart/token.mjs +6 -11
  94. package/esm2022/driver/magento/injection-tokens/transforms/cart-item/token.mjs +6 -11
  95. package/esm2022/driver/testing/drivers/cart-driver.module.mjs +13 -46
  96. package/esm2022/injection-tokens/payment-method-map.mjs +8 -5
  97. package/esm2022/models/cart-coupon.mjs +1 -1
  98. package/esm2022/models/cart-item.mjs +1 -1
  99. package/esm2022/models/cart-order-result.mjs +1 -1
  100. package/esm2022/models/cart.mjs +1 -1
  101. package/esm2022/models/composite-cart-item.mjs +1 -1
  102. package/esm2022/routing/cart-routing.module.mjs +3 -9
  103. package/esm2022/routing/config/config.mjs +7 -6
  104. package/esm2022/routing/guards/billing-address/billing-address-guard-redirect.token.mjs +7 -3
  105. package/esm2022/routing/guards/cart-items/cart-items-guard-redirect.token.mjs +8 -3
  106. package/esm2022/routing/guards/in-stock-items/in-stock-items-guard-redirect.token.mjs +8 -3
  107. package/esm2022/routing/guards/order-result/order-result-guard-redirect.token.mjs +7 -3
  108. package/esm2022/routing/guards/payment-method/payment-method-guard-redirect.token.mjs +7 -3
  109. package/esm2022/routing/guards/resolve-cart/redirect.token.mjs +7 -3
  110. package/esm2022/routing/guards/shipping-address/shipping-address-guard-redirect.token.mjs +7 -3
  111. package/esm2022/routing/guards/shipping-method/shipping-method-guard-redirect.token.mjs +7 -3
  112. package/esm2022/routing/resolvers/tokens/cart-resolver-redirect.token.mjs +7 -3
  113. package/esm2022/routing/resolvers/tokens/empty-cart-resolver-redirect.token.mjs +7 -3
  114. package/esm2022/state/cart-retrieval/token.mjs +5 -8
  115. package/esm2022/state/cart-state.module.mjs +4 -4
  116. package/esm2022/state/injection-tokens/cart-item-state-debounce-time.mjs +8 -3
  117. package/esm2022/state/injection-tokens/error-matcher.token.mjs +8 -3
  118. package/esm2022/state/injection-tokens/public_api.mjs +3 -3
  119. package/esm2022/state/reducers/token/config.token.mjs +8 -3
  120. package/esm2022/state/reducers/token/extra.token.mjs +5 -10
  121. package/esm2022/state/reducers/token/meta.token.mjs +5 -10
  122. package/esm2022/state/reducers/token/reducers.token.mjs +9 -3
  123. package/fesm2022/daffodil-cart-driver-in-memory.mjs +178 -244
  124. package/fesm2022/daffodil-cart-driver-in-memory.mjs.map +1 -1
  125. package/fesm2022/daffodil-cart-driver-magento.mjs +34 -68
  126. package/fesm2022/daffodil-cart-driver-magento.mjs.map +1 -1
  127. package/fesm2022/daffodil-cart-driver-testing.mjs +12 -45
  128. package/fesm2022/daffodil-cart-driver-testing.mjs.map +1 -1
  129. package/fesm2022/daffodil-cart-driver.mjs +62 -24
  130. package/fesm2022/daffodil-cart-driver.mjs.map +1 -1
  131. package/fesm2022/daffodil-cart-routing.mjs +60 -22
  132. package/fesm2022/daffodil-cart-routing.mjs.map +1 -1
  133. package/fesm2022/daffodil-cart-state.mjs +37 -31
  134. package/fesm2022/daffodil-cart-state.mjs.map +1 -1
  135. package/fesm2022/daffodil-cart.mjs +9 -6
  136. package/fesm2022/daffodil-cart.mjs.map +1 -1
  137. package/injection-tokens/payment-method-map.d.ts +6 -9
  138. package/models/cart-coupon.d.ts +1 -1
  139. package/models/cart-item.d.ts +1 -1
  140. package/models/cart-order-result.d.ts +1 -1
  141. package/models/cart.d.ts +2 -2
  142. package/models/composite-cart-item.d.ts +1 -1
  143. package/package.json +1 -1
  144. package/routing/config/config.d.ts +1 -2
  145. package/routing/guards/billing-address/billing-address-guard-redirect.token.d.ts +1 -2
  146. package/routing/guards/cart-items/cart-items-guard-redirect.token.d.ts +1 -5
  147. package/routing/guards/in-stock-items/in-stock-items-guard-redirect.token.d.ts +1 -5
  148. package/routing/guards/order-result/order-result-guard-redirect.token.d.ts +1 -2
  149. package/routing/guards/payment-method/payment-method-guard-redirect.token.d.ts +1 -2
  150. package/routing/guards/resolve-cart/redirect.token.d.ts +1 -2
  151. package/routing/guards/shipping-address/shipping-address-guard-redirect.token.d.ts +1 -2
  152. package/routing/guards/shipping-method/shipping-method-guard-redirect.token.d.ts +1 -2
  153. package/routing/resolvers/tokens/cart-resolver-redirect.token.d.ts +1 -2
  154. package/routing/resolvers/tokens/empty-cart-resolver-redirect.token.d.ts +1 -2
  155. package/state/cart-retrieval/token.d.ts +1 -9
  156. package/state/injection-tokens/cart-item-state-debounce-time.d.ts +1 -8
  157. package/state/injection-tokens/error-matcher.token.d.ts +1 -6
  158. package/state/injection-tokens/public_api.d.ts +2 -2
  159. package/state/reducers/token/config.token.d.ts +1 -2
  160. package/state/reducers/token/extra.token.d.ts +1 -21
  161. package/state/reducers/token/meta.token.d.ts +1 -20
  162. package/state/reducers/token/reducers.token.d.ts +1 -8
@@ -1,27 +1,38 @@
1
1
  import * as i1 from '@angular/common/http';
2
2
  import * as i0 from '@angular/core';
3
- import { Injectable, NgModule, InjectionToken, Inject } from '@angular/core';
4
- import { throwError } from 'rxjs';
3
+ import { Injectable, Inject, NgModule } from '@angular/core';
4
+ import * as i2 from 'angular-in-memory-web-api';
5
+ import { STATUS } from 'angular-in-memory-web-api';
6
+ import { throwError, of } from 'rxjs';
5
7
  import { catchError, map } from 'rxjs/operators';
6
- import { DaffCartNotFoundError, DaffCartDriver, DaffCartAddressDriver, DaffCartBillingAddressDriver, DaffCartItemDriver, DaffCartPaymentDriver, DaffCartPaymentMethodsDriver, DaffCartShippingAddressDriver, DaffCartShippingInformationDriver, DaffCartShippingMethodsDriver, DaffCartOrderDriver, DaffCartCouponDriver } from '@daffodil/cart/driver';
8
+ import { DaffCartNotFoundError, provideDaffCartDriver, provideDaffCartAddressDriver, provideDaffCartBillingAddressDriver, provideDaffCartItemDriver, provideDaffCartPaymentDriver, provideDaffCartPaymentMethodsDriver, provideDaffCartShippingAddressDriver, provideDaffCartShippingInformationDriver, provideDaffCartShippingMethodsDriver, provideDaffCartOrderDriver, provideDaffCartCouponDriver } from '@daffodil/cart/driver';
9
+ import { DaffInMemoryDriverBase, DaffInMemoryBackendDelegate, provideDaffInMemoryBackends } from '@daffodil/driver/in-memory';
7
10
  import { CommonModule } from '@angular/common';
8
- import { STATUS } from 'angular-in-memory-web-api';
9
11
  import * as i1$1 from '@daffodil/cart/testing';
10
- import * as i2 from '@daffodil/product/driver/in-memory';
12
+ import * as i2$1 from '@daffodil/product/driver/in-memory';
11
13
  import { faker } from '@faker-js/faker/locale/en_US';
12
14
  import { DaffCartTotalTypeEnum } from '@daffodil/cart';
13
- import { daffMultiply } from '@daffodil/core';
15
+ import { createSingleInjectionToken, daffMultiply } from '@daffodil/core';
16
+
17
+ const DAFF_CART_IN_MEMORY_CART_COLLECTION_NAME = 'cart';
18
+ const DAFF_CART_IN_MEMORY_CART_ITEMS_COLLECTION_NAME = 'cart-items';
19
+ const DAFF_CART_IN_MEMORY_CART_ORDER_COLLECTION_NAME = 'cart-order';
20
+ const DAFF_CART_IN_MEMORY_CART_COUPON_COLLECTION_NAME = 'cart-coupon';
21
+ const DAFF_CART_IN_MEMORY_CART_ADDRESS_COLLECTION_NAME = 'cart-address';
22
+ const DAFF_CART_IN_MEMORY_CART_SHIPPING_ADDRESS_COLLECTION_NAME = 'cart-shipping-address';
23
+ const DAFF_CART_IN_MEMORY_CART_BILLING_ADDRESS_COLLECTION_NAME = 'cart-billing-address';
24
+ const DAFF_CART_IN_MEMORY_CART_PAYMENT_METHODS_COLLECTION_NAME = 'cart-payment-methods';
25
+ const DAFF_CART_IN_MEMORY_CART_SHIPPING_METHODS_COLLECTION_NAME = 'cart-shipping-methods';
26
+ const DAFF_CART_IN_MEMORY_CART_PAYMENT_COLLECTION_NAME = 'cart-payment';
27
+ const DAFF_CART_IN_MEMORY_CART_SHIPPING_COLLECTION_NAME = 'cart-shipping-information';
14
28
 
15
29
  /**
16
30
  * @inheritdoc
17
31
  */
18
- class DaffInMemoryCartService {
19
- constructor(http) {
32
+ class DaffInMemoryCartService extends DaffInMemoryDriverBase {
33
+ constructor(http, config) {
34
+ super(config, DAFF_CART_IN_MEMORY_CART_COLLECTION_NAME);
20
35
  this.http = http;
21
- /**
22
- * The URL with which the driver makes calls to the backend.
23
- */
24
- this.url = '/api/cart';
25
36
  }
26
37
  get(cartId) {
27
38
  return this.http.get(`${this.url}/${cartId}`).pipe(catchError((error) => throwError(() => new DaffCartNotFoundError(error.message))), map(result => ({
@@ -47,7 +58,7 @@ class DaffInMemoryCartService {
47
58
  errors: [],
48
59
  })));
49
60
  }
50
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
61
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
51
62
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartService, providedIn: 'root' }); }
52
63
  }
53
64
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartService, decorators: [{
@@ -55,18 +66,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
55
66
  args: [{
56
67
  providedIn: 'root',
57
68
  }]
58
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
69
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
59
70
 
60
71
  /**
61
72
  * @inheritdoc
62
73
  */
63
- class DaffInMemoryCartItemService {
64
- constructor(http) {
74
+ class DaffInMemoryCartItemService extends DaffInMemoryDriverBase {
75
+ constructor(http, config) {
76
+ super(config, DAFF_CART_IN_MEMORY_CART_ITEMS_COLLECTION_NAME);
65
77
  this.http = http;
66
- /**
67
- * The URL with which the driver makes calls to the backend.
68
- */
69
- this.url = '/api/cart-items';
70
78
  }
71
79
  list(cartId) {
72
80
  return this.http.get(`${this.url}/${cartId}/`);
@@ -83,7 +91,7 @@ class DaffInMemoryCartItemService {
83
91
  delete(cartId, itemId) {
84
92
  return this.http.delete(`${this.url}/${cartId}/${itemId}`);
85
93
  }
86
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartItemService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
94
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartItemService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
87
95
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartItemService, providedIn: 'root' }); }
88
96
  }
89
97
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartItemService, decorators: [{
@@ -91,18 +99,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
91
99
  args: [{
92
100
  providedIn: 'root',
93
101
  }]
94
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
102
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
95
103
 
96
104
  /**
97
105
  * @inheritdoc
98
106
  */
99
- class DaffInMemoryCartBillingAddressService {
100
- constructor(http) {
107
+ class DaffInMemoryCartBillingAddressService extends DaffInMemoryDriverBase {
108
+ constructor(http, config) {
109
+ super(config, DAFF_CART_IN_MEMORY_CART_BILLING_ADDRESS_COLLECTION_NAME);
101
110
  this.http = http;
102
- /**
103
- * The URL with which the driver makes calls to the backend.
104
- */
105
- this.url = '/api/cart-billing-address';
106
111
  }
107
112
  get(cartId) {
108
113
  return this.http.get(`${this.url}/${cartId}`);
@@ -110,7 +115,7 @@ class DaffInMemoryCartBillingAddressService {
110
115
  update(cartId, address) {
111
116
  return this.http.put(`${this.url}/${cartId}`, address);
112
117
  }
113
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartBillingAddressService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
118
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartBillingAddressService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
114
119
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartBillingAddressService, providedIn: 'root' }); }
115
120
  }
116
121
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartBillingAddressService, decorators: [{
@@ -118,18 +123,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
118
123
  args: [{
119
124
  providedIn: 'root',
120
125
  }]
121
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
126
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
122
127
 
123
128
  /**
124
129
  * @inheritdoc
125
130
  */
126
- class DaffInMemoryCartPaymentService {
127
- constructor(http) {
131
+ class DaffInMemoryCartPaymentService extends DaffInMemoryDriverBase {
132
+ constructor(http, config) {
133
+ super(config, DAFF_CART_IN_MEMORY_CART_PAYMENT_COLLECTION_NAME);
128
134
  this.http = http;
129
- /**
130
- * The URL with which the driver makes calls to the backend.
131
- */
132
- this.url = '/api/cart-payment';
133
135
  }
134
136
  get(cartId) {
135
137
  return this.http.get(`${this.url}/${cartId}`);
@@ -143,7 +145,7 @@ class DaffInMemoryCartPaymentService {
143
145
  remove(cartId) {
144
146
  return this.http.delete(`${this.url}/${cartId}`);
145
147
  }
146
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartPaymentService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
148
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartPaymentService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
147
149
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartPaymentService, providedIn: 'root' }); }
148
150
  }
149
151
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartPaymentService, decorators: [{
@@ -151,23 +153,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
151
153
  args: [{
152
154
  providedIn: 'root',
153
155
  }]
154
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
156
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
155
157
 
156
158
  /**
157
159
  * @inheritdoc
158
160
  */
159
- class DaffInMemoryCartPaymentMethodsService {
160
- constructor(http) {
161
+ class DaffInMemoryCartPaymentMethodsService extends DaffInMemoryDriverBase {
162
+ constructor(http, config) {
163
+ super(config, DAFF_CART_IN_MEMORY_CART_PAYMENT_METHODS_COLLECTION_NAME);
161
164
  this.http = http;
162
- /**
163
- * The URL with which the driver makes calls to the backend.
164
- */
165
- this.url = '/api/cart-payment-methods';
166
165
  }
167
166
  list(cartId) {
168
167
  return this.http.get(`${this.url}/${cartId}`);
169
168
  }
170
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartPaymentMethodsService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
169
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartPaymentMethodsService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
171
170
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartPaymentMethodsService, providedIn: 'root' }); }
172
171
  }
173
172
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartPaymentMethodsService, decorators: [{
@@ -175,18 +174,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
175
174
  args: [{
176
175
  providedIn: 'root',
177
176
  }]
178
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
177
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
179
178
 
180
179
  /**
181
180
  * @inheritdoc
182
181
  */
183
- class DaffInMemoryCartShippingAddressService {
184
- constructor(http) {
182
+ class DaffInMemoryCartShippingAddressService extends DaffInMemoryDriverBase {
183
+ constructor(http, config) {
184
+ super(config, DAFF_CART_IN_MEMORY_CART_SHIPPING_ADDRESS_COLLECTION_NAME);
185
185
  this.http = http;
186
- /**
187
- * The URL with which the driver makes calls to the backend.
188
- */
189
- this.url = '/api/cart-shipping-address';
190
186
  }
191
187
  get(cartId) {
192
188
  return this.http.get(`${this.url}/${cartId}`);
@@ -194,7 +190,7 @@ class DaffInMemoryCartShippingAddressService {
194
190
  update(cartId, address) {
195
191
  return this.http.put(`${this.url}/${cartId}`, address);
196
192
  }
197
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingAddressService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
193
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingAddressService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
198
194
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingAddressService, providedIn: 'root' }); }
199
195
  }
200
196
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingAddressService, decorators: [{
@@ -202,18 +198,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
202
198
  args: [{
203
199
  providedIn: 'root',
204
200
  }]
205
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
201
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
206
202
 
207
203
  /**
208
204
  * @inheritdoc
209
205
  */
210
- class DaffInMemoryCartShippingInformationService {
211
- constructor(http) {
206
+ class DaffInMemoryCartShippingInformationService extends DaffInMemoryDriverBase {
207
+ constructor(http, config) {
208
+ super(config, DAFF_CART_IN_MEMORY_CART_SHIPPING_COLLECTION_NAME);
212
209
  this.http = http;
213
- /**
214
- * The URL with which the driver makes calls to the backend.
215
- */
216
- this.url = '/api/cart-shipping-information';
217
210
  }
218
211
  get(cartId) {
219
212
  return this.http.get(`${this.url}/${cartId}`);
@@ -224,7 +217,7 @@ class DaffInMemoryCartShippingInformationService {
224
217
  delete(cartId) {
225
218
  return this.http.delete(`${this.url}/${cartId}`);
226
219
  }
227
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingInformationService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
220
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingInformationService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
228
221
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingInformationService, providedIn: 'root' }); }
229
222
  }
230
223
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingInformationService, decorators: [{
@@ -232,23 +225,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
232
225
  args: [{
233
226
  providedIn: 'root',
234
227
  }]
235
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
228
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
236
229
 
237
230
  /**
238
231
  * @inheritdoc
239
232
  */
240
- class DaffInMemoryCartShippingMethodsService {
241
- constructor(http) {
233
+ class DaffInMemoryCartShippingMethodsService extends DaffInMemoryDriverBase {
234
+ constructor(http, config) {
235
+ super(config, DAFF_CART_IN_MEMORY_CART_SHIPPING_METHODS_COLLECTION_NAME);
242
236
  this.http = http;
243
- /**
244
- * The URL with which the driver makes calls to the backend.
245
- */
246
- this.url = '/api/cart-shipping-methods';
247
237
  }
248
238
  list(cartId) {
249
239
  return this.http.get(`${this.url}/${cartId}`);
250
240
  }
251
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingMethodsService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
241
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingMethodsService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
252
242
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingMethodsService, providedIn: 'root' }); }
253
243
  }
254
244
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartShippingMethodsService, decorators: [{
@@ -256,23 +246,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
256
246
  args: [{
257
247
  providedIn: 'root',
258
248
  }]
259
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
249
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
260
250
 
261
251
  /**
262
252
  * @inheritdoc
263
253
  */
264
- class DaffInMemoryCartOrderService {
265
- constructor(http) {
254
+ class DaffInMemoryCartOrderService extends DaffInMemoryDriverBase {
255
+ constructor(http, config) {
256
+ super(config, DAFF_CART_IN_MEMORY_CART_ORDER_COLLECTION_NAME);
266
257
  this.http = http;
267
- /**
268
- * The URL with which the driver makes calls to the backend.
269
- */
270
- this.url = '/api/cart-order';
271
258
  }
272
259
  placeOrder(cartId, payment) {
273
260
  return this.http.post(`${this.url}/${cartId}/`, { payment });
274
261
  }
275
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartOrderService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
262
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartOrderService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
276
263
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartOrderService, providedIn: 'root' }); }
277
264
  }
278
265
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartOrderService, decorators: [{
@@ -280,18 +267,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
280
267
  args: [{
281
268
  providedIn: 'root',
282
269
  }]
283
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
270
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
284
271
 
285
272
  /**
286
273
  * @inheritdoc
287
274
  */
288
- class DaffInMemoryCartCouponService {
289
- constructor(http) {
275
+ class DaffInMemoryCartCouponService extends DaffInMemoryDriverBase {
276
+ constructor(http, config) {
277
+ super(config, DAFF_CART_IN_MEMORY_CART_COUPON_COLLECTION_NAME);
290
278
  this.http = http;
291
- /**
292
- * The URL with which the driver makes calls to the backend.
293
- */
294
- this.url = '/api/cart-coupon';
295
279
  }
296
280
  list(cartId) {
297
281
  return this.http.get(`${this.url}/${cartId}/`);
@@ -305,7 +289,7 @@ class DaffInMemoryCartCouponService {
305
289
  removeAll(cartId) {
306
290
  return this.http.delete(`${this.url}/${cartId}/`);
307
291
  }
308
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartCouponService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
292
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartCouponService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
309
293
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartCouponService, providedIn: 'root' }); }
310
294
  }
311
295
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartCouponService, decorators: [{
@@ -313,23 +297,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
313
297
  args: [{
314
298
  providedIn: 'root',
315
299
  }]
316
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
300
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
317
301
 
318
302
  /**
319
303
  * @inheritdoc
320
304
  */
321
- class DaffInMemoryCartAddressService {
322
- constructor(http) {
305
+ class DaffInMemoryCartAddressService extends DaffInMemoryDriverBase {
306
+ constructor(http, config) {
307
+ super(config, DAFF_CART_IN_MEMORY_CART_ADDRESS_COLLECTION_NAME);
323
308
  this.http = http;
324
- /**
325
- * The URL with which the driver makes calls to the backend.
326
- */
327
- this.url = '/api/cart-address';
328
309
  }
329
310
  update(cartId, address) {
330
311
  return this.http.put(`${this.url}/${cartId}`, address);
331
312
  }
332
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartAddressService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
313
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartAddressService, deps: [{ token: i1.HttpClient }, { token: i2.InMemoryBackendConfig }], target: i0.ɵɵFactoryTarget.Injectable }); }
333
314
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartAddressService, providedIn: 'root' }); }
334
315
  }
335
316
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryCartAddressService, decorators: [{
@@ -337,72 +318,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
337
318
  args: [{
338
319
  providedIn: 'root',
339
320
  }]
340
- }], ctorParameters: () => [{ type: i1.HttpClient }] });
341
-
342
- class DaffCartInMemoryDriverModule {
343
- static forRoot() {
344
- return {
345
- ngModule: DaffCartInMemoryDriverModule,
346
- providers: [
347
- {
348
- provide: DaffCartDriver,
349
- useExisting: DaffInMemoryCartService,
350
- },
351
- {
352
- provide: DaffCartAddressDriver,
353
- useExisting: DaffInMemoryCartAddressService,
354
- },
355
- {
356
- provide: DaffCartBillingAddressDriver,
357
- useExisting: DaffInMemoryCartBillingAddressService,
358
- },
359
- {
360
- provide: DaffCartItemDriver,
361
- useExisting: DaffInMemoryCartItemService,
362
- },
363
- {
364
- provide: DaffCartPaymentDriver,
365
- useExisting: DaffInMemoryCartPaymentService,
366
- },
367
- {
368
- provide: DaffCartPaymentMethodsDriver,
369
- useExisting: DaffInMemoryCartPaymentMethodsService,
370
- },
371
- {
372
- provide: DaffCartShippingAddressDriver,
373
- useExisting: DaffInMemoryCartShippingAddressService,
374
- },
375
- {
376
- provide: DaffCartShippingInformationDriver,
377
- useExisting: DaffInMemoryCartShippingInformationService,
378
- },
379
- {
380
- provide: DaffCartShippingMethodsDriver,
381
- useExisting: DaffInMemoryCartShippingMethodsService,
382
- },
383
- {
384
- provide: DaffCartOrderDriver,
385
- useExisting: DaffInMemoryCartOrderService,
386
- },
387
- {
388
- provide: DaffCartCouponDriver,
389
- useExisting: DaffInMemoryCartCouponService,
390
- },
391
- ],
392
- };
393
- }
394
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffCartInMemoryDriverModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
395
- /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.2", ngImport: i0, type: DaffCartInMemoryDriverModule, imports: [CommonModule] }); }
396
- /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffCartInMemoryDriverModule, imports: [CommonModule] }); }
397
- }
398
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffCartInMemoryDriverModule, decorators: [{
399
- type: NgModule,
400
- args: [{
401
- imports: [
402
- CommonModule,
403
- ],
404
- }]
405
- }] });
321
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.InMemoryBackendConfig }] });
406
322
 
407
323
  function daffCartInMemoryComputeCartTotals(cart, products) {
408
324
  const shipping = cart.shipping_information ? faker.datatype.number({ min: 0, max: 99 }) : 0;
@@ -448,6 +364,7 @@ function daffCartInMemoryComputeCartTotals(cart, products) {
448
364
  };
449
365
  }
450
366
 
367
+ const {
451
368
  /**
452
369
  * Allows an app dev to generate extra fields in the in-memory backend.
453
370
  * This enables the in-memory drivers to return responses similar to what the
@@ -466,9 +383,11 @@ function daffCartInMemoryComputeCartTotals(cart, products) {
466
383
  * Note that this and any `extra_attributes` features are for advanced users
467
384
  * and should be used with care.
468
385
  */
469
- const DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK = new InjectionToken('DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK', {
470
- factory: () => (reqInfo, cart) => ({}),
471
- });
386
+ token: DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK,
387
+ /**
388
+ * Provider function for {@link DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK}.
389
+ */
390
+ provider: provideDaffCartInMemoryExtraAttributesHook, } = createSingleInjectionToken('DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK', { factory: () => (reqInfo, cart) => ({}) });
472
391
 
473
392
  /**
474
393
  * @inheritdoc
@@ -478,6 +397,7 @@ class DaffInMemoryBackendCartService {
478
397
  this.cartFactory = cartFactory;
479
398
  this.extraFieldsHook = extraFieldsHook;
480
399
  this.productBackend = productBackend;
400
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_COLLECTION_NAME;
481
401
  }
482
402
  get(reqInfo) {
483
403
  return reqInfo.utils.createResponse$(() => this.getCart(reqInfo));
@@ -570,7 +490,7 @@ class DaffInMemoryBackendCartService {
570
490
  status: STATUS.NOT_FOUND,
571
491
  };
572
492
  }
573
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartService, deps: [{ token: i1$1.DaffCartFactory }, { token: DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK }, { token: i2.DaffInMemoryBackendProductService }], target: i0.ɵɵFactoryTarget.Injectable }); }
493
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartService, deps: [{ token: i1$1.DaffCartFactory }, { token: DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK }, { token: i2$1.DaffInMemoryBackendProductService }], target: i0.ɵɵFactoryTarget.Injectable }); }
574
494
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartService, providedIn: 'root' }); }
575
495
  }
576
496
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartService, decorators: [{
@@ -581,7 +501,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
581
501
  }], ctorParameters: () => [{ type: i1$1.DaffCartFactory }, { type: undefined, decorators: [{
582
502
  type: Inject,
583
503
  args: [DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK]
584
- }] }, { type: i2.DaffInMemoryBackendProductService }] });
504
+ }] }, { type: i2$1.DaffInMemoryBackendProductService }] });
585
505
 
586
506
  /**
587
507
  * @inheritdoc
@@ -589,6 +509,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
589
509
  class DaffInMemoryBackendCartAddressService {
590
510
  constructor(extraFieldsHook) {
591
511
  this.extraFieldsHook = extraFieldsHook;
512
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_ADDRESS_COLLECTION_NAME;
592
513
  }
593
514
  put(reqInfo) {
594
515
  return reqInfo.utils.createResponse$(() => ({
@@ -628,6 +549,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
628
549
  class DaffInMemoryBackendCartBillingAddressService {
629
550
  constructor(extraFieldsHook) {
630
551
  this.extraFieldsHook = extraFieldsHook;
552
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_BILLING_ADDRESS_COLLECTION_NAME;
631
553
  }
632
554
  get(reqInfo) {
633
555
  return reqInfo.utils.createResponse$(() => ({
@@ -675,6 +597,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
675
597
  class DaffInMemoryBackendCartCouponService {
676
598
  constructor(extraFieldsHook) {
677
599
  this.extraFieldsHook = extraFieldsHook;
600
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_COUPON_COLLECTION_NAME;
678
601
  }
679
602
  get(reqInfo) {
680
603
  return reqInfo.utils.createResponse$(() => ({
@@ -768,6 +691,7 @@ class DaffInMemoryBackendCartItemsService {
768
691
  this.cartItemFactory = cartItemFactory;
769
692
  this.extraFieldsHook = extraFieldsHook;
770
693
  this.productBackend = productBackend;
694
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_ITEMS_COLLECTION_NAME;
771
695
  }
772
696
  get(reqInfo) {
773
697
  return reqInfo.utils.createResponse$(() => {
@@ -879,7 +803,7 @@ class DaffInMemoryBackendCartItemsService {
879
803
  }, this.productBackend.products);
880
804
  return reqInfo.collection[cartIndex];
881
805
  }
882
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartItemsService, deps: [{ token: i1$1.DaffCartItemFactory }, { token: DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK }, { token: i2.DaffInMemoryBackendProductService }], target: i0.ɵɵFactoryTarget.Injectable }); }
806
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartItemsService, deps: [{ token: i1$1.DaffCartItemFactory }, { token: DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK }, { token: i2$1.DaffInMemoryBackendProductService }], target: i0.ɵɵFactoryTarget.Injectable }); }
883
807
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartItemsService, providedIn: 'root' }); }
884
808
  }
885
809
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartItemsService, decorators: [{
@@ -890,12 +814,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
890
814
  }], ctorParameters: () => [{ type: i1$1.DaffCartItemFactory }, { type: undefined, decorators: [{
891
815
  type: Inject,
892
816
  args: [DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK]
893
- }] }, { type: i2.DaffInMemoryBackendProductService }] });
817
+ }] }, { type: i2$1.DaffInMemoryBackendProductService }] });
894
818
 
895
819
  /**
896
820
  * @inheritdoc
897
821
  */
898
822
  class DaffInMemoryBackendCartOrderService {
823
+ constructor() {
824
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_ORDER_COLLECTION_NAME;
825
+ }
899
826
  post(reqInfo) {
900
827
  return reqInfo.utils.createResponse$(() => ({
901
828
  body: this.placeOrder(reqInfo),
@@ -925,6 +852,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
925
852
  class DaffInMemoryBackendCartPaymentService {
926
853
  constructor(extraFieldsHook) {
927
854
  this.extraFieldsHook = extraFieldsHook;
855
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_PAYMENT_COLLECTION_NAME;
928
856
  }
929
857
  get(reqInfo) {
930
858
  return reqInfo.utils.createResponse$(() => ({
@@ -987,6 +915,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
987
915
  * @inheritdoc
988
916
  */
989
917
  class DaffInMemoryBackendCartPaymentMethodsService {
918
+ constructor() {
919
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_PAYMENT_METHODS_COLLECTION_NAME;
920
+ }
990
921
  get(reqInfo) {
991
922
  return reqInfo.utils.createResponse$(() => ({
992
923
  body: this.listPaymentMethods(reqInfo),
@@ -1015,6 +946,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
1015
946
  class DaffInMemoryBackendCartShippingAddressService {
1016
947
  constructor(extraFieldsHook) {
1017
948
  this.extraFieldsHook = extraFieldsHook;
949
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_SHIPPING_ADDRESS_COLLECTION_NAME;
1018
950
  }
1019
951
  get(reqInfo) {
1020
952
  return reqInfo.utils.createResponse$(() => ({
@@ -1063,6 +995,7 @@ class DaffInMemoryBackendCartShippingInformationService {
1063
995
  constructor(extraFieldsHook, productBackend) {
1064
996
  this.extraFieldsHook = extraFieldsHook;
1065
997
  this.productBackend = productBackend;
998
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_SHIPPING_COLLECTION_NAME;
1066
999
  }
1067
1000
  get(reqInfo) {
1068
1001
  return reqInfo.utils.createResponse$(() => ({
@@ -1105,7 +1038,7 @@ class DaffInMemoryBackendCartShippingInformationService {
1105
1038
  extra_attributes: this.extraFieldsHook(reqInfo, cart),
1106
1039
  };
1107
1040
  }
1108
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartShippingInformationService, deps: [{ token: DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK }, { token: i2.DaffInMemoryBackendProductService }], target: i0.ɵɵFactoryTarget.Injectable }); }
1041
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartShippingInformationService, deps: [{ token: DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK }, { token: i2$1.DaffInMemoryBackendProductService }], target: i0.ɵɵFactoryTarget.Injectable }); }
1109
1042
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartShippingInformationService, providedIn: 'root' }); }
1110
1043
  }
1111
1044
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartShippingInformationService, decorators: [{
@@ -1116,7 +1049,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
1116
1049
  }], ctorParameters: () => [{ type: undefined, decorators: [{
1117
1050
  type: Inject,
1118
1051
  args: [DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK]
1119
- }] }, { type: i2.DaffInMemoryBackendProductService }] });
1052
+ }] }, { type: i2$1.DaffInMemoryBackendProductService }] });
1120
1053
 
1121
1054
  /**
1122
1055
  * @inheritdoc
@@ -1124,6 +1057,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
1124
1057
  class DaffInMemoryBackendCartShippingMethodsService {
1125
1058
  constructor(shippingMethodFactory) {
1126
1059
  this.shippingMethodFactory = shippingMethodFactory;
1060
+ this.collectionName = DAFF_CART_IN_MEMORY_CART_SHIPPING_METHODS_COLLECTION_NAME;
1127
1061
  }
1128
1062
  get(reqInfo) {
1129
1063
  return reqInfo.utils.createResponse$(() => ({
@@ -1156,45 +1090,56 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
1156
1090
  }]
1157
1091
  }], ctorParameters: () => [{ type: i1$1.DaffCartShippingRateFactory }] });
1158
1092
 
1093
+ /**
1094
+ * The collections that the root service manages.
1095
+ * Useful for a higher-level backend that delegates to this one based on collection name.
1096
+ */
1097
+ const COLLECTION_NAMES = [
1098
+ 'cart',
1099
+ 'cart-items',
1100
+ 'cart-order',
1101
+ 'cart-coupon',
1102
+ 'cart-address',
1103
+ 'cart-shipping-address',
1104
+ 'cart-billing-address',
1105
+ 'cart-payment-methods',
1106
+ 'cart-shipping-methods',
1107
+ 'cart-payment',
1108
+ 'cart-shipping-information',
1109
+ ];
1159
1110
  /**
1160
1111
  * The root cart in-memory backend.
1161
1112
  * Creates the database and delegates requests to child backends.
1162
1113
  */
1163
- class DaffInMemoryBackendCartRootService {
1164
- /**
1165
- * The collections that the root service manages.
1166
- * Useful for a higher-level backend that delegates to this one based on collection name.
1167
- */
1168
- static { this.COLLECTION_NAMES = [
1169
- 'cart',
1170
- 'cart-items',
1171
- 'cart-order',
1172
- 'cart-coupon',
1173
- 'cart-address',
1174
- 'cart-shipping-address',
1175
- 'cart-billing-address',
1176
- 'cart-payment-methods',
1177
- 'cart-shipping-methods',
1178
- 'cart-payment',
1179
- 'cart-shipping-information',
1180
- ]; }
1114
+ class DaffInMemoryBackendCartRootService extends DaffInMemoryBackendDelegate {
1181
1115
  constructor(cartService, cartItemsService, cartOrderService, cartCouponService, cartAddressService, cartShippingAddressService, cartBillingAddressService, cartPaymentMethodsService, cartShippingMethodsService, cartPaymentService, cartShippingInformationService) {
1182
- this.cartService = cartService;
1183
- this.cartItemsService = cartItemsService;
1184
- this.cartOrderService = cartOrderService;
1185
- this.cartCouponService = cartCouponService;
1186
- this.cartAddressService = cartAddressService;
1187
- this.cartShippingAddressService = cartShippingAddressService;
1188
- this.cartBillingAddressService = cartBillingAddressService;
1189
- this.cartPaymentMethodsService = cartPaymentMethodsService;
1190
- this.cartShippingMethodsService = cartShippingMethodsService;
1191
- this.cartPaymentService = cartPaymentService;
1192
- this.cartShippingInformationService = cartShippingInformationService;
1116
+ super([
1117
+ cartService,
1118
+ cartItemsService,
1119
+ cartOrderService,
1120
+ cartCouponService,
1121
+ cartAddressService,
1122
+ cartShippingAddressService,
1123
+ cartBillingAddressService,
1124
+ cartPaymentMethodsService,
1125
+ cartShippingMethodsService,
1126
+ cartPaymentService,
1127
+ cartShippingInformationService,
1128
+ ]);
1193
1129
  /**
1194
1130
  * The collection of carts in the backend.
1195
1131
  */
1196
1132
  this.carts = [];
1197
1133
  }
1134
+ delegateRequest(reqInfo, method) {
1135
+ return super.delegateRequest({
1136
+ ...reqInfo,
1137
+ collection: this.carts,
1138
+ }, method);
1139
+ }
1140
+ canHandle(collectionName) {
1141
+ return COLLECTION_NAMES.includes(collectionName);
1142
+ }
1198
1143
  createDb(reqInfo) {
1199
1144
  if (reqInfo) {
1200
1145
  const seedData = reqInfo.utils.getJsonBody(reqInfo.req).carts;
@@ -1202,53 +1147,9 @@ class DaffInMemoryBackendCartRootService {
1202
1147
  this.carts = seedData;
1203
1148
  }
1204
1149
  }
1205
- return {
1150
+ return of({
1206
1151
  cart: this.carts,
1207
- };
1208
- }
1209
- get(reqInfo) {
1210
- return this.delegateRequest(reqInfo);
1211
- }
1212
- post(reqInfo) {
1213
- return this.delegateRequest(reqInfo);
1214
- }
1215
- put(reqInfo) {
1216
- return this.delegateRequest(reqInfo);
1217
- }
1218
- delete(reqInfo) {
1219
- return this.delegateRequest(reqInfo);
1220
- }
1221
- delegateRequest(reqInfo) {
1222
- reqInfo.collection = this.carts;
1223
- switch (reqInfo.collectionName) {
1224
- case 'cart':
1225
- return this.cartService[reqInfo.method](reqInfo);
1226
- case 'cart-items':
1227
- return this.cartItemsService[reqInfo.method](reqInfo);
1228
- case 'cart-order':
1229
- return this.cartOrderService[reqInfo.method](reqInfo);
1230
- case 'cart-coupon':
1231
- return this.cartCouponService[reqInfo.method](reqInfo);
1232
- case 'cart-address':
1233
- return this.cartAddressService[reqInfo.method](reqInfo);
1234
- case 'cart-shipping-address':
1235
- return this.cartShippingAddressService[reqInfo.method](reqInfo);
1236
- case 'cart-billing-address':
1237
- return this.cartBillingAddressService[reqInfo.method](reqInfo);
1238
- case 'cart-payment-methods':
1239
- return this.cartPaymentMethodsService[reqInfo.method](reqInfo);
1240
- case 'cart-shipping-methods':
1241
- return this.cartShippingMethodsService[reqInfo.method](reqInfo);
1242
- case 'cart-payment':
1243
- return this.cartPaymentService[reqInfo.method](reqInfo);
1244
- case 'cart-shipping-information':
1245
- return this.cartShippingInformationService[reqInfo.method](reqInfo);
1246
- default:
1247
- return reqInfo.utils.createResponse$(() => ({
1248
- body: {},
1249
- status: STATUS.OK,
1250
- }));
1251
- }
1152
+ });
1252
1153
  }
1253
1154
  /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartRootService, deps: [{ token: DaffInMemoryBackendCartService }, { token: DaffInMemoryBackendCartItemsService }, { token: DaffInMemoryBackendCartOrderService }, { token: DaffInMemoryBackendCartCouponService }, { token: DaffInMemoryBackendCartAddressService }, { token: DaffInMemoryBackendCartShippingAddressService }, { token: DaffInMemoryBackendCartBillingAddressService }, { token: DaffInMemoryBackendCartPaymentMethodsService }, { token: DaffInMemoryBackendCartShippingMethodsService }, { token: DaffInMemoryBackendCartPaymentService }, { token: DaffInMemoryBackendCartShippingInformationService }], target: i0.ɵɵFactoryTarget.Injectable }); }
1254
1155
  /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffInMemoryBackendCartRootService, providedIn: 'root' }); }
@@ -1260,9 +1161,42 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
1260
1161
  }]
1261
1162
  }], ctorParameters: () => [{ type: DaffInMemoryBackendCartService }, { type: DaffInMemoryBackendCartItemsService }, { type: DaffInMemoryBackendCartOrderService }, { type: DaffInMemoryBackendCartCouponService }, { type: DaffInMemoryBackendCartAddressService }, { type: DaffInMemoryBackendCartShippingAddressService }, { type: DaffInMemoryBackendCartBillingAddressService }, { type: DaffInMemoryBackendCartPaymentMethodsService }, { type: DaffInMemoryBackendCartShippingMethodsService }, { type: DaffInMemoryBackendCartPaymentService }, { type: DaffInMemoryBackendCartShippingInformationService }] });
1262
1163
 
1164
+ class DaffCartInMemoryDriverModule {
1165
+ static forRoot() {
1166
+ return {
1167
+ ngModule: DaffCartInMemoryDriverModule,
1168
+ providers: [
1169
+ provideDaffCartDriver(DaffInMemoryCartService),
1170
+ provideDaffCartAddressDriver(DaffInMemoryCartAddressService),
1171
+ provideDaffCartBillingAddressDriver(DaffInMemoryCartBillingAddressService),
1172
+ provideDaffCartItemDriver(DaffInMemoryCartItemService),
1173
+ provideDaffCartPaymentDriver(DaffInMemoryCartPaymentService),
1174
+ provideDaffCartPaymentMethodsDriver(DaffInMemoryCartPaymentMethodsService),
1175
+ provideDaffCartShippingAddressDriver(DaffInMemoryCartShippingAddressService),
1176
+ provideDaffCartShippingInformationDriver(DaffInMemoryCartShippingInformationService),
1177
+ provideDaffCartShippingMethodsDriver(DaffInMemoryCartShippingMethodsService),
1178
+ provideDaffCartOrderDriver(DaffInMemoryCartOrderService),
1179
+ provideDaffCartCouponDriver(DaffInMemoryCartCouponService),
1180
+ provideDaffInMemoryBackends(DaffInMemoryBackendCartRootService),
1181
+ ],
1182
+ };
1183
+ }
1184
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffCartInMemoryDriverModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1185
+ /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.2", ngImport: i0, type: DaffCartInMemoryDriverModule, imports: [CommonModule] }); }
1186
+ /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffCartInMemoryDriverModule, imports: [CommonModule] }); }
1187
+ }
1188
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DaffCartInMemoryDriverModule, decorators: [{
1189
+ type: NgModule,
1190
+ args: [{
1191
+ imports: [
1192
+ CommonModule,
1193
+ ],
1194
+ }]
1195
+ }] });
1196
+
1263
1197
  /**
1264
1198
  * Generated bundle index. Do not edit.
1265
1199
  */
1266
1200
 
1267
- export { DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK, DaffCartInMemoryDriverModule, DaffInMemoryBackendCartAddressService, DaffInMemoryBackendCartBillingAddressService, DaffInMemoryBackendCartCouponService, DaffInMemoryBackendCartItemsService, DaffInMemoryBackendCartOrderService, DaffInMemoryBackendCartPaymentMethodsService, DaffInMemoryBackendCartPaymentService, DaffInMemoryBackendCartRootService, DaffInMemoryBackendCartService, DaffInMemoryBackendCartShippingAddressService, DaffInMemoryBackendCartShippingInformationService, DaffInMemoryBackendCartShippingMethodsService, DaffInMemoryCartBillingAddressService, DaffInMemoryCartCouponService, DaffInMemoryCartItemService, DaffInMemoryCartOrderService, DaffInMemoryCartPaymentMethodsService, DaffInMemoryCartPaymentService, DaffInMemoryCartService, DaffInMemoryCartShippingAddressService, DaffInMemoryCartShippingInformationService, DaffInMemoryCartShippingMethodsService };
1201
+ export { DAFF_CART_IN_MEMORY_CART_ADDRESS_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_BILLING_ADDRESS_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_COUPON_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_ITEMS_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_ORDER_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_PAYMENT_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_PAYMENT_METHODS_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_SHIPPING_ADDRESS_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_SHIPPING_COLLECTION_NAME, DAFF_CART_IN_MEMORY_CART_SHIPPING_METHODS_COLLECTION_NAME, DAFF_CART_IN_MEMORY_EXTRA_ATTRIBUTES_HOOK, DaffCartInMemoryDriverModule, DaffInMemoryBackendCartAddressService, DaffInMemoryBackendCartBillingAddressService, DaffInMemoryBackendCartCouponService, DaffInMemoryBackendCartItemsService, DaffInMemoryBackendCartOrderService, DaffInMemoryBackendCartPaymentMethodsService, DaffInMemoryBackendCartPaymentService, DaffInMemoryBackendCartRootService, DaffInMemoryBackendCartService, DaffInMemoryBackendCartShippingAddressService, DaffInMemoryBackendCartShippingInformationService, DaffInMemoryBackendCartShippingMethodsService, DaffInMemoryCartBillingAddressService, DaffInMemoryCartCouponService, DaffInMemoryCartItemService, DaffInMemoryCartOrderService, DaffInMemoryCartPaymentMethodsService, DaffInMemoryCartPaymentService, DaffInMemoryCartService, DaffInMemoryCartShippingAddressService, DaffInMemoryCartShippingInformationService, DaffInMemoryCartShippingMethodsService };
1268
1202
  //# sourceMappingURL=daffodil-cart-driver-in-memory.mjs.map