@typewoo/sdk 3.2.0 → 3.4.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.
- package/README.md +21 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/lib/configs/sdk.config.d.ts +56 -2
- package/dist/lib/configs/sdk.config.d.ts.map +1 -1
- package/dist/lib/configs/sdk.config.js +46 -23
- package/dist/lib/configs/sdk.config.js.map +1 -1
- package/dist/lib/extensions/index.d.ts +4 -0
- package/dist/lib/extensions/index.d.ts.map +1 -0
- package/dist/lib/extensions/index.js +5 -0
- package/dist/lib/extensions/index.js.map +1 -0
- package/dist/lib/extensions/loop/index.d.ts +3 -0
- package/dist/lib/extensions/loop/index.d.ts.map +1 -0
- package/dist/lib/extensions/loop/index.js +3 -0
- package/dist/lib/extensions/loop/index.js.map +1 -0
- package/dist/lib/extensions/loop/loop.d.ts +10 -0
- package/dist/lib/extensions/loop/loop.d.ts.map +1 -0
- package/dist/lib/extensions/loop/loop.js +82 -0
- package/dist/lib/extensions/loop/loop.js.map +1 -0
- package/dist/lib/extensions/loop/loop.options.d.ts +44 -0
- package/dist/lib/extensions/loop/loop.options.d.ts.map +1 -0
- package/dist/lib/extensions/loop/loop.options.js +2 -0
- package/dist/lib/extensions/loop/loop.options.js.map +1 -0
- package/dist/lib/extensions/paginated-request.d.ts +59 -0
- package/dist/lib/extensions/paginated-request.d.ts.map +1 -0
- package/dist/lib/extensions/paginated-request.js +70 -0
- package/dist/lib/extensions/paginated-request.js.map +1 -0
- package/dist/lib/http/http.client.d.ts +5 -0
- package/dist/lib/http/http.client.d.ts.map +1 -0
- package/dist/lib/http/http.client.js +22 -0
- package/dist/lib/http/http.client.js.map +1 -0
- package/dist/lib/http/http.d.ts +9 -0
- package/dist/lib/http/http.d.ts.map +1 -0
- package/dist/lib/http/http.helper.d.ts +32 -0
- package/dist/lib/http/http.helper.d.ts.map +1 -0
- package/dist/lib/http/http.helper.js +115 -0
- package/dist/lib/http/http.helper.js.map +1 -0
- package/dist/lib/http/http.js +28 -0
- package/dist/lib/http/http.js.map +1 -0
- package/dist/lib/http/http.request.d.ts +5 -0
- package/dist/lib/http/http.request.d.ts.map +1 -0
- package/dist/lib/http/http.request.js +96 -0
- package/dist/lib/http/http.request.js.map +1 -0
- package/dist/lib/http/index.d.ts +5 -0
- package/dist/lib/http/index.d.ts.map +1 -0
- package/dist/lib/http/index.js +5 -0
- package/dist/lib/http/index.js.map +1 -0
- package/dist/lib/interceptors/admin-auth.interceptor.d.ts.map +1 -1
- package/dist/lib/interceptors/admin-auth.interceptor.js +1 -1
- package/dist/lib/interceptors/admin-auth.interceptor.js.map +1 -1
- package/dist/lib/interceptors/cart.token.interceptor.js +1 -1
- package/dist/lib/interceptors/cart.token.interceptor.js.map +1 -1
- package/dist/lib/interceptors/nonce.interceptor.js +1 -1
- package/dist/lib/interceptors/nonce.interceptor.js.map +1 -1
- package/dist/lib/interceptors/refresh.token.interceptor.d.ts.map +1 -1
- package/dist/lib/interceptors/refresh.token.interceptor.js +5 -3
- package/dist/lib/interceptors/refresh.token.interceptor.js.map +1 -1
- package/dist/lib/interceptors/token.interceptor.js +1 -1
- package/dist/lib/interceptors/token.interceptor.js.map +1 -1
- package/dist/lib/sdk.d.ts.map +1 -1
- package/dist/lib/sdk.js +4 -2
- package/dist/lib/sdk.js.map +1 -1
- package/dist/lib/services/admin/coupon.service.d.ts +28 -8
- package/dist/lib/services/admin/coupon.service.d.ts.map +1 -1
- package/dist/lib/services/admin/coupon.service.js +38 -16
- package/dist/lib/services/admin/coupon.service.js.map +1 -1
- package/dist/lib/services/admin/customer.service.d.ts +9 -7
- package/dist/lib/services/admin/customer.service.d.ts.map +1 -1
- package/dist/lib/services/admin/customer.service.js +19 -15
- package/dist/lib/services/admin/customer.service.js.map +1 -1
- package/dist/lib/services/admin/data.service.d.ts +7 -6
- package/dist/lib/services/admin/data.service.d.ts.map +1 -1
- package/dist/lib/services/admin/data.service.js +13 -13
- package/dist/lib/services/admin/data.service.js.map +1 -1
- package/dist/lib/services/admin/order.service.d.ts +23 -21
- package/dist/lib/services/admin/order.service.d.ts.map +1 -1
- package/dist/lib/services/admin/order.service.js +47 -43
- package/dist/lib/services/admin/order.service.js.map +1 -1
- package/dist/lib/services/admin/payment-gateway.service.d.ts +6 -4
- package/dist/lib/services/admin/payment-gateway.service.d.ts.map +1 -1
- package/dist/lib/services/admin/payment-gateway.service.js +13 -9
- package/dist/lib/services/admin/payment-gateway.service.js.map +1 -1
- package/dist/lib/services/admin/product-attribute-term.service.d.ts +9 -7
- package/dist/lib/services/admin/product-attribute-term.service.d.ts.map +1 -1
- package/dist/lib/services/admin/product-attribute-term.service.js +19 -15
- package/dist/lib/services/admin/product-attribute-term.service.js.map +1 -1
- package/dist/lib/services/admin/product-attribute.service.d.ts +9 -7
- package/dist/lib/services/admin/product-attribute.service.d.ts.map +1 -1
- package/dist/lib/services/admin/product-attribute.service.js +19 -15
- package/dist/lib/services/admin/product-attribute.service.js.map +1 -1
- package/dist/lib/services/admin/product-brand.service.d.ts +9 -7
- package/dist/lib/services/admin/product-brand.service.d.ts.map +1 -1
- package/dist/lib/services/admin/product-brand.service.js +19 -15
- package/dist/lib/services/admin/product-brand.service.js.map +1 -1
- package/dist/lib/services/admin/product-category.service.d.ts +9 -7
- package/dist/lib/services/admin/product-category.service.d.ts.map +1 -1
- package/dist/lib/services/admin/product-category.service.js +19 -15
- package/dist/lib/services/admin/product-category.service.js.map +1 -1
- package/dist/lib/services/admin/product-review.service.d.ts +9 -7
- package/dist/lib/services/admin/product-review.service.d.ts.map +1 -1
- package/dist/lib/services/admin/product-review.service.js +19 -15
- package/dist/lib/services/admin/product-review.service.js.map +1 -1
- package/dist/lib/services/admin/product-tag.service.d.ts +9 -7
- package/dist/lib/services/admin/product-tag.service.d.ts.map +1 -1
- package/dist/lib/services/admin/product-tag.service.js +19 -15
- package/dist/lib/services/admin/product-tag.service.js.map +1 -1
- package/dist/lib/services/admin/product.service.d.ts +16 -14
- package/dist/lib/services/admin/product.service.d.ts.map +1 -1
- package/dist/lib/services/admin/product.service.js +35 -31
- package/dist/lib/services/admin/product.service.js.map +1 -1
- package/dist/lib/services/admin/refund.service.d.ts +3 -2
- package/dist/lib/services/admin/refund.service.d.ts.map +1 -1
- package/dist/lib/services/admin/refund.service.js +9 -5
- package/dist/lib/services/admin/refund.service.js.map +1 -1
- package/dist/lib/services/admin/report.service.d.ts +12 -10
- package/dist/lib/services/admin/report.service.d.ts.map +1 -1
- package/dist/lib/services/admin/report.service.js +27 -23
- package/dist/lib/services/admin/report.service.js.map +1 -1
- package/dist/lib/services/admin/setting.service.d.ts +7 -6
- package/dist/lib/services/admin/setting.service.d.ts.map +1 -1
- package/dist/lib/services/admin/setting.service.js +13 -13
- package/dist/lib/services/admin/setting.service.js.map +1 -1
- package/dist/lib/services/admin/shipping-class.service.d.ts +9 -7
- package/dist/lib/services/admin/shipping-class.service.d.ts.map +1 -1
- package/dist/lib/services/admin/shipping-class.service.js +19 -15
- package/dist/lib/services/admin/shipping-class.service.js.map +1 -1
- package/dist/lib/services/admin/shipping-method.service.d.ts +5 -3
- package/dist/lib/services/admin/shipping-method.service.d.ts.map +1 -1
- package/dist/lib/services/admin/shipping-method.service.js +11 -7
- package/dist/lib/services/admin/shipping-method.service.js.map +1 -1
- package/dist/lib/services/admin/shipping-zone.service.d.ts +14 -12
- package/dist/lib/services/admin/shipping-zone.service.d.ts.map +1 -1
- package/dist/lib/services/admin/shipping-zone.service.js +31 -27
- package/dist/lib/services/admin/shipping-zone.service.js.map +1 -1
- package/dist/lib/services/admin/system-status.service.d.ts +2 -1
- package/dist/lib/services/admin/system-status.service.d.ts.map +1 -1
- package/dist/lib/services/admin/system-status.service.js +3 -3
- package/dist/lib/services/admin/system-status.service.js.map +1 -1
- package/dist/lib/services/admin/tax.service.d.ts +13 -11
- package/dist/lib/services/admin/tax.service.d.ts.map +1 -1
- package/dist/lib/services/admin/tax.service.js +27 -23
- package/dist/lib/services/admin/tax.service.js.map +1 -1
- package/dist/lib/services/admin/webhook.service.d.ts +9 -7
- package/dist/lib/services/admin/webhook.service.d.ts.map +1 -1
- package/dist/lib/services/admin/webhook.service.js +19 -15
- package/dist/lib/services/admin/webhook.service.js.map +1 -1
- package/dist/lib/services/api.d.ts +3 -4
- package/dist/lib/services/api.d.ts.map +1 -1
- package/dist/lib/services/api.js +5 -19
- package/dist/lib/services/api.js.map +1 -1
- package/dist/lib/services/auth/auth.service.d.ts +7 -7
- package/dist/lib/services/auth/auth.service.d.ts.map +1 -1
- package/dist/lib/services/auth/auth.service.js +1 -1
- package/dist/lib/services/auth/auth.service.js.map +1 -1
- package/dist/lib/services/store/batch.service.d.ts +2 -1
- package/dist/lib/services/store/batch.service.d.ts.map +1 -1
- package/dist/lib/services/store/batch.service.js +2 -3
- package/dist/lib/services/store/batch.service.js.map +1 -1
- package/dist/lib/services/store/cart.coupon.service.d.ts +6 -5
- package/dist/lib/services/store/cart.coupon.service.d.ts.map +1 -1
- package/dist/lib/services/store/cart.coupon.service.js +11 -11
- package/dist/lib/services/store/cart.coupon.service.js.map +1 -1
- package/dist/lib/services/store/cart.extensions.service.d.ts +2 -1
- package/dist/lib/services/store/cart.extensions.service.d.ts.map +1 -1
- package/dist/lib/services/store/cart.extensions.service.js +2 -3
- package/dist/lib/services/store/cart.extensions.service.js.map +1 -1
- package/dist/lib/services/store/cart.item.service.d.ts +7 -6
- package/dist/lib/services/store/cart.item.service.d.ts.map +1 -1
- package/dist/lib/services/store/cart.item.service.js +7 -13
- package/dist/lib/services/store/cart.item.service.js.map +1 -1
- package/dist/lib/services/store/cart.service.d.ts +9 -8
- package/dist/lib/services/store/cart.service.d.ts.map +1 -1
- package/dist/lib/services/store/cart.service.js +9 -17
- package/dist/lib/services/store/cart.service.js.map +1 -1
- package/dist/lib/services/store/checkout.order.service.d.ts +2 -1
- package/dist/lib/services/store/checkout.order.service.d.ts.map +1 -1
- package/dist/lib/services/store/checkout.order.service.js +2 -3
- package/dist/lib/services/store/checkout.order.service.js.map +1 -1
- package/dist/lib/services/store/checkout.service.d.ts +4 -3
- package/dist/lib/services/store/checkout.service.d.ts.map +1 -1
- package/dist/lib/services/store/checkout.service.js +4 -7
- package/dist/lib/services/store/checkout.service.js.map +1 -1
- package/dist/lib/services/store/order.service.d.ts +2 -1
- package/dist/lib/services/store/order.service.d.ts.map +1 -1
- package/dist/lib/services/store/order.service.js +2 -3
- package/dist/lib/services/store/order.service.js.map +1 -1
- package/dist/lib/services/store/product.attribute.service.d.ts +3 -2
- package/dist/lib/services/store/product.attribute.service.d.ts.map +1 -1
- package/dist/lib/services/store/product.attribute.service.js +5 -5
- package/dist/lib/services/store/product.attribute.service.js.map +1 -1
- package/dist/lib/services/store/product.attribute.term.service.d.ts +3 -2
- package/dist/lib/services/store/product.attribute.term.service.d.ts.map +1 -1
- package/dist/lib/services/store/product.attribute.term.service.js +7 -5
- package/dist/lib/services/store/product.attribute.term.service.js.map +1 -1
- package/dist/lib/services/store/product.brand.service.d.ts +5 -3
- package/dist/lib/services/store/product.brand.service.d.ts.map +1 -1
- package/dist/lib/services/store/product.brand.service.js +9 -7
- package/dist/lib/services/store/product.brand.service.js.map +1 -1
- package/dist/lib/services/store/product.category.service.d.ts +5 -3
- package/dist/lib/services/store/product.category.service.d.ts.map +1 -1
- package/dist/lib/services/store/product.category.service.js +9 -7
- package/dist/lib/services/store/product.category.service.js.map +1 -1
- package/dist/lib/services/store/product.collection.data.service.d.ts +2 -1
- package/dist/lib/services/store/product.collection.data.service.d.ts.map +1 -1
- package/dist/lib/services/store/product.collection.data.service.js +3 -3
- package/dist/lib/services/store/product.collection.data.service.js.map +1 -1
- package/dist/lib/services/store/product.review.service.d.ts +3 -2
- package/dist/lib/services/store/product.review.service.d.ts.map +1 -1
- package/dist/lib/services/store/product.review.service.js +7 -5
- package/dist/lib/services/store/product.review.service.js.map +1 -1
- package/dist/lib/services/store/product.service.d.ts +5 -3
- package/dist/lib/services/store/product.service.d.ts.map +1 -1
- package/dist/lib/services/store/product.service.js +15 -13
- package/dist/lib/services/store/product.service.js.map +1 -1
- package/dist/lib/services/store/product.tag.service.d.ts +3 -2
- package/dist/lib/services/store/product.tag.service.d.ts.map +1 -1
- package/dist/lib/services/store/product.tag.service.js +7 -5
- package/dist/lib/services/store/product.tag.service.js.map +1 -1
- package/dist/lib/storage/auth.storage.d.ts +27 -0
- package/dist/lib/storage/auth.storage.d.ts.map +1 -0
- package/dist/lib/storage/auth.storage.js +113 -0
- package/dist/lib/storage/auth.storage.js.map +1 -0
- package/dist/lib/types/admin/attribute.types.d.ts +9 -6
- package/dist/lib/types/admin/attribute.types.d.ts.map +1 -1
- package/dist/lib/types/admin/attribute.types.js +6 -6
- package/dist/lib/types/admin/attribute.types.js.map +1 -1
- package/dist/lib/types/admin/coupon.types.d.ts +127 -4
- package/dist/lib/types/admin/coupon.types.d.ts.map +1 -1
- package/dist/lib/types/admin/coupon.types.js +3 -3
- package/dist/lib/types/admin/coupon.types.js.map +1 -1
- package/dist/lib/types/admin/customer.types.d.ts +37 -5
- package/dist/lib/types/admin/customer.types.d.ts.map +1 -1
- package/dist/lib/types/admin/customer.types.js +7 -5
- package/dist/lib/types/admin/customer.types.js.map +1 -1
- package/dist/lib/types/admin/data.types.d.ts +4 -4
- package/dist/lib/types/admin/data.types.js +4 -4
- package/dist/lib/types/admin/data.types.js.map +1 -1
- package/dist/lib/types/admin/order.types.d.ts +31 -31
- package/dist/lib/types/admin/order.types.js +17 -17
- package/dist/lib/types/admin/order.types.js.map +1 -1
- package/dist/lib/types/admin/payment-gateway.types.d.ts +3 -3
- package/dist/lib/types/admin/payment-gateway.types.js +3 -3
- package/dist/lib/types/admin/payment-gateway.types.js.map +1 -1
- package/dist/lib/types/admin/product-brand.types.d.ts +6 -3
- package/dist/lib/types/admin/product-brand.types.d.ts.map +1 -1
- package/dist/lib/types/admin/product-brand.types.js +3 -3
- package/dist/lib/types/admin/product-brand.types.js.map +1 -1
- package/dist/lib/types/admin/product-review.types.d.ts +4 -4
- package/dist/lib/types/admin/product-review.types.js +3 -3
- package/dist/lib/types/admin/product-review.types.js.map +1 -1
- package/dist/lib/types/admin/product.types.d.ts +24 -23
- package/dist/lib/types/admin/product.types.d.ts.map +1 -1
- package/dist/lib/types/admin/product.types.js +12 -11
- package/dist/lib/types/admin/product.types.js.map +1 -1
- package/dist/lib/types/admin/refund.types.d.ts +12 -12
- package/dist/lib/types/admin/refund.types.js +7 -7
- package/dist/lib/types/admin/refund.types.js.map +1 -1
- package/dist/lib/types/admin/report.types.d.ts +11 -11
- package/dist/lib/types/admin/report.types.js +7 -7
- package/dist/lib/types/admin/report.types.js.map +1 -1
- package/dist/lib/types/admin/setting.types.d.ts +3 -3
- package/dist/lib/types/admin/setting.types.js +3 -3
- package/dist/lib/types/admin/setting.types.js.map +1 -1
- package/dist/lib/types/admin/shipping-method.types.d.ts +2 -2
- package/dist/lib/types/admin/shipping-method.types.js +2 -2
- package/dist/lib/types/admin/shipping-method.types.js.map +1 -1
- package/dist/lib/types/admin/shipping-zone.types.d.ts +8 -8
- package/dist/lib/types/admin/shipping-zone.types.js +8 -8
- package/dist/lib/types/admin/shipping-zone.types.js.map +1 -1
- package/dist/lib/types/admin/system-status.types.d.ts +2 -2
- package/dist/lib/types/admin/system-status.types.js +2 -2
- package/dist/lib/types/admin/system-status.types.js.map +1 -1
- package/dist/lib/types/admin/tax.types.d.ts +7 -7
- package/dist/lib/types/admin/tax.types.js +6 -6
- package/dist/lib/types/admin/tax.types.js.map +1 -1
- package/dist/lib/types/admin/taxonomy.types.d.ts +9 -9
- package/dist/lib/types/admin/taxonomy.types.js +9 -9
- package/dist/lib/types/admin/taxonomy.types.js.map +1 -1
- package/dist/lib/types/admin/webhook.types.d.ts +4 -4
- package/dist/lib/types/admin/webhook.types.js +3 -3
- package/dist/lib/types/admin/webhook.types.js.map +1 -1
- package/dist/lib/types/auth/one-time-token/auth.one.time.token.request.d.ts +1 -1
- package/dist/lib/types/auth/one-time-token/auth.one.time.token.request.js +1 -1
- package/dist/lib/types/auth/one-time-token/auth.one.time.token.request.js.map +1 -1
- package/dist/lib/types/auth/one-time-token/auth.one.time.token.response.d.ts +1 -1
- package/dist/lib/types/auth/one-time-token/auth.one.time.token.response.js +1 -1
- package/dist/lib/types/auth/one-time-token/auth.one.time.token.response.js.map +1 -1
- package/dist/lib/types/auth/refresh/auth.refresh.request.d.ts +1 -1
- package/dist/lib/types/auth/refresh/auth.refresh.request.js +1 -1
- package/dist/lib/types/auth/refresh/auth.refresh.request.js.map +1 -1
- package/dist/lib/types/auth/revoke/auth.revoke.request.d.ts +1 -1
- package/dist/lib/types/auth/revoke/auth.revoke.request.js +1 -1
- package/dist/lib/types/auth/revoke/auth.revoke.request.js.map +1 -1
- package/dist/lib/types/auth/revoke/auth.revoke.response.d.ts +1 -1
- package/dist/lib/types/auth/revoke/auth.revoke.response.js +1 -1
- package/dist/lib/types/auth/revoke/auth.revoke.response.js.map +1 -1
- package/dist/lib/types/auth/status/auth.status.response.d.ts +1 -1
- package/dist/lib/types/auth/status/auth.status.response.js +1 -1
- package/dist/lib/types/auth/status/auth.status.response.js.map +1 -1
- package/dist/lib/types/auth/token/auth.token.request.d.ts +1 -1
- package/dist/lib/types/auth/token/auth.token.request.js +1 -1
- package/dist/lib/types/auth/token/auth.token.request.js.map +1 -1
- package/dist/lib/types/auth/token/auth.token.response.d.ts +2 -2
- package/dist/lib/types/auth/token/auth.token.response.js +2 -2
- package/dist/lib/types/auth/token/auth.token.response.js.map +1 -1
- package/dist/lib/types/auth/validate/auth.validate.response.d.ts +2 -2
- package/dist/lib/types/auth/validate/auth.validate.response.js +2 -2
- package/dist/lib/types/auth/validate/auth.validate.response.js.map +1 -1
- package/dist/lib/types/request.d.ts +19 -0
- package/dist/lib/types/request.d.ts.map +1 -0
- package/dist/lib/types/request.js +2 -0
- package/dist/lib/types/request.js.map +1 -0
- package/dist/lib/types/sdk.state.d.ts +19 -19
- package/dist/lib/types/store/batch/batch.request.d.ts +38 -5
- package/dist/lib/types/store/batch/batch.request.d.ts.map +1 -1
- package/dist/lib/types/store/batch/batch.request.js +2 -2
- package/dist/lib/types/store/batch/batch.request.js.map +1 -1
- package/dist/lib/types/store/batch/batch.response.d.ts +24 -3
- package/dist/lib/types/store/batch/batch.response.d.ts.map +1 -1
- package/dist/lib/types/store/batch/batch.response.js +2 -2
- package/dist/lib/types/store/batch/batch.response.js.map +1 -1
- package/dist/lib/types/store/cart/cart.billing.response.d.ts +1 -1
- package/dist/lib/types/store/cart/cart.billing.response.js +1 -1
- package/dist/lib/types/store/cart/cart.billing.response.js.map +1 -1
- package/dist/lib/types/store/cart/cart.customer.request.d.ts +3 -3
- package/dist/lib/types/store/cart/cart.customer.request.js +3 -3
- package/dist/lib/types/store/cart/cart.customer.request.js.map +1 -1
- package/dist/lib/types/store/cart/cart.response.d.ts +19 -19
- package/dist/lib/types/store/cart/cart.response.js +1 -1
- package/dist/lib/types/store/cart/cart.response.js.map +1 -1
- package/dist/lib/types/store/cart/cart.shipping.rate.response.d.ts +5 -5
- package/dist/lib/types/store/cart/cart.shipping.rate.response.js +5 -5
- package/dist/lib/types/store/cart/cart.shipping.rate.response.js.map +1 -1
- package/dist/lib/types/store/cart/cart.shipping.response.d.ts +1 -1
- package/dist/lib/types/store/cart/cart.shipping.response.js +1 -1
- package/dist/lib/types/store/cart/cart.shipping.response.js.map +1 -1
- package/dist/lib/types/store/cart/cart.total.response.d.ts +2 -2
- package/dist/lib/types/store/cart/cart.total.response.js +2 -2
- package/dist/lib/types/store/cart/cart.total.response.js.map +1 -1
- package/dist/lib/types/store/cart-coupon/cart.coupon.response.d.ts +2 -2
- package/dist/lib/types/store/cart-coupon/cart.coupon.response.js +1 -1
- package/dist/lib/types/store/cart-coupon/cart.coupon.response.js.map +1 -1
- package/dist/lib/types/store/cart-coupon/cart.coupon.total.response.d.ts +1 -1
- package/dist/lib/types/store/cart-coupon/cart.coupon.total.response.js +1 -1
- package/dist/lib/types/store/cart-coupon/cart.coupon.total.response.js.map +1 -1
- package/dist/lib/types/store/cart-extensions/cart.extensions.request.d.ts +7 -1
- package/dist/lib/types/store/cart-extensions/cart.extensions.request.d.ts.map +1 -1
- package/dist/lib/types/store/cart-extensions/cart.extensions.request.js +1 -1
- package/dist/lib/types/store/cart-extensions/cart.extensions.request.js.map +1 -1
- package/dist/lib/types/store/cart-extensions/cart.extensions.response.d.ts +13 -1
- package/dist/lib/types/store/cart-extensions/cart.extensions.response.d.ts.map +1 -1
- package/dist/lib/types/store/cart-extensions/cart.extensions.response.js +1 -1
- package/dist/lib/types/store/cart-extensions/cart.extensions.response.js.map +1 -1
- package/dist/lib/types/store/cart-item/cart.item.add.request.d.ts +10 -1
- package/dist/lib/types/store/cart-item/cart.item.add.request.d.ts.map +1 -1
- package/dist/lib/types/store/cart-item/cart.item.add.request.js +1 -1
- package/dist/lib/types/store/cart-item/cart.item.add.request.js.map +1 -1
- package/dist/lib/types/store/cart-item/cart.item.edit.request.d.ts +7 -1
- package/dist/lib/types/store/cart-item/cart.item.edit.request.d.ts.map +1 -1
- package/dist/lib/types/store/cart-item/cart.item.edit.request.js +1 -1
- package/dist/lib/types/store/cart-item/cart.item.edit.request.js.map +1 -1
- package/dist/lib/types/store/cart-item/cart.item.price.response.d.ts +2 -2
- package/dist/lib/types/store/cart-item/cart.item.price.response.js +2 -2
- package/dist/lib/types/store/cart-item/cart.item.price.response.js.map +1 -1
- package/dist/lib/types/store/cart-item/cart.item.quantity.limits.response.d.ts +1 -1
- package/dist/lib/types/store/cart-item/cart.item.quantity.limits.response.js +1 -1
- package/dist/lib/types/store/cart-item/cart.item.quantity.limits.response.js.map +1 -1
- package/dist/lib/types/store/cart-item/cart.item.response.d.ts +7 -7
- package/dist/lib/types/store/cart-item/cart.item.response.js +1 -1
- package/dist/lib/types/store/cart-item/cart.item.response.js.map +1 -1
- package/dist/lib/types/store/cart-item/cart.item.total.response.d.ts +1 -1
- package/dist/lib/types/store/cart-item/cart.item.total.response.js +1 -1
- package/dist/lib/types/store/cart-item/cart.item.total.response.js.map +1 -1
- package/dist/lib/types/store/cart-item/cart.item.variation.response.d.ts +1 -1
- package/dist/lib/types/store/cart-item/cart.item.variation.response.js +1 -1
- package/dist/lib/types/store/cart-item/cart.item.variation.response.js.map +1 -1
- package/dist/lib/types/store/checkout/checkout.billing.response.d.ts +1 -1
- package/dist/lib/types/store/checkout/checkout.billing.response.js +1 -1
- package/dist/lib/types/store/checkout/checkout.billing.response.js.map +1 -1
- package/dist/lib/types/store/checkout/checkout.create.request.d.ts +22 -4
- package/dist/lib/types/store/checkout/checkout.create.request.d.ts.map +1 -1
- package/dist/lib/types/store/checkout/checkout.create.request.js +2 -2
- package/dist/lib/types/store/checkout/checkout.create.request.js.map +1 -1
- package/dist/lib/types/store/checkout/checkout.response.d.ts +4 -4
- package/dist/lib/types/store/checkout/checkout.response.js +2 -2
- package/dist/lib/types/store/checkout/checkout.response.js.map +1 -1
- package/dist/lib/types/store/checkout/checkout.shipping.d.ts +1 -1
- package/dist/lib/types/store/checkout/checkout.shipping.js +1 -1
- package/dist/lib/types/store/checkout/checkout.shipping.js.map +1 -1
- package/dist/lib/types/store/checkout/checkout.update.request.d.ts +10 -1
- package/dist/lib/types/store/checkout/checkout.update.request.d.ts.map +1 -1
- package/dist/lib/types/store/checkout/checkout.update.request.js +1 -1
- package/dist/lib/types/store/checkout/checkout.update.request.js.map +1 -1
- package/dist/lib/types/store/image.response.d.ts +1 -1
- package/dist/lib/types/store/image.response.js +1 -1
- package/dist/lib/types/store/image.response.js.map +1 -1
- package/dist/lib/types/store/order/order.billing.response.d.ts +1 -1
- package/dist/lib/types/store/order/order.billing.response.js +1 -1
- package/dist/lib/types/store/order/order.billing.response.js.map +1 -1
- package/dist/lib/types/store/order/order.coupon.response.d.ts +2 -2
- package/dist/lib/types/store/order/order.coupon.response.js +2 -2
- package/dist/lib/types/store/order/order.coupon.response.js.map +1 -1
- package/dist/lib/types/store/order/order.request.d.ts +22 -4
- package/dist/lib/types/store/order/order.request.d.ts.map +1 -1
- package/dist/lib/types/store/order/order.request.js +2 -2
- package/dist/lib/types/store/order/order.request.js.map +1 -1
- package/dist/lib/types/store/order/order.response.d.ts +13 -13
- package/dist/lib/types/store/order/order.response.js +1 -1
- package/dist/lib/types/store/order/order.response.js.map +1 -1
- package/dist/lib/types/store/order/order.shipping.response.d.ts +1 -1
- package/dist/lib/types/store/order/order.shipping.response.js +1 -1
- package/dist/lib/types/store/order/order.shipping.response.js.map +1 -1
- package/dist/lib/types/store/order/order.total.response.d.ts +1 -1
- package/dist/lib/types/store/order/order.total.response.js +1 -1
- package/dist/lib/types/store/order/order.total.response.js.map +1 -1
- package/dist/lib/types/store/product/product.price.response.d.ts +1 -1
- package/dist/lib/types/store/product/product.price.response.js +1 -1
- package/dist/lib/types/store/product/product.price.response.js.map +1 -1
- package/dist/lib/types/store/product/product.request.d.ts +1 -1
- package/dist/lib/types/store/product/product.request.js +1 -1
- package/dist/lib/types/store/product/product.response.d.ts +8 -8
- package/dist/lib/types/store/product/product.response.js +6 -6
- package/dist/lib/types/store/product/product.response.js.map +1 -1
- package/dist/lib/types/store/product-attribute/product.attribute.response.d.ts +1 -1
- package/dist/lib/types/store/product-attribute/product.attribute.response.js +1 -1
- package/dist/lib/types/store/product-attribute/product.attribute.response.js.map +1 -1
- package/dist/lib/types/store/product-attribute-term/product.attribute.term.request.d.ts +12 -1
- package/dist/lib/types/store/product-attribute-term/product.attribute.term.request.d.ts.map +1 -1
- package/dist/lib/types/store/product-attribute-term/product.attribute.term.request.js +2 -2
- package/dist/lib/types/store/product-attribute-term/product.attribute.term.request.js.map +1 -1
- package/dist/lib/types/store/product-attribute-term/product.attribute.term.response.d.ts +1 -1
- package/dist/lib/types/store/product-attribute-term/product.attribute.term.response.js +1 -1
- package/dist/lib/types/store/product-attribute-term/product.attribute.term.response.js.map +1 -1
- package/dist/lib/types/store/product-brand/product.brand.response.d.ts +2 -2
- package/dist/lib/types/store/product-brand/product.brand.response.js +1 -1
- package/dist/lib/types/store/product-brand/product.brand.response.js.map +1 -1
- package/dist/lib/types/store/product-category/product.category.response.d.ts +2 -2
- package/dist/lib/types/store/product-category/product.category.response.js +1 -1
- package/dist/lib/types/store/product-category/product.category.response.js.map +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.attribute.counts.response.d.ts +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.attribute.counts.response.d.ts.map +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.attribute.counts.response.js +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.attribute.counts.response.js.map +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.price.range.response.d.ts +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.price.range.response.js +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.price.range.response.js.map +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.rating.counts.response.d.ts +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.rating.counts.response.js +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.rating.counts.response.js.map +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.request.d.ts +24 -2
- package/dist/lib/types/store/product-collection-data/product.collection.data.request.d.ts.map +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.request.js +2 -2
- package/dist/lib/types/store/product-collection-data/product.collection.data.request.js.map +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.response.d.ts +5 -5
- package/dist/lib/types/store/product-collection-data/product.collection.data.response.js +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.response.js.map +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.taxonomy.counts.response.d.ts +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.taxonomy.counts.response.js +1 -1
- package/dist/lib/types/store/product-collection-data/product.collection.data.taxonomy.counts.response.js.map +1 -1
- package/dist/lib/types/store/product-review/product.review.response.d.ts +2 -2
- package/dist/lib/types/store/product-review/product.review.response.js +1 -1
- package/dist/lib/types/store/product-review/product.review.response.js.map +1 -1
- package/dist/lib/types/store/product-tag/product.tag.response.d.ts +1 -1
- package/dist/lib/types/store/product-tag/product.tag.response.js +1 -1
- package/dist/lib/types/store/product-tag/product.tag.response.js.map +1 -1
- package/dist/lib/utilities/axios.utility.d.ts +9 -7
- package/dist/lib/utilities/axios.utility.d.ts.map +1 -1
- package/dist/lib/utilities/axios.utility.js +155 -24
- package/dist/lib/utilities/axios.utility.js.map +1 -1
- package/dist/lib/utilities/paginated-request.d.ts +2 -0
- package/dist/lib/utilities/paginated-request.d.ts.map +1 -0
- package/dist/lib/utilities/paginated-request.js +2 -0
- package/dist/lib/utilities/paginated-request.js.map +1 -0
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __awaiter } from "tslib";
|
|
2
2
|
import { BaseService } from '../base.service.js';
|
|
3
|
-
import { doPost } from '../../
|
|
3
|
+
import { doPost } from '../../http/http.js';
|
|
4
4
|
/**
|
|
5
5
|
* Batch API
|
|
6
6
|
*
|
|
@@ -18,10 +18,9 @@ export class BatchService extends BaseService {
|
|
|
18
18
|
* @param params - Batch request parameters containing individual requests
|
|
19
19
|
* @returns {BatchResponse} - Batch response containing individual results
|
|
20
20
|
*/
|
|
21
|
-
execute(params) {
|
|
21
|
+
execute(params, options) {
|
|
22
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
23
23
|
const url = `/${this.endpoint}`;
|
|
24
|
-
const options = {};
|
|
25
24
|
this.events.emit('batch:loading', true);
|
|
26
25
|
this.events.emit('batch:request:start');
|
|
27
26
|
const { data, error } = yield doPost(url, params, options);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"batch.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/batch.service.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"batch.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/batch.service.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAK5C;;;;;GAKG;AACH,MAAM,OAAO,YAAa,SAAQ,WAAW;IAA7C;;QACmB,aAAQ,GAAG,2BAA2B,CAAC;IA6B1D,CAAC;IA3BC;;;;;OAKG;IACG,OAAO,CACX,MAAoB,EACpB,OAAwB;;YAExB,MAAM,GAAG,GAAG,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;YAEhC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,eAAe,EAAE,IAAI,CAAC,CAAC;YACxC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,qBAAqB,CAAC,CAAC;YAExC,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,MAAM,MAAM,CAClC,GAAG,EACH,MAAM,EACN,OAAO,CACR,CAAC;YAEF,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,EAAE,uBAAuB,CAAC,CAAC;YACpD,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,EAAE,qBAAqB,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;YAC9D,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,eAAe,EAAE,KAAK,CAAC,CAAC;YAEzC,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;QACzB,CAAC;KAAA;CACF"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { BaseService } from '../base.service.js';
|
|
2
2
|
import { ApiPaginationResult, ApiResult } from '../../types/api.js';
|
|
3
3
|
import { CartCouponResponse } from '../../types/index.js';
|
|
4
|
+
import { RequestOptions } from '../../types/request.js';
|
|
4
5
|
/**
|
|
5
6
|
* Cart Coupons API
|
|
6
7
|
*/
|
|
@@ -10,29 +11,29 @@ export declare class CartCouponService extends BaseService {
|
|
|
10
11
|
* List Cart Coupons
|
|
11
12
|
* @returns {CartCouponResponse[]}
|
|
12
13
|
*/
|
|
13
|
-
list(): Promise<ApiPaginationResult<CartCouponResponse[]>>;
|
|
14
|
+
list(options?: RequestOptions): Promise<ApiPaginationResult<CartCouponResponse[]>>;
|
|
14
15
|
/**
|
|
15
16
|
* Get a single cart coupon.
|
|
16
17
|
* @param code The coupon code of the cart coupon to retrieve.
|
|
17
18
|
* @returns {CartCouponResponse}
|
|
18
19
|
*/
|
|
19
|
-
single(code: string): Promise<ApiResult<CartCouponResponse>>;
|
|
20
|
+
single(code: string, options?: RequestOptions): Promise<ApiResult<CartCouponResponse>>;
|
|
20
21
|
/**
|
|
21
22
|
* Apply a coupon to the cart. Returns the new coupon object that was applied, or an error if it was not applied.
|
|
22
23
|
* @param code The coupon code you wish to apply to the cart.
|
|
23
24
|
* @returns {CartCouponResponse}
|
|
24
25
|
*/
|
|
25
|
-
add(code: string): Promise<ApiResult<CartCouponResponse>>;
|
|
26
|
+
add(code: string, options?: RequestOptions): Promise<ApiResult<CartCouponResponse>>;
|
|
26
27
|
/**
|
|
27
28
|
* Delete/remove a coupon from the cart.
|
|
28
29
|
* @param code The coupon code you wish to remove from the cart.
|
|
29
30
|
* @returns {unknown}
|
|
30
31
|
*/
|
|
31
|
-
delete(code: string): Promise<ApiResult<unknown>>;
|
|
32
|
+
delete(code: string, options?: RequestOptions): Promise<ApiResult<unknown>>;
|
|
32
33
|
/**
|
|
33
34
|
* Delete/remove all coupons from the cart.
|
|
34
35
|
* @returns {CartCouponResponse[]}
|
|
35
36
|
*/
|
|
36
|
-
clear(): Promise<ApiResult<CartCouponResponse[]>>;
|
|
37
|
+
clear(options?: RequestOptions): Promise<ApiResult<CartCouponResponse[]>>;
|
|
37
38
|
}
|
|
38
39
|
//# sourceMappingURL=cart.coupon.service.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cart.coupon.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.coupon.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAGjD,OAAO,EAAE,mBAAmB,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"cart.coupon.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.coupon.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAGjD,OAAO,EAAE,mBAAmB,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAExD;;GAEG;AACH,qBAAa,iBAAkB,SAAQ,WAAW;IAChD,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAsC;IAE/D;;;OAGG;IACG,IAAI,CACR,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,mBAAmB,CAAC,kBAAkB,EAAE,CAAC,CAAC;IAYrD;;;;OAIG;IACG,MAAM,CACV,IAAI,EAAE,MAAM,EACZ,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,kBAAkB,CAAC,CAAC;IAOzC;;;;OAIG;IACG,GAAG,CACP,IAAI,EAAE,MAAM,EACZ,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,kBAAkB,CAAC,CAAC;IAmBzC;;;;OAIG;IACG,MAAM,CACV,IAAI,EAAE,MAAM,EACZ,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;IAe9B;;;OAGG;IACG,KAAK,CACT,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,kBAAkB,EAAE,CAAC,CAAC;CAc5C"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __awaiter } from "tslib";
|
|
2
2
|
import { BaseService } from '../base.service.js';
|
|
3
|
-
import { doDelete, doGet, doPost } from '../../
|
|
3
|
+
import { doDelete, doGet, doPost } from '../../http/http.js';
|
|
4
4
|
import { extractPagination } from '../../utilities/common.js';
|
|
5
5
|
/**
|
|
6
6
|
* Cart Coupons API
|
|
@@ -14,10 +14,10 @@ export class CartCouponService extends BaseService {
|
|
|
14
14
|
* List Cart Coupons
|
|
15
15
|
* @returns {CartCouponResponse[]}
|
|
16
16
|
*/
|
|
17
|
-
list() {
|
|
17
|
+
list(options) {
|
|
18
18
|
return __awaiter(this, void 0, void 0, function* () {
|
|
19
19
|
const url = `/${this.endpoint}`;
|
|
20
|
-
const { data, error, headers } = yield doGet(url);
|
|
20
|
+
const { data, error, headers } = yield doGet(url, options);
|
|
21
21
|
const pagination = extractPagination(headers);
|
|
22
22
|
return { data, error, pagination };
|
|
23
23
|
});
|
|
@@ -27,10 +27,10 @@ export class CartCouponService extends BaseService {
|
|
|
27
27
|
* @param code The coupon code of the cart coupon to retrieve.
|
|
28
28
|
* @returns {CartCouponResponse}
|
|
29
29
|
*/
|
|
30
|
-
single(code) {
|
|
30
|
+
single(code, options) {
|
|
31
31
|
return __awaiter(this, void 0, void 0, function* () {
|
|
32
32
|
const url = `/${this.endpoint}/${code}`;
|
|
33
|
-
const { data, error } = yield doGet(url);
|
|
33
|
+
const { data, error } = yield doGet(url, options);
|
|
34
34
|
return { data, error };
|
|
35
35
|
});
|
|
36
36
|
}
|
|
@@ -39,12 +39,12 @@ export class CartCouponService extends BaseService {
|
|
|
39
39
|
* @param code The coupon code you wish to apply to the cart.
|
|
40
40
|
* @returns {CartCouponResponse}
|
|
41
41
|
*/
|
|
42
|
-
add(code) {
|
|
42
|
+
add(code, options) {
|
|
43
43
|
return __awaiter(this, void 0, void 0, function* () {
|
|
44
44
|
const url = `/${this.endpoint}?code=${code}`;
|
|
45
45
|
this.events.emit('cart:loading', true);
|
|
46
46
|
this.events.emit('cart:request:start');
|
|
47
|
-
const { data, error } = yield doPost(url);
|
|
47
|
+
const { data, error } = yield doPost(url, undefined, options);
|
|
48
48
|
this.events.emitIf(!!data, 'cart:request:success');
|
|
49
49
|
this.events.emitIf(!!error, 'cart:request:error', error);
|
|
50
50
|
this.events.emit('cart:loading', false);
|
|
@@ -56,12 +56,12 @@ export class CartCouponService extends BaseService {
|
|
|
56
56
|
* @param code The coupon code you wish to remove from the cart.
|
|
57
57
|
* @returns {unknown}
|
|
58
58
|
*/
|
|
59
|
-
delete(code) {
|
|
59
|
+
delete(code, options) {
|
|
60
60
|
return __awaiter(this, void 0, void 0, function* () {
|
|
61
61
|
const url = `/${this.endpoint}/${code}`;
|
|
62
62
|
this.events.emit('cart:loading', true);
|
|
63
63
|
this.events.emit('cart:request:start');
|
|
64
|
-
const { data, error } = yield doDelete(url);
|
|
64
|
+
const { data, error } = yield doDelete(url, options);
|
|
65
65
|
this.events.emitIf(!!data, 'cart:request:success');
|
|
66
66
|
this.events.emitIf(!!error, 'cart:request:error', error);
|
|
67
67
|
this.events.emit('cart:loading', false);
|
|
@@ -72,12 +72,12 @@ export class CartCouponService extends BaseService {
|
|
|
72
72
|
* Delete/remove all coupons from the cart.
|
|
73
73
|
* @returns {CartCouponResponse[]}
|
|
74
74
|
*/
|
|
75
|
-
clear() {
|
|
75
|
+
clear(options) {
|
|
76
76
|
return __awaiter(this, void 0, void 0, function* () {
|
|
77
77
|
const url = `/${this.endpoint}`;
|
|
78
78
|
this.events.emit('cart:loading', true);
|
|
79
79
|
this.events.emit('cart:request:start');
|
|
80
|
-
const { data, error } = yield doDelete(url);
|
|
80
|
+
const { data, error } = yield doDelete(url, options);
|
|
81
81
|
this.events.emitIf(!!data, 'cart:request:success');
|
|
82
82
|
this.events.emitIf(!!error, 'cart:request:error', error);
|
|
83
83
|
this.events.emit('cart:loading', false);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cart.coupon.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.coupon.service.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"cart.coupon.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.coupon.service.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAC7D,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAK9D;;GAEG;AACH,MAAM,OAAO,iBAAkB,SAAQ,WAAW;IAAlD;;QACmB,aAAQ,GAAG,kCAAkC,CAAC;IAyGjE,CAAC;IAvGC;;;OAGG;IACG,IAAI,CACR,OAAwB;;YAExB,MAAM,GAAG,GAAG,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;YAChC,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,GAAG,MAAM,KAAK,CAC1C,GAAG,EACH,OAAO,CACR,CAAC;YAEF,MAAM,UAAU,GAAG,iBAAiB,CAAC,OAAO,CAAC,CAAC;YAE9C,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,UAAU,EAAE,CAAC;QACrC,CAAC;KAAA;IAED;;;;OAIG;IACG,MAAM,CACV,IAAY,EACZ,OAAwB;;YAExB,MAAM,GAAG,GAAG,IAAI,IAAI,CAAC,QAAQ,IAAI,IAAI,EAAE,CAAC;YACxC,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,MAAM,KAAK,CAAqB,GAAG,EAAE,OAAO,CAAC,CAAC;YAEt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,CAAC,CAAC,CAAC,KAAK,EAAE,oBAAoB,EAAE,KAAK,CAAC,CAAC;YACzD,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;YAExC,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;QACzB,CAAC;KAAA;IAED;;;OAGG;IACG,KAAK,CACT,OAAwB;;YAExB,MAAM,GAAG,GAAG,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;YAEhC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,cAAc,EAAE,IAAI,CAAC,CAAC;YACvC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,oBAAoB,CAAC,CAAC;YAEvC,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,MAAM,QAAQ,CAAuB,GAAG,EAAE,OAAO,CAAC,CAAC;YAE3E,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,EAAE,sBAAsB,CAAC,CAAC;YACnD,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,EAAE,oBAAoB,EAAE,KAAK,CAAC,CAAC;YACzD,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;YAExC,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;QACzB,CAAC;KAAA;CACF"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { BaseService } from '../base.service.js';
|
|
2
2
|
import { ApiResult } from '../../types/api.js';
|
|
3
3
|
import { CartExtensionsRequest, CartExtensionsResponse } from '../../types/index.js';
|
|
4
|
+
import { RequestOptions } from '../../types/request.js';
|
|
4
5
|
/**
|
|
5
6
|
* Cart Extensions API
|
|
6
7
|
*
|
|
@@ -14,6 +15,6 @@ export declare class CartExtensionsService extends BaseService {
|
|
|
14
15
|
* @param params - Extension data to store
|
|
15
16
|
* @returns {CartExtensionsResponse} - Response indicating success/failure
|
|
16
17
|
*/
|
|
17
|
-
store(params: CartExtensionsRequest): Promise<ApiResult<CartExtensionsResponse>>;
|
|
18
|
+
store(params: CartExtensionsRequest, options?: RequestOptions): Promise<ApiResult<CartExtensionsResponse>>;
|
|
18
19
|
}
|
|
19
20
|
//# sourceMappingURL=cart.extensions.service.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cart.extensions.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.extensions.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"cart.extensions.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.extensions.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EACL,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAExD;;;;GAIG;AACH,qBAAa,qBAAsB,SAAQ,WAAW;IACpD,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAyC;IAElE;;;;;OAKG;IACG,KAAK,CACT,MAAM,EAAE,qBAAqB,EAC7B,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,sBAAsB,CAAC,CAAC;CAiB9C"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __awaiter } from "tslib";
|
|
2
2
|
import { BaseService } from '../base.service.js';
|
|
3
|
-
import { doPost } from '../../
|
|
3
|
+
import { doPost } from '../../http/http.js';
|
|
4
4
|
/**
|
|
5
5
|
* Cart Extensions API
|
|
6
6
|
*
|
|
@@ -17,10 +17,9 @@ export class CartExtensionsService extends BaseService {
|
|
|
17
17
|
* @param params - Extension data to store
|
|
18
18
|
* @returns {CartExtensionsResponse} - Response indicating success/failure
|
|
19
19
|
*/
|
|
20
|
-
store(params) {
|
|
20
|
+
store(params, options) {
|
|
21
21
|
return __awaiter(this, void 0, void 0, function* () {
|
|
22
22
|
const url = `/${this.endpoint}`;
|
|
23
|
-
const options = {};
|
|
24
23
|
this.events.emit('cart:extensions:loading', true);
|
|
25
24
|
this.events.emit('cart:extensions:request:start');
|
|
26
25
|
const { data, error } = yield doPost(url, params, options);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cart.extensions.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.extensions.service.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"cart.extensions.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.extensions.service.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAQ5C;;;;GAIG;AACH,MAAM,OAAO,qBAAsB,SAAQ,WAAW;IAAtD;;QACmB,aAAQ,GAAG,qCAAqC,CAAC;IA4BpE,CAAC;IA1BC;;;;;OAKG;IACG,KAAK,CACT,MAA6B,EAC7B,OAAwB;;YAExB,MAAM,GAAG,GAAG,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;YAEhC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,yBAAyB,EAAE,IAAI,CAAC,CAAC;YAClD,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,+BAA+B,CAAC,CAAC;YAElD,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,MAAM,MAAM,CAGlC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC;YAExB,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,EAAE,iCAAiC,CAAC,CAAC;YAC9D,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,EAAE,+BAA+B,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;YACxE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,yBAAyB,EAAE,KAAK,CAAC,CAAC;YAEnD,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;QACzB,CAAC;KAAA;CACF"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { BaseService } from '../base.service.js';
|
|
2
2
|
import { ApiPaginationResult, ApiResult } from '../../types/api.js';
|
|
3
3
|
import { CartItemResponse, CartItemAddRequest } from '../../types/index.js';
|
|
4
|
+
import { RequestOptions } from '../../types/request.js';
|
|
4
5
|
/**
|
|
5
6
|
* Cart Items API
|
|
6
7
|
*/
|
|
@@ -10,36 +11,36 @@ export declare class CartItemService extends BaseService {
|
|
|
10
11
|
* List Cart Items
|
|
11
12
|
* @returns {CartItemResponse[]}
|
|
12
13
|
*/
|
|
13
|
-
list(): Promise<ApiPaginationResult<CartItemResponse[]>>;
|
|
14
|
+
list(options?: RequestOptions): Promise<ApiPaginationResult<CartItemResponse[]>>;
|
|
14
15
|
/**
|
|
15
16
|
* Get a single cart item by its key.
|
|
16
17
|
* @param key The key of the cart item to retrieve.
|
|
17
18
|
* @returns {CartItemResponse}
|
|
18
19
|
*/
|
|
19
|
-
single(key: string): Promise<ApiResult<CartItemResponse>>;
|
|
20
|
+
single(key: string, options?: RequestOptions): Promise<ApiResult<CartItemResponse>>;
|
|
20
21
|
/**
|
|
21
22
|
* Add Cart Item
|
|
22
23
|
* @param params
|
|
23
24
|
* @returns {CartItemResponse}
|
|
24
25
|
*/
|
|
25
|
-
add(params: CartItemAddRequest): Promise<ApiResult<CartItemResponse>>;
|
|
26
|
+
add(params: CartItemAddRequest, options?: RequestOptions): Promise<ApiResult<CartItemResponse>>;
|
|
26
27
|
/**
|
|
27
28
|
* Edit Single Cart Item
|
|
28
29
|
* @param key The key of the cart item to edit.
|
|
29
30
|
* @param quantity Quantity of this item in the cart.
|
|
30
31
|
* @returns {CartItemResponse}
|
|
31
32
|
*/
|
|
32
|
-
update(key: string, quantity: number): Promise<ApiResult<CartItemResponse>>;
|
|
33
|
+
update(key: string, quantity: number, options?: RequestOptions): Promise<ApiResult<CartItemResponse>>;
|
|
33
34
|
/**
|
|
34
35
|
* Delete Single Cart Item
|
|
35
36
|
* @param key The key of the cart item to edit.
|
|
36
37
|
* @returns {unknown}
|
|
37
38
|
*/
|
|
38
|
-
remove(key: string): Promise<ApiResult<unknown>>;
|
|
39
|
+
remove(key: string, options?: RequestOptions): Promise<ApiResult<unknown>>;
|
|
39
40
|
/**
|
|
40
41
|
* Delete All Cart Items
|
|
41
42
|
* @returns {CartItemResponse[]}
|
|
42
43
|
*/
|
|
43
|
-
clear(): Promise<ApiResult<CartItemResponse[]>>;
|
|
44
|
+
clear(options?: RequestOptions): Promise<ApiResult<CartItemResponse[]>>;
|
|
44
45
|
}
|
|
45
46
|
//# sourceMappingURL=cart.item.service.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cart.item.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.item.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"cart.item.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.item.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAIjD,OAAO,EAAE,mBAAmB,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACpE,OAAO,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC5E,OAAO,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAExD;;GAEG;AACH,qBAAa,eAAgB,SAAQ,WAAW;IAC9C,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAoC;IAE7D;;;OAGG;IACG,IAAI,CACR,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,mBAAmB,CAAC,gBAAgB,EAAE,CAAC,CAAC;IAanD;;;;OAIG;IACG,MAAM,CACV,GAAG,EAAE,MAAM,EACX,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAAC;IAQvC;;;;OAIG;IACG,GAAG,CACP,MAAM,EAAE,kBAAkB,EAC1B,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAAC;IAoBvC;;;;;OAKG;IACG,MAAM,CACV,GAAG,EAAE,MAAM,EACX,QAAQ,EAAE,MAAM,EAChB,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAAC;IAoBvC;;;;OAIG;IACG,MAAM,CACV,GAAG,EAAE,MAAM,EACX,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;IAe9B;;;OAGG;IACG,KAAK,CACT,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,gBAAgB,EAAE,CAAC,CAAC;CAc1C"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __awaiter } from "tslib";
|
|
2
2
|
import { BaseService } from '../base.service.js';
|
|
3
|
-
import { doDelete, doGet, doPost, doPut
|
|
3
|
+
import { doDelete, doGet, doPost, doPut } from '../../http/http.js';
|
|
4
4
|
import { extractPagination } from '../../utilities/common.js';
|
|
5
5
|
import * as qs from 'qs';
|
|
6
6
|
/**
|
|
@@ -15,10 +15,9 @@ export class CartItemService extends BaseService {
|
|
|
15
15
|
* List Cart Items
|
|
16
16
|
* @returns {CartItemResponse[]}
|
|
17
17
|
*/
|
|
18
|
-
list() {
|
|
18
|
+
list(options) {
|
|
19
19
|
return __awaiter(this, void 0, void 0, function* () {
|
|
20
20
|
const url = `/${this.endpoint}`;
|
|
21
|
-
const options = {};
|
|
22
21
|
const { data, error, headers } = yield doGet(url, options);
|
|
23
22
|
const pagination = extractPagination(headers);
|
|
24
23
|
return { data, error, pagination };
|
|
@@ -29,10 +28,9 @@ export class CartItemService extends BaseService {
|
|
|
29
28
|
* @param key The key of the cart item to retrieve.
|
|
30
29
|
* @returns {CartItemResponse}
|
|
31
30
|
*/
|
|
32
|
-
single(key) {
|
|
31
|
+
single(key, options) {
|
|
33
32
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
33
|
const url = `/${this.endpoint}/${key}`;
|
|
35
|
-
const options = {};
|
|
36
34
|
const { data, error } = yield doGet(url, options);
|
|
37
35
|
return { data, error };
|
|
38
36
|
});
|
|
@@ -42,11 +40,10 @@ export class CartItemService extends BaseService {
|
|
|
42
40
|
* @param params
|
|
43
41
|
* @returns {CartItemResponse}
|
|
44
42
|
*/
|
|
45
|
-
add(params) {
|
|
43
|
+
add(params, options) {
|
|
46
44
|
return __awaiter(this, void 0, void 0, function* () {
|
|
47
45
|
const query = qs.stringify(params, { encode: true });
|
|
48
46
|
const url = `/${this.endpoint}?${query}`;
|
|
49
|
-
const options = {};
|
|
50
47
|
this.events.emit('cart:loading', true);
|
|
51
48
|
this.events.emit('cart:request:start');
|
|
52
49
|
const { data, error } = yield doPost(url, undefined, options);
|
|
@@ -62,11 +59,10 @@ export class CartItemService extends BaseService {
|
|
|
62
59
|
* @param quantity Quantity of this item in the cart.
|
|
63
60
|
* @returns {CartItemResponse}
|
|
64
61
|
*/
|
|
65
|
-
update(key, quantity) {
|
|
62
|
+
update(key, quantity, options) {
|
|
66
63
|
return __awaiter(this, void 0, void 0, function* () {
|
|
67
64
|
const query = qs.stringify({ quantity: quantity }, { encode: true });
|
|
68
65
|
const url = `/${this.endpoint}/${key}?${query}`;
|
|
69
|
-
const options = {};
|
|
70
66
|
this.events.emit('cart:loading', true);
|
|
71
67
|
this.events.emit('cart:request:start');
|
|
72
68
|
const { data, error } = yield doPut(url, undefined, options);
|
|
@@ -81,10 +77,9 @@ export class CartItemService extends BaseService {
|
|
|
81
77
|
* @param key The key of the cart item to edit.
|
|
82
78
|
* @returns {unknown}
|
|
83
79
|
*/
|
|
84
|
-
remove(key) {
|
|
80
|
+
remove(key, options) {
|
|
85
81
|
return __awaiter(this, void 0, void 0, function* () {
|
|
86
82
|
const url = `/${this.endpoint}/${key}`;
|
|
87
|
-
const options = {};
|
|
88
83
|
this.events.emit('cart:loading', true);
|
|
89
84
|
this.events.emit('cart:request:start');
|
|
90
85
|
const { data, error } = yield doDelete(url, options);
|
|
@@ -98,10 +93,9 @@ export class CartItemService extends BaseService {
|
|
|
98
93
|
* Delete All Cart Items
|
|
99
94
|
* @returns {CartItemResponse[]}
|
|
100
95
|
*/
|
|
101
|
-
clear() {
|
|
96
|
+
clear(options) {
|
|
102
97
|
return __awaiter(this, void 0, void 0, function* () {
|
|
103
98
|
const url = `/${this.endpoint}`;
|
|
104
|
-
const options = {};
|
|
105
99
|
this.events.emit('cart:loading', true);
|
|
106
100
|
this.events.emit('cart:request:start');
|
|
107
101
|
const { data, error } = yield doDelete(url, options);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cart.item.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.item.service.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"cart.item.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.item.service.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AACpE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAAO,KAAK,EAAE,MAAM,IAAI,CAAC;AAKzB;;GAEG;AACH,MA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AA;CACF"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { BaseService } from '../base.service.js';
|
|
2
2
|
import { ApiResult } from '../../types/api.js';
|
|
3
3
|
import { CartResponse, CartItemAddRequest, CartCustomerRequest } from '../../types/index.js';
|
|
4
|
+
import { RequestOptions } from '../../types/request.js';
|
|
4
5
|
/**
|
|
5
6
|
* Cart API
|
|
6
7
|
*
|
|
@@ -12,50 +13,50 @@ export declare class CartService extends BaseService {
|
|
|
12
13
|
* Get Cart
|
|
13
14
|
* @returns {CartResponse}
|
|
14
15
|
*/
|
|
15
|
-
get(): Promise<ApiResult<CartResponse>>;
|
|
16
|
+
get(options?: RequestOptions): Promise<ApiResult<CartResponse>>;
|
|
16
17
|
/**
|
|
17
18
|
* Add Item
|
|
18
19
|
* @param params
|
|
19
20
|
* @returns {CartResponse}
|
|
20
21
|
*/
|
|
21
|
-
add(params: CartItemAddRequest): Promise<ApiResult<CartResponse>>;
|
|
22
|
+
add(params: CartItemAddRequest, options?: RequestOptions): Promise<ApiResult<CartResponse>>;
|
|
22
23
|
/**
|
|
23
24
|
* Update Item
|
|
24
25
|
* @param key The key of the cart item to edit.
|
|
25
26
|
* @param quantity Quantity of this item in the cart.
|
|
26
27
|
* @returns {CartResponse}
|
|
27
28
|
*/
|
|
28
|
-
update(key: string, quantity: number): Promise<ApiResult<CartResponse>>;
|
|
29
|
+
update(key: string, quantity: number, options?: RequestOptions): Promise<ApiResult<CartResponse>>;
|
|
29
30
|
/**
|
|
30
31
|
* Remove Item
|
|
31
32
|
* @param key
|
|
32
33
|
* @returns {CartResponse}
|
|
33
34
|
*/
|
|
34
|
-
remove(key: string): Promise<ApiResult<CartResponse>>;
|
|
35
|
+
remove(key: string, options?: RequestOptions): Promise<ApiResult<CartResponse>>;
|
|
35
36
|
/**
|
|
36
37
|
* Apply Coupon
|
|
37
38
|
* @param code The coupon code you wish to apply to the cart.
|
|
38
39
|
* @returns {CartResponse}
|
|
39
40
|
*/
|
|
40
|
-
applyCoupon(code: string): Promise<ApiResult<CartResponse>>;
|
|
41
|
+
applyCoupon(code: string, options?: RequestOptions): Promise<ApiResult<CartResponse>>;
|
|
41
42
|
/**
|
|
42
43
|
* Remove Coupon
|
|
43
44
|
* @param code The coupon code you wish to remove from the cart.
|
|
44
45
|
* @returns {CartResponse}
|
|
45
46
|
*/
|
|
46
|
-
removeCoupon(code: string): Promise<ApiResult<CartResponse>>;
|
|
47
|
+
removeCoupon(code: string, options?: RequestOptions): Promise<ApiResult<CartResponse>>;
|
|
47
48
|
/**
|
|
48
49
|
* Update Customer
|
|
49
50
|
* @param body
|
|
50
51
|
* @returns {CartResponse}
|
|
51
52
|
*/
|
|
52
|
-
updateCustomer(body: CartCustomerRequest): Promise<ApiResult<CartResponse>>;
|
|
53
|
+
updateCustomer(body: CartCustomerRequest, options?: RequestOptions): Promise<ApiResult<CartResponse>>;
|
|
53
54
|
/**
|
|
54
55
|
* Select Shipping Rate
|
|
55
56
|
* @param packageId The ID of the shipping package within the cart.
|
|
56
57
|
* @param rateId The chosen rate ID for the package.
|
|
57
58
|
* @returns {CartResponse}s
|
|
58
59
|
*/
|
|
59
|
-
selectShippingRate(packageId: number, rateId: string): Promise<ApiResult<CartResponse>>;
|
|
60
|
+
selectShippingRate(packageId: number, rateId: string, options?: RequestOptions): Promise<ApiResult<CartResponse>>;
|
|
60
61
|
}
|
|
61
62
|
//# sourceMappingURL=cart.service.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cart.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.service.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"cart.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.service.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAAE,SAAS,EAAE,MAAM,oB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M,EACd,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC;CAoBpC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { __awaiter } from "tslib";
|
|
2
2
|
import * as qs from 'qs';
|
|
3
3
|
import { BaseService } from '../base.service.js';
|
|
4
|
-
import { doGet, doPost } from '../../
|
|
4
|
+
import { doGet, doPost } from '../../http/http.js';
|
|
5
5
|
/**
|
|
6
6
|
* Cart API
|
|
7
7
|
*
|
|
@@ -16,10 +16,9 @@ export class CartService extends BaseService {
|
|
|
16
16
|
* Get Cart
|
|
17
17
|
* @returns {CartResponse}
|
|
18
18
|
*/
|
|
19
|
-
get() {
|
|
19
|
+
get(options) {
|
|
20
20
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
21
|
const url = `/${this.endpoint}`;
|
|
22
|
-
const options = {};
|
|
23
22
|
this.events.emit('cart:loading', true);
|
|
24
23
|
this.events.emit('cart:request:start');
|
|
25
24
|
const { data, error } = yield doGet(url, options);
|
|
@@ -35,11 +34,10 @@ export class CartService extends BaseService {
|
|
|
35
34
|
* @param params
|
|
36
35
|
* @returns {CartResponse}
|
|
37
36
|
*/
|
|
38
|
-
add(params) {
|
|
37
|
+
add(params, options) {
|
|
39
38
|
return __awaiter(this, void 0, void 0, function* () {
|
|
40
39
|
const query = qs.stringify(params, { encode: true });
|
|
41
40
|
const url = `/${this.endpoint}/add-item?${query}`;
|
|
42
|
-
const options = {};
|
|
43
41
|
this.events.emit('cart:loading', true);
|
|
44
42
|
this.events.emit('cart:request:start');
|
|
45
43
|
const { data, error } = yield doPost(url, undefined, options);
|
|
@@ -56,11 +54,10 @@ export class CartService extends BaseService {
|
|
|
56
54
|
* @param quantity Quantity of this item in the cart.
|
|
57
55
|
* @returns {CartResponse}
|
|
58
56
|
*/
|
|
59
|
-
update(key, quantity) {
|
|
57
|
+
update(key, quantity, options) {
|
|
60
58
|
return __awaiter(this, void 0, void 0, function* () {
|
|
61
59
|
const query = qs.stringify({ key, quantity }, { encode: true });
|
|
62
60
|
const url = `/${this.endpoint}/update-item?${query}`;
|
|
63
|
-
const options = {};
|
|
64
61
|
this.events.emit('cart:loading', true);
|
|
65
62
|
this.events.emit('cart:request:start');
|
|
66
63
|
const { data, error } = yield doPost(url, undefined, options);
|
|
@@ -76,10 +73,9 @@ export class CartService extends BaseService {
|
|
|
76
73
|
* @param key
|
|
77
74
|
* @returns {CartResponse}
|
|
78
75
|
*/
|
|
79
|
-
remove(key) {
|
|
76
|
+
remove(key, options) {
|
|
80
77
|
return __awaiter(this, void 0, void 0, function* () {
|
|
81
78
|
const url = `/${this.endpoint}/remove-item?key=${key}`;
|
|
82
|
-
const options = {};
|
|
83
79
|
this.events.emit('cart:loading', true);
|
|
84
80
|
this.events.emit('cart:request:start');
|
|
85
81
|
const { data, error } = yield doPost(url, undefined, options);
|
|
@@ -95,10 +91,9 @@ export class CartService extends BaseService {
|
|
|
95
91
|
* @param code The coupon code you wish to apply to the cart.
|
|
96
92
|
* @returns {CartResponse}
|
|
97
93
|
*/
|
|
98
|
-
applyCoupon(code) {
|
|
94
|
+
applyCoupon(code, options) {
|
|
99
95
|
return __awaiter(this, void 0, void 0, function* () {
|
|
100
96
|
const url = `/${this.endpoint}/apply-coupon?code=${code}`;
|
|
101
|
-
const options = {};
|
|
102
97
|
this.events.emit('cart:loading', true);
|
|
103
98
|
this.events.emit('cart:request:start');
|
|
104
99
|
const { data, error } = yield doPost(url, undefined, options);
|
|
@@ -114,10 +109,9 @@ export class CartService extends BaseService {
|
|
|
114
109
|
* @param code The coupon code you wish to remove from the cart.
|
|
115
110
|
* @returns {CartResponse}
|
|
116
111
|
*/
|
|
117
|
-
removeCoupon(code) {
|
|
112
|
+
removeCoupon(code, options) {
|
|
118
113
|
return __awaiter(this, void 0, void 0, function* () {
|
|
119
114
|
const url = `/${this.endpoint}/remove-coupon?code=${code}`;
|
|
120
|
-
const options = {};
|
|
121
115
|
this.events.emit('cart:loading', true);
|
|
122
116
|
this.events.emit('cart:request:start');
|
|
123
117
|
const { data, error } = yield doPost(url, undefined, options);
|
|
@@ -133,10 +127,9 @@ export class CartService extends BaseService {
|
|
|
133
127
|
* @param body
|
|
134
128
|
* @returns {CartResponse}
|
|
135
129
|
*/
|
|
136
|
-
updateCustomer(body) {
|
|
130
|
+
updateCustomer(body, options) {
|
|
137
131
|
return __awaiter(this, void 0, void 0, function* () {
|
|
138
132
|
const url = `/${this.endpoint}/update-customer`;
|
|
139
|
-
const options = {};
|
|
140
133
|
this.events.emit('cart:loading', true);
|
|
141
134
|
this.events.emit('cart:request:start');
|
|
142
135
|
const { data, error } = yield doPost(url, body, options);
|
|
@@ -153,11 +146,10 @@ export class CartService extends BaseService {
|
|
|
153
146
|
* @param rateId The chosen rate ID for the package.
|
|
154
147
|
* @returns {CartResponse}s
|
|
155
148
|
*/
|
|
156
|
-
selectShippingRate(packageId, rateId) {
|
|
149
|
+
selectShippingRate(packageId, rateId, options) {
|
|
157
150
|
return __awaiter(this, void 0, void 0, function* () {
|
|
158
151
|
// Fixed: use query string form. Path segment form caused rest_no_route errors.
|
|
159
152
|
const url = `/${this.endpoint}/select-shipping-rate?package_id=${packageId}&rate_id=${rateId}`;
|
|
160
|
-
const options = {};
|
|
161
153
|
this.events.emit('cart:loading', true);
|
|
162
154
|
this.events.emit('cart:request:start');
|
|
163
155
|
const { data, error } = yield doPost(url, undefined, options);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cart.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.service.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,EAAE,MAAM,IAAI,CAAC;AACzB,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"cart.service.js","sourceRoot":"","sources":["../../../../src/lib/services/store/cart.service.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,EAAE,MAAM,IAAI,CAAC;AACzB,OAAO,EA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AS,YAAY,MAAM,EAAE,CAAC;YAE/F,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,cAAc,EAAE,IAAI,CAAC,CAAC;YACvC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,oBAAoB,CAAC,CAAC;YAEvC,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,MAAM,MAAM,CAClC,GAAG,EACH,SAAS,EACT,OAAO,CACR,CAAC;YAEF,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,EAAE,sBAAsB,CAAC,CAAC;YACnD,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,EAAE,oBAAoB,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;YAC7D,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,EAAE,cAAc,EAAE,IAAI,CAAC,CAAC;YACjD,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;YAExC,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;QACzB,CAAC;KAAA;CACF"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { BaseService } from '../base.service.js';
|
|
2
2
|
import { ApiResult } from '../../types/api.js';
|
|
3
3
|
import { OrderRequest, CheckoutResponse } from '../../types/index.js';
|
|
4
|
+
import { RequestOptions } from '../../types/request.js';
|
|
4
5
|
/**
|
|
5
6
|
* Checkout order API
|
|
6
7
|
*
|
|
@@ -14,6 +15,6 @@ export declare class CheckoutOrderService extends BaseService {
|
|
|
14
15
|
* @param params
|
|
15
16
|
* @returns
|
|
16
17
|
*/
|
|
17
|
-
order(orderId: number, params: OrderRequest): Promise<ApiResult<CheckoutResponse>>;
|
|
18
|
+
order(orderId: number, params: OrderRequest, options?: RequestOptions): Promise<ApiResult<CheckoutResponse>>;
|
|
18
19
|
}
|
|
19
20
|
//# sourceMappingURL=checkout.order.service.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkout.order.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/checkout.order.service.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"checkout.order.service.d.ts","sourceRoot":"","sources":["../../../../src/lib/services/store/checkout.order.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AACtE,OAAO,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAExD;;;;GAIG;AACH,qBAAa,oBAAqB,SAAQ,WAAW;IACnD,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAkC;IAE3D;;;;;OAKG;IACG,KAAK,CACT,OAAO,EAAE,MAAM,EACf,MAAM,EAAE,YAAY,EACpB,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAAC;CAWxC"}
|