@esolve/ng-esolve-connect 0.13.0 → 0.15.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 +2 -2
- package/esm2020/lib/account/address/esolve-address-record.interface.mjs +2 -0
- package/esm2020/lib/account/address/esolve-address-response.interface.mjs +2 -0
- package/esm2020/lib/account/address/esolve-address-result.model.mjs +11 -0
- package/esm2020/lib/account/address/esolve-address-set-data.interface.mjs +2 -0
- package/esm2020/lib/account/address/esolve-address-type.type.mjs +2 -0
- package/esm2020/lib/account/address/esolve-address.model.mjs +19 -0
- package/esm2020/lib/account/address/index.mjs +7 -0
- package/esm2020/lib/account/esolve-account.service.mjs +13 -17
- package/esm2020/lib/account/esolve-geocode-result.interface.mjs +2 -0
- package/esm2020/lib/account/esolve-location-update-result.model.mjs +8 -0
- package/esm2020/lib/account/index.mjs +7 -0
- package/esm2020/lib/account/password/esolve-change-password-result.model.mjs +8 -0
- package/esm2020/lib/account/password/esolve-forgot-password-get-result.interface.mjs +2 -0
- package/esm2020/lib/account/password/esolve-forgot-password-response.interface.mjs +2 -0
- package/esm2020/lib/account/password/esolve-reset-password-result.model.mjs +11 -0
- package/esm2020/lib/account/password/index.mjs +5 -0
- package/esm2020/lib/account/registration/esolve-registration-data.interface.mjs +2 -0
- package/esm2020/lib/account/registration/esolve-registration-post-response-item.interface.mjs +2 -0
- package/esm2020/lib/account/registration/esolve-registration-result.model.mjs +12 -0
- package/esm2020/lib/account/registration/index.mjs +4 -0
- package/esm2020/lib/account/transaction/esolve-transaction-address.model.mjs +16 -0
- package/esm2020/lib/account/transaction/esolve-transaction-client-record.interface.mjs +2 -0
- package/esm2020/lib/account/transaction/esolve-transaction-client.model.mjs +13 -0
- package/esm2020/lib/account/transaction/esolve-transaction-item-price.model.mjs +25 -0
- package/esm2020/lib/account/transaction/esolve-transaction-item-record.interface.mjs +2 -0
- package/esm2020/lib/account/transaction/esolve-transaction-item.model.mjs +12 -0
- package/esm2020/lib/account/transaction/esolve-transaction-list.model.mjs +4 -0
- package/esm2020/lib/account/transaction/esolve-transaction-location-record.interface.mjs +2 -0
- package/esm2020/lib/account/transaction/esolve-transaction-location.model.mjs +4 -0
- package/esm2020/lib/account/transaction/esolve-transaction-options.interface.mjs +2 -0
- package/esm2020/lib/account/transaction/esolve-transaction-payment-method-record.interface.mjs +2 -0
- package/esm2020/lib/account/transaction/esolve-transaction-payment-method.model.mjs +10 -0
- package/esm2020/lib/account/transaction/esolve-transaction-record.interface.mjs +2 -0
- package/esm2020/lib/account/transaction/esolve-transaction-shipping-method-record.interface.mjs +2 -0
- package/esm2020/lib/account/transaction/esolve-transaction-shipping-method.model.mjs +12 -0
- package/esm2020/lib/account/transaction/esolve-transaction-type.type.mjs +2 -0
- package/esm2020/lib/account/transaction/esolve-transaction-user-record.interface.mjs +2 -0
- package/esm2020/lib/account/transaction/esolve-transaction-user.model.mjs +11 -0
- package/esm2020/lib/account/transaction/esolve-transaction.model.mjs +58 -0
- package/esm2020/lib/account/transaction/index.mjs +23 -0
- package/esm2020/lib/account/user-account/esolve-user-account-business.model.mjs +9 -0
- package/esm2020/lib/account/user-account/esolve-user-account-contact.model.mjs +8 -0
- package/esm2020/lib/account/user-account/esolve-user-account-data.interface.mjs +2 -0
- package/esm2020/lib/account/user-account/esolve-user-account-record.interface.mjs +2 -0
- package/esm2020/lib/account/user-account/esolve-user-account-result.model.mjs +9 -0
- package/esm2020/lib/account/user-account/esolve-user-account.model.mjs +14 -0
- package/esm2020/lib/account/user-account/index.mjs +7 -0
- package/esm2020/lib/auth/esolve-auth-check-data.interface.mjs +2 -0
- package/esm2020/lib/auth/esolve-auth-check-response.interface.mjs +2 -0
- package/esm2020/lib/auth/esolve-auth-data.interface.mjs +2 -0
- package/esm2020/lib/auth/esolve-auth-get-data.interface.mjs +2 -0
- package/esm2020/lib/auth/esolve-auth-get-response.interface.mjs +2 -0
- package/esm2020/lib/auth/esolve-auth-interceptor.service.mjs +4 -4
- package/esm2020/lib/auth/esolve-auth-response-data.type.mjs +2 -0
- package/esm2020/lib/auth/esolve-auth-response.interface.mjs +2 -0
- package/esm2020/lib/auth/esolve-auth-result.type.mjs +2 -0
- package/esm2020/lib/auth/esolve-auth.service.mjs +3 -3
- package/esm2020/lib/auth/esolve-login-post-response-item.interface.mjs +2 -0
- package/esm2020/lib/auth/index.mjs +4 -0
- package/esm2020/lib/banners/esolve-banner-image-hotspot-coords.interface.mjs +2 -0
- package/esm2020/lib/banners/esolve-banner-image-hotspot-record.interface.mjs +2 -0
- package/esm2020/lib/banners/esolve-banner-image-hotspot.model.mjs +9 -0
- package/esm2020/lib/banners/esolve-banner-image-record.interface.mjs +2 -0
- package/esm2020/lib/banners/esolve-banner-image-set.interface.mjs +2 -0
- package/esm2020/lib/banners/esolve-banner-image-type.type.mjs +2 -0
- package/esm2020/lib/banners/esolve-banner-image.model.mjs +14 -0
- package/esm2020/lib/banners/esolve-banner-link.interface.mjs +2 -0
- package/esm2020/lib/banners/esolve-banner-record.interface.mjs +2 -0
- package/esm2020/lib/banners/esolve-banner-type.type.mjs +2 -0
- package/esm2020/lib/banners/esolve-banner.model.mjs +25 -0
- package/esm2020/lib/banners/esolve-banner.service.mjs +5 -5
- package/esm2020/lib/banners/index.mjs +14 -0
- package/esm2020/lib/cart/esolve-cart-item-record.interface.mjs +2 -0
- package/esm2020/lib/cart/esolve-cart-item-response.interface.mjs +2 -0
- package/esm2020/lib/cart/esolve-cart-item.model.mjs +24 -0
- package/esm2020/lib/cart/esolve-cart-set-action.type.mjs +2 -0
- package/esm2020/lib/cart/esolve-cart-set-item.interface.mjs +2 -0
- package/esm2020/lib/cart/esolve-cart-stock-item.model.mjs +49 -0
- package/esm2020/lib/cart/esolve-cart-totals-record.interface.mjs +2 -0
- package/esm2020/lib/cart/esolve-cart-totals.model.mjs +39 -0
- package/esm2020/lib/cart/esolve-cart.service.mjs +8 -8
- package/esm2020/lib/cart/esolve-cart.type.mjs +2 -0
- package/esm2020/lib/cart/esolve-checkout-response.interface.mjs +2 -0
- package/esm2020/lib/cart/esolve-checkout-result.model.mjs +9 -0
- package/esm2020/lib/cart/esolve-tracking-code.interface.mjs +2 -0
- package/esm2020/lib/cart/index.mjs +14 -0
- package/esm2020/lib/category-tree/esolve-category-identifier.interface.mjs +2 -0
- package/esm2020/lib/category-tree/esolve-category-record.interface.mjs +2 -0
- package/esm2020/lib/category-tree/esolve-category-tree-item-options.interface.mjs +2 -0
- package/esm2020/lib/category-tree/esolve-category-tree-item-record.interface.mjs +2 -0
- package/esm2020/lib/category-tree/esolve-category-tree-item.model.mjs +48 -0
- package/esm2020/lib/category-tree/esolve-category-tree.service.mjs +4 -4
- package/esm2020/lib/category-tree/esolve-subcategory-record.interface.mjs +2 -0
- package/esm2020/lib/category-tree/index.mjs +7 -0
- package/esm2020/lib/enquiry/esolve-enquiry-response.interface.mjs +2 -0
- package/esm2020/lib/enquiry/esolve-enquiry-result.model.mjs +9 -0
- package/esm2020/lib/enquiry/esolve-enquiry.service.mjs +41 -0
- package/esm2020/lib/enquiry/index.mjs +4 -0
- package/esm2020/lib/esolve-connect-config.constant.mjs +3 -0
- package/esm2020/lib/esolve-connect.config.mjs +2 -10
- package/esm2020/lib/locations/esolve-location-address.model.mjs +13 -0
- package/esm2020/lib/locations/esolve-location-contact-info.model.mjs +9 -0
- package/esm2020/lib/locations/esolve-location-pobox-address.model.mjs +8 -0
- package/esm2020/lib/locations/esolve-location-record.interface.mjs +2 -0
- package/esm2020/lib/locations/esolve-location-trading-day.model.mjs +7 -0
- package/esm2020/lib/locations/esolve-location-trading-times.model.mjs +14 -0
- package/esm2020/lib/locations/esolve-location.model.mjs +43 -0
- package/esm2020/lib/locations/esolve-locations.service.mjs +4 -4
- package/esm2020/lib/locations/index.mjs +9 -0
- package/esm2020/lib/manufacturers/esolve-manufacturer-options.interface.mjs +2 -0
- package/esm2020/lib/manufacturers/esolve-manufacturer-record.interface.mjs +2 -0
- package/esm2020/lib/manufacturers/esolve-manufacturer.model.mjs +41 -0
- package/esm2020/lib/manufacturers/esolve-manufacturers.service.mjs +3 -3
- package/esm2020/lib/manufacturers/index.mjs +5 -0
- package/esm2020/lib/media/esolve-heading-record.interface.mjs +2 -0
- package/esm2020/lib/media/esolve-heading.model.mjs +7 -0
- package/esm2020/lib/media/esolve-media-article.model.mjs +16 -0
- package/esm2020/lib/media/esolve-media-record.interface.mjs +2 -0
- package/esm2020/lib/media/esolve-media.service.mjs +6 -6
- package/esm2020/lib/media/index.mjs +6 -0
- package/esm2020/lib/menu/esolve-menu-item.model.mjs +9 -0
- package/esm2020/lib/menu/esolve-menu-tree-record.interface.mjs +2 -0
- package/esm2020/lib/menu/esolve-menu.service.mjs +3 -3
- package/esm2020/lib/menu/esolve-menu.type.mjs +2 -0
- package/esm2020/lib/menu/index.mjs +5 -0
- package/esm2020/lib/news/esolve-news-article-author-record.interface.mjs +2 -0
- package/esm2020/lib/news/esolve-news-article-author.model.mjs +9 -0
- package/esm2020/lib/news/esolve-news-article-list.model.mjs +8 -0
- package/esm2020/lib/news/esolve-news-article-options.interface.mjs +2 -0
- package/esm2020/lib/news/esolve-news-article-record.interface.mjs +2 -0
- package/esm2020/lib/news/esolve-news-article.model.mjs +20 -0
- package/esm2020/lib/news/esolve-news-group-record.interface.mjs +2 -0
- package/esm2020/lib/news/esolve-news-group.model.mjs +9 -0
- package/esm2020/lib/news/esolve-news-manufacturer-record.interface.mjs +2 -0
- package/esm2020/lib/news/esolve-news-range-record.interface.mjs +2 -0
- package/esm2020/lib/news/esolve-news.service.mjs +6 -6
- package/esm2020/lib/news/index.mjs +12 -0
- package/esm2020/lib/ng-esolve-connect.module.mjs +2 -2
- package/esm2020/lib/payment/esolve-banking-details.model.mjs +11 -0
- package/esm2020/lib/payment/esolve-card-data.interface.mjs +2 -0
- package/esm2020/lib/payment/esolve-integration-type.type.mjs +2 -0
- package/esm2020/lib/payment/esolve-paygate-form-input.interface.mjs +2 -0
- package/esm2020/lib/payment/esolve-payment-method-options.interface.mjs +2 -0
- package/esm2020/lib/payment/esolve-payment-method-record.interface.mjs +2 -0
- package/esm2020/lib/payment/esolve-payment-method.model.mjs +36 -0
- package/esm2020/lib/payment/esolve-payment-response.interface.mjs +2 -0
- package/esm2020/lib/payment/esolve-payment-result.model.mjs +22 -0
- package/esm2020/lib/payment/esolve-payment-set-body.interface.mjs +2 -0
- package/esm2020/lib/payment/esolve-payment.service.mjs +13 -13
- package/esm2020/lib/payment/esolve-vault-item-result.model.mjs +20 -0
- package/esm2020/lib/payment/esolve-vault-item.model.mjs +20 -0
- package/esm2020/lib/payment/esolve-vault-record.interface.mjs +2 -0
- package/esm2020/lib/payment/esolve-vault-response.interface.mjs +2 -0
- package/esm2020/lib/payment/index.mjs +15 -0
- package/esm2020/lib/ranges/esolve-range-options.interface.mjs +2 -0
- package/esm2020/lib/ranges/esolve-range-record.interface.mjs +2 -0
- package/esm2020/lib/ranges/esolve-range.model.mjs +33 -0
- package/esm2020/lib/ranges/esolve-ranges.service.mjs +4 -4
- package/esm2020/lib/ranges/index.mjs +5 -0
- package/esm2020/lib/session/esolve-session-data.interface.mjs +2 -0
- package/esm2020/lib/session/esolve-session.model.mjs +28 -0
- package/esm2020/lib/session/esolve-session.service.mjs +3 -3
- package/esm2020/lib/session/esolve-stored-session.interface.mjs +2 -0
- package/esm2020/lib/session/index.mjs +5 -0
- package/esm2020/lib/shared/assets/esolve-asset-type.type.mjs +2 -0
- package/esm2020/lib/shared/assets/esolve-linked-asset-record.interface.mjs +2 -0
- package/esm2020/lib/shared/assets/esolve-linked-asset.model.mjs +10 -0
- package/esm2020/lib/shared/assets/index.mjs +4 -4
- package/esm2020/lib/shared/custom-fields/esolve-custom-fields.type.mjs +2 -0
- package/esm2020/lib/shared/custom-fields/esolve-generic-custom-fields.interface.mjs +2 -0
- package/esm2020/lib/shared/custom-fields/index.mjs +3 -0
- package/esm2020/lib/shared/errors/esolve-error-handler.service.mjs +94 -0
- package/esm2020/lib/shared/errors/esolve-http-error.model.mjs +8 -0
- package/esm2020/lib/shared/errors/index.mjs +3 -0
- package/esm2020/lib/shared/esolve-list.model.mjs +9 -0
- package/esm2020/lib/shared/esolve-result.model.mjs +8 -0
- package/esm2020/lib/shared/esolve-url-target.type.mjs +2 -0
- package/esm2020/lib/shared/geocoder/esolve-geocode-address-record.interface.mjs +2 -0
- package/esm2020/lib/shared/geocoder/esolve-geocode-address-result.model.mjs +12 -0
- package/esm2020/lib/shared/geocoder/esolve-geocode-coords-result.model.mjs +7 -0
- package/esm2020/lib/shared/geocoder/esolve-geocode-result-record.interface.mjs +2 -0
- package/esm2020/lib/shared/geocoder/esolve-geocode-result.model.mjs +11 -0
- package/esm2020/lib/shared/geocoder/esolve-geocoder.service.mjs +5 -5
- package/esm2020/lib/shared/geocoder/index.mjs +7 -0
- package/esm2020/lib/shared/response/esolve-delete-response.interface.mjs +2 -0
- package/esm2020/lib/shared/response/esolve-delete-result.interface.mjs +2 -0
- package/esm2020/lib/shared/response/esolve-get-response.interface.mjs +2 -0
- package/esm2020/lib/shared/response/esolve-post-response-item.interface.mjs +2 -0
- package/esm2020/lib/shared/response/esolve-post-response-status.interface.mjs +2 -0
- package/esm2020/lib/shared/response/esolve-response-handler.service.mjs +34 -0
- package/esm2020/lib/shared/response/esolve-response-log-item.interface.mjs +2 -0
- package/esm2020/lib/shared/response/esolve-response-result.model.mjs +9 -0
- package/esm2020/lib/shared/response/esolve-response.interface.mjs +2 -0
- package/esm2020/lib/shared/response/esolve-set-response.interface.mjs +2 -0
- package/esm2020/lib/shared/response/index.mjs +11 -0
- package/esm2020/lib/shared/seo/esolve-seo-details.interface.mjs +2 -0
- package/esm2020/lib/shared/seo/esolve-seo-info.model.mjs +11 -0
- package/esm2020/lib/shared/seo/esolve-seo.service.mjs +15 -15
- package/esm2020/lib/shared/seo/index.mjs +4 -0
- package/esm2020/lib/shipping/esolve-insurance-calculation-method.type.mjs +2 -0
- package/esm2020/lib/shipping/esolve-shipping-calculation-method.type.mjs +2 -0
- package/esm2020/lib/shipping/esolve-shipping-cost-record.interface.mjs +2 -0
- package/esm2020/lib/shipping/esolve-shipping-cost.model.mjs +12 -0
- package/esm2020/lib/shipping/esolve-shipping-location.type.mjs +2 -0
- package/esm2020/lib/shipping/esolve-shipping-method-options.interface.mjs +2 -0
- package/esm2020/lib/shipping/esolve-shipping-method-record.interface.mjs +2 -0
- package/esm2020/lib/shipping/esolve-shipping-method.model.mjs +33 -0
- package/esm2020/lib/shipping/esolve-shipping-totals.model.mjs +8 -0
- package/esm2020/lib/shipping/esolve-shipping.service.mjs +17 -6
- package/esm2020/lib/shipping/index.mjs +11 -0
- package/esm2020/lib/specials/esolve-special-image-collection-record.interface.mjs +2 -0
- package/esm2020/lib/specials/esolve-special-image-collection.model.mjs +25 -0
- package/esm2020/lib/specials/esolve-special-image-record.interface.mjs +2 -0
- package/esm2020/lib/specials/esolve-special-image.model.mjs +9 -0
- package/esm2020/lib/specials/esolve-special-options.interface.mjs +2 -0
- package/esm2020/lib/specials/esolve-special-record.interface.mjs +2 -0
- package/esm2020/lib/specials/esolve-special.model.mjs +38 -0
- package/esm2020/lib/specials/esolve-specials.service.mjs +3 -3
- package/esm2020/lib/specials/index.mjs +8 -8
- package/esm2020/lib/stock/esolve-colour-record.interface.mjs +2 -0
- package/esm2020/lib/stock/esolve-colour.model.mjs +8 -0
- package/esm2020/lib/stock/esolve-linked-stock-item.model.mjs +9 -0
- package/esm2020/lib/stock/esolve-linked-stock-record.interface.mjs +2 -0
- package/esm2020/lib/stock/esolve-recipe-item-record.interface.mjs +2 -0
- package/esm2020/lib/stock/esolve-recipe-stock-item.model.mjs +9 -0
- package/esm2020/lib/stock/esolve-stock-badge-record.interface.mjs +2 -0
- package/esm2020/lib/stock/esolve-stock-badge.model.mjs +11 -0
- package/esm2020/lib/stock/esolve-stock-base-record.interface.mjs +2 -0
- package/esm2020/lib/stock/esolve-stock-group-item-record.interface.mjs +2 -0
- package/esm2020/lib/stock/esolve-stock-group-item.model.mjs +7 -0
- package/esm2020/lib/stock/esolve-stock-group.model.mjs +13 -0
- package/esm2020/lib/stock/esolve-stock-item-base.model.mjs +193 -0
- package/esm2020/lib/stock/esolve-stock-item-list.model.mjs +11 -0
- package/esm2020/lib/stock/esolve-stock-item-options.interface.mjs +2 -0
- package/esm2020/lib/stock/esolve-stock-item.model.mjs +17 -0
- package/esm2020/lib/stock/esolve-stock-linked-category-record.interface.mjs +2 -0
- package/esm2020/lib/stock/esolve-stock-price.model.mjs +43 -0
- package/esm2020/lib/stock/esolve-stock-record.interface.mjs +2 -0
- package/esm2020/lib/stock/esolve-stock.service.mjs +66 -25
- package/esm2020/lib/stock/index.mjs +24 -0
- package/esm2020/lib/tags/esolve-tag-record.interface.mjs +2 -0
- package/esm2020/lib/tags/esolve-tag.model.mjs +9 -0
- package/esm2020/lib/tags/index.mjs +3 -0
- package/esm2020/lib/topics/esolve-topic-record.interface.mjs +2 -0
- package/esm2020/lib/topics/esolve-topic.model.mjs +9 -0
- package/esm2020/lib/topics/esolve-topic.service.mjs +4 -4
- package/esm2020/lib/topics/index.mjs +4 -0
- package/esm2020/public-api.mjs +29 -85
- package/fesm2015/esolve-ng-esolve-connect.mjs +1383 -1139
- package/fesm2015/esolve-ng-esolve-connect.mjs.map +1 -1
- package/fesm2020/esolve-ng-esolve-connect.mjs +1377 -1139
- package/fesm2020/esolve-ng-esolve-connect.mjs.map +1 -1
- package/lib/account/{esolve-address-record.d.ts → address/esolve-address-record.interface.d.ts} +1 -1
- package/lib/account/{esolve-address-response.d.ts → address/esolve-address-response.interface.d.ts} +2 -2
- package/lib/account/{esolve-address-result.d.ts → address/esolve-address-result.model.d.ts} +3 -3
- package/lib/account/{esolve-address-set-data.d.ts → address/esolve-address-set-data.interface.d.ts} +1 -1
- package/lib/account/address/esolve-address-type.type.d.ts +1 -0
- package/lib/account/{esolve-address.d.ts → address/esolve-address.model.d.ts} +1 -1
- package/lib/account/address/index.d.ts +6 -0
- package/lib/account/esolve-account.service.d.ts +9 -17
- package/lib/account/{esolve-geocode-result.d.ts → esolve-geocode-result.interface.d.ts} +0 -0
- package/lib/account/esolve-location-update-result.model.d.ts +5 -0
- package/lib/account/index.d.ts +6 -0
- package/lib/account/password/esolve-change-password-result.model.d.ts +5 -0
- package/lib/account/password/esolve-forgot-password-get-result.interface.d.ts +3 -0
- package/lib/account/{esolve-forgot-password-response.d.ts → password/esolve-forgot-password-response.interface.d.ts} +2 -2
- package/lib/account/{esolve-reset-password-result.d.ts → password/esolve-reset-password-result.model.d.ts} +2 -2
- package/lib/account/password/index.d.ts +4 -0
- package/lib/account/{esolve-registration-data.d.ts → registration/esolve-registration-data.interface.d.ts} +0 -0
- package/lib/account/{esolve-registration-post-response-item.d.ts → registration/esolve-registration-post-response-item.interface.d.ts} +2 -2
- package/lib/account/{esolve-registration-result.d.ts → registration/esolve-registration-result.model.d.ts} +2 -2
- package/lib/account/registration/index.d.ts +3 -0
- package/lib/account/transaction/esolve-transaction-address.model.d.ts +15 -0
- package/lib/account/transaction/esolve-transaction-client-record.interface.d.ts +10 -0
- package/lib/account/transaction/esolve-transaction-client.model.d.ts +11 -0
- package/lib/account/transaction/esolve-transaction-item-price.model.d.ts +35 -0
- package/lib/account/transaction/esolve-transaction-item-record.interface.d.ts +16 -0
- package/lib/account/transaction/esolve-transaction-item.model.d.ts +11 -0
- package/lib/account/transaction/esolve-transaction-list.model.d.ts +4 -0
- package/lib/account/transaction/esolve-transaction-location-record.interface.d.ts +3 -0
- package/lib/account/transaction/esolve-transaction-location.model.d.ts +3 -0
- package/lib/account/{esolve-transaction-options.d.ts → transaction/esolve-transaction-options.interface.d.ts} +1 -1
- package/lib/account/transaction/esolve-transaction-payment-method-record.interface.d.ts +7 -0
- package/lib/account/transaction/esolve-transaction-payment-method.model.d.ts +8 -0
- package/lib/account/transaction/esolve-transaction-record.interface.d.ts +51 -0
- package/lib/account/transaction/esolve-transaction-shipping-method-record.interface.d.ts +9 -0
- package/lib/account/transaction/esolve-transaction-shipping-method.model.d.ts +10 -0
- package/lib/account/transaction/esolve-transaction-type.type.d.ts +1 -0
- package/lib/account/transaction/esolve-transaction-user-record.interface.d.ts +8 -0
- package/lib/account/transaction/esolve-transaction-user.model.d.ts +9 -0
- package/lib/account/transaction/esolve-transaction.model.d.ts +38 -0
- package/lib/account/transaction/index.d.ts +19 -0
- package/lib/account/user-account/esolve-user-account-business.model.d.ts +7 -0
- package/lib/account/user-account/esolve-user-account-contact.model.d.ts +6 -0
- package/lib/account/{esolve-user-account-data.d.ts → user-account/esolve-user-account-data.interface.d.ts} +0 -0
- package/lib/account/{esolve-user-account-record.d.ts → user-account/esolve-user-account-record.interface.d.ts} +0 -0
- package/lib/account/user-account/esolve-user-account-result.model.d.ts +5 -0
- package/lib/account/{esolve-user-account.d.ts → user-account/esolve-user-account.model.d.ts} +2 -13
- package/lib/account/user-account/index.d.ts +6 -0
- package/lib/auth/esolve-auth-check-data.interface.d.ts +3 -0
- package/lib/auth/esolve-auth-check-response.interface.d.ts +4 -0
- package/lib/auth/esolve-auth-data.interface.d.ts +5 -0
- package/lib/auth/esolve-auth-get-data.interface.d.ts +3 -0
- package/lib/auth/esolve-auth-get-response.interface.d.ts +4 -0
- package/lib/auth/esolve-auth-response-data.type.d.ts +3 -0
- package/lib/auth/esolve-auth-response.interface.d.ts +7 -0
- package/lib/auth/esolve-auth-result.type.d.ts +3 -0
- package/lib/auth/esolve-auth.service.d.ts +3 -3
- package/lib/auth/{esolve-login-post-response-item.d.ts → esolve-login-post-response-item.interface.d.ts} +2 -2
- package/lib/auth/index.d.ts +3 -0
- package/lib/banners/esolve-banner-image-hotspot-coords.interface.d.ts +4 -0
- package/lib/banners/{esolve-banner-image-hotspot-record.d.ts → esolve-banner-image-hotspot-record.interface.d.ts} +2 -2
- package/lib/banners/{esolve-banner-image-hotspot.d.ts → esolve-banner-image-hotspot.model.d.ts} +2 -5
- package/lib/banners/{esolve-banner-image-record.d.ts → esolve-banner-image-record.interface.d.ts} +2 -2
- package/lib/banners/esolve-banner-image-set.interface.d.ts +6 -0
- package/lib/banners/esolve-banner-image-type.type.d.ts +1 -0
- package/lib/banners/{esolve-banner-image.d.ts → esolve-banner-image.model.d.ts} +2 -2
- package/lib/banners/esolve-banner-link.interface.d.ts +5 -0
- package/lib/banners/{esolve-banner-record.d.ts → esolve-banner-record.interface.d.ts} +3 -2
- package/lib/banners/esolve-banner-type.type.d.ts +1 -0
- package/lib/banners/{esolve-banner.d.ts → esolve-banner.model.d.ts} +4 -7
- package/lib/banners/esolve-banner.service.d.ts +1 -1
- package/lib/banners/index.d.ts +9 -0
- package/lib/cart/{esolve-cart-item-record.d.ts → esolve-cart-item-record.interface.d.ts} +0 -0
- package/lib/cart/{esolve-cart-item-response.d.ts → esolve-cart-item-response.interface.d.ts} +1 -1
- package/lib/cart/{esolve-cart-item.d.ts → esolve-cart-item.model.d.ts} +1 -9
- package/lib/cart/esolve-cart-set-action.type.d.ts +1 -0
- package/lib/cart/esolve-cart-set-item.interface.d.ts +7 -0
- package/lib/cart/{esolve-cart-stock-item.d.ts → esolve-cart-stock-item.model.d.ts} +2 -1
- package/lib/cart/{esolve-cart-totals-record.d.ts → esolve-cart-totals-record.interface.d.ts} +0 -0
- package/lib/cart/{esolve-cart-totals.d.ts → esolve-cart-totals.model.d.ts} +4 -4
- package/lib/cart/esolve-cart.service.d.ts +8 -6
- package/lib/cart/esolve-cart.type.d.ts +2 -0
- package/lib/cart/esolve-checkout-response.interface.d.ts +4 -0
- package/lib/cart/esolve-checkout-result.model.d.ts +6 -0
- package/lib/cart/esolve-tracking-code.interface.d.ts +3 -0
- package/lib/cart/index.d.ts +13 -0
- package/lib/category-tree/esolve-category-identifier.interface.d.ts +4 -0
- package/lib/category-tree/esolve-category-record.interface.d.ts +18 -0
- package/lib/category-tree/{esolve-category-tree-item-options.d.ts → esolve-category-tree-item-options.interface.d.ts} +0 -0
- package/lib/category-tree/esolve-category-tree-item-record.interface.d.ts +17 -0
- package/lib/category-tree/{esolve-category-tree-item.d.ts → esolve-category-tree-item.model.d.ts} +7 -6
- package/lib/category-tree/esolve-category-tree.service.d.ts +2 -2
- package/lib/category-tree/esolve-subcategory-record.interface.d.ts +18 -0
- package/lib/category-tree/index.d.ts +6 -0
- package/lib/enquiry/esolve-enquiry-response.interface.d.ts +3 -0
- package/lib/enquiry/esolve-enquiry-result.model.d.ts +6 -0
- package/lib/enquiry/esolve-enquiry.service.d.ts +17 -0
- package/lib/enquiry/index.d.ts +3 -0
- package/lib/esolve-connect-config.constant.d.ts +3 -0
- package/lib/esolve-connect.config.d.ts +0 -2
- package/lib/locations/esolve-location-address.model.d.ts +11 -0
- package/lib/locations/esolve-location-contact-info.model.d.ts +7 -0
- package/lib/locations/esolve-location-pobox-address.model.d.ts +6 -0
- package/lib/locations/{esolve-stock-location-record.d.ts → esolve-location-record.interface.d.ts} +1 -1
- package/lib/locations/esolve-location-trading-day.model.d.ts +5 -0
- package/lib/locations/esolve-location-trading-times.model.d.ts +13 -0
- package/lib/locations/esolve-location.model.d.ts +23 -0
- package/lib/locations/esolve-locations.service.d.ts +2 -2
- package/lib/locations/index.d.ts +8 -0
- package/lib/manufacturers/{esolve-manufacturer-options.d.ts → esolve-manufacturer-options.interface.d.ts} +0 -0
- package/lib/manufacturers/{esolve-manufacturer-record.d.ts → esolve-manufacturer-record.interface.d.ts} +0 -0
- package/lib/manufacturers/{esolve-manufacturer.d.ts → esolve-manufacturer.model.d.ts} +6 -4
- package/lib/manufacturers/esolve-manufacturers.service.d.ts +2 -2
- package/lib/manufacturers/index.d.ts +4 -0
- package/lib/media/{esolve-heading-record.d.ts → esolve-heading-record.interface.d.ts} +0 -0
- package/lib/media/{esolve-heading.d.ts → esolve-heading.model.d.ts} +0 -0
- package/lib/media/esolve-media-article.model.d.ts +14 -0
- package/lib/media/{esolve-media-record.d.ts → esolve-media-record.interface.d.ts} +2 -2
- package/lib/media/esolve-media.service.d.ts +2 -2
- package/lib/media/index.d.ts +5 -0
- package/lib/menu/{esolve-menu-item.d.ts → esolve-menu-item.model.d.ts} +0 -1
- package/lib/menu/{esolve-menu-tree-record.d.ts → esolve-menu-tree-record.interface.d.ts} +0 -0
- package/lib/menu/esolve-menu.service.d.ts +1 -1
- package/lib/menu/esolve-menu.type.d.ts +2 -0
- package/lib/menu/index.d.ts +4 -0
- package/lib/news/{esolve-news-article-author-record.d.ts → esolve-news-article-author-record.interface.d.ts} +0 -0
- package/lib/news/{esolve-news-article-author.d.ts → esolve-news-article-author.model.d.ts} +0 -0
- package/lib/news/{esolve-news-article-list.d.ts → esolve-news-article-list.model.d.ts} +1 -1
- package/lib/news/{esolve-news-article-options.d.ts → esolve-news-article-options.interface.d.ts} +0 -0
- package/lib/news/{esolve-news-article-record.d.ts → esolve-news-article-record.interface.d.ts} +4 -4
- package/lib/news/{esolve-news-article.d.ts → esolve-news-article.model.d.ts} +5 -4
- package/lib/news/{esolve-news-group-record.d.ts → esolve-news-group-record.interface.d.ts} +0 -0
- package/lib/news/{esolve-news-group.d.ts → esolve-news-group.model.d.ts} +0 -0
- package/lib/news/{esolve-news-manufacturer-record.d.ts → esolve-news-manufacturer-record.interface.d.ts} +0 -0
- package/lib/news/{esolve-news-range-record.d.ts → esolve-news-range-record.interface.d.ts} +0 -0
- package/lib/news/esolve-news.service.d.ts +4 -4
- package/lib/news/index.d.ts +11 -0
- package/lib/payment/esolve-banking-details.model.d.ts +9 -0
- package/lib/payment/{esolve-card-data.d.ts → esolve-card-data.interface.d.ts} +0 -0
- package/lib/payment/esolve-integration-type.type.d.ts +1 -0
- package/lib/payment/esolve-paygate-form-input.interface.d.ts +4 -0
- package/lib/payment/{esolve-payment-method-options.d.ts → esolve-payment-method-options.interface.d.ts} +0 -0
- package/lib/payment/{esolve-payment-method-record.d.ts → esolve-payment-method-record.interface.d.ts} +1 -1
- package/lib/payment/{esolve-payment-method.d.ts → esolve-payment-method.model.d.ts} +3 -10
- package/lib/payment/{esolve-payment-response.d.ts → esolve-payment-response.interface.d.ts} +2 -5
- package/lib/payment/{esolve-payment-result.d.ts → esolve-payment-result.model.d.ts} +3 -2
- package/lib/payment/esolve-payment-set-body.interface.d.ts +13 -0
- package/lib/payment/esolve-payment.service.d.ts +9 -9
- package/lib/payment/{esolve-vault-item-result.d.ts → esolve-vault-item-result.model.d.ts} +2 -2
- package/lib/payment/{esolve-vault-item.d.ts → esolve-vault-item.model.d.ts} +0 -0
- package/lib/payment/{esolve-vault-record.d.ts → esolve-vault-record.interface.d.ts} +0 -0
- package/lib/payment/{esolve-vault-response.d.ts → esolve-vault-response.interface.d.ts} +1 -1
- package/lib/payment/index.d.ts +14 -0
- package/lib/ranges/{esolve-range-options.d.ts → esolve-range-options.interface.d.ts} +0 -0
- package/lib/ranges/{esolve-range-record.d.ts → esolve-range-record.interface.d.ts} +0 -0
- package/lib/ranges/{esolve-range.d.ts → esolve-range.model.d.ts} +5 -4
- package/lib/ranges/esolve-ranges.service.d.ts +2 -2
- package/lib/ranges/index.d.ts +4 -0
- package/lib/session/{esolve-session-data.d.ts → esolve-session-data.interface.d.ts} +0 -0
- package/lib/session/{esolve-session.d.ts → esolve-session.model.d.ts} +1 -1
- package/lib/session/esolve-session.service.d.ts +1 -1
- package/lib/session/{esolve-stored-session.d.ts → esolve-stored-session.interface.d.ts} +1 -1
- package/lib/session/index.d.ts +4 -0
- package/lib/shared/assets/{esolve-asset-type.d.ts → esolve-asset-type.type.d.ts} +0 -0
- package/lib/shared/assets/{esolve-linked-asset-record.d.ts → esolve-linked-asset-record.interface.d.ts} +1 -1
- package/lib/shared/assets/{esolve-linked-asset.d.ts → esolve-linked-asset.model.d.ts} +2 -2
- package/lib/shared/assets/index.d.ts +3 -3
- package/lib/shared/custom-fields/esolve-custom-fields.type.d.ts +4 -0
- package/lib/shared/custom-fields/esolve-generic-custom-fields.interface.d.ts +3 -0
- package/lib/shared/custom-fields/index.d.ts +2 -0
- package/lib/shared/{error-handler → errors}/esolve-error-handler.service.d.ts +3 -2
- package/lib/shared/{error-handler/esolve-http-error.d.ts → errors/esolve-http-error.model.d.ts} +0 -0
- package/lib/shared/errors/index.d.ts +2 -0
- package/lib/shared/{esolve-list.d.ts → esolve-list.model.d.ts} +0 -0
- package/lib/shared/{esolve-result.d.ts → esolve-result.model.d.ts} +0 -0
- package/lib/shared/{esolve-url-target.d.ts → esolve-url-target.type.d.ts} +0 -0
- package/lib/shared/geocoder/{esolve-geocode-address-record.d.ts → esolve-geocode-address-record.interface.d.ts} +0 -0
- package/lib/shared/geocoder/{esolve-geocode-address-result.d.ts → esolve-geocode-address-result.model.d.ts} +0 -0
- package/lib/shared/geocoder/{esolve-geocode-coords-result.d.ts → esolve-geocode-coords-result.model.d.ts} +0 -0
- package/lib/shared/geocoder/{esolve-geocode-result-record.d.ts → esolve-geocode-result-record.interface.d.ts} +1 -1
- package/lib/shared/geocoder/{esolve-geocode-result.d.ts → esolve-geocode-result.model.d.ts} +2 -2
- package/lib/shared/geocoder/esolve-geocoder.service.d.ts +1 -1
- package/lib/shared/geocoder/index.d.ts +6 -0
- package/lib/shared/response/esolve-delete-response.interface.d.ts +5 -0
- package/lib/shared/response/esolve-delete-result.interface.d.ts +6 -0
- package/lib/shared/response/esolve-get-response.interface.d.ts +4 -0
- package/lib/shared/response/esolve-post-response-item.interface.d.ts +9 -0
- package/lib/shared/response/esolve-post-response-status.interface.d.ts +5 -0
- package/lib/shared/{response-handler → response}/esolve-response-handler.service.d.ts +5 -2
- package/lib/shared/response/esolve-response-log-item.interface.d.ts +5 -0
- package/lib/shared/{response-handler/esolve-response-result.d.ts → response/esolve-response-result.model.d.ts} +2 -1
- package/lib/shared/response/esolve-response.interface.d.ts +8 -0
- package/lib/shared/response/esolve-set-response.interface.d.ts +5 -0
- package/lib/shared/response/index.d.ts +10 -0
- package/lib/shared/seo/esolve-seo-details.interface.d.ts +4 -0
- package/lib/shared/seo/{esolve-seo-info.d.ts → esolve-seo-info.model.d.ts} +1 -4
- package/lib/shared/seo/esolve-seo.service.d.ts +6 -6
- package/lib/shared/seo/index.d.ts +3 -0
- package/lib/shipping/esolve-insurance-calculation-method.type.d.ts +1 -0
- package/lib/shipping/esolve-shipping-calculation-method.type.d.ts +1 -0
- package/lib/shipping/{esolve-shipping-cost-record.d.ts → esolve-shipping-cost-record.interface.d.ts} +0 -0
- package/lib/shipping/{esolve-shipping-cost.d.ts → esolve-shipping-cost.model.d.ts} +1 -7
- package/lib/shipping/esolve-shipping-location.type.d.ts +1 -0
- package/lib/shipping/{esolve-shipping-method-options.d.ts → esolve-shipping-method-options.interface.d.ts} +0 -0
- package/lib/shipping/{esolve-shipping-method-record.d.ts → esolve-shipping-method-record.interface.d.ts} +6 -6
- package/lib/shipping/esolve-shipping-method.model.d.ts +34 -0
- package/lib/shipping/esolve-shipping-totals.model.d.ts +6 -0
- package/lib/shipping/esolve-shipping.service.d.ts +16 -5
- package/lib/shipping/index.d.ts +10 -0
- package/lib/specials/{esolve-special-image-collection-record.d.ts → esolve-special-image-collection-record.interface.d.ts} +1 -1
- package/lib/specials/{esolve-special-image-collection.d.ts → esolve-special-image-collection.model.d.ts} +2 -2
- package/lib/specials/{esolve-special-image-record.d.ts → esolve-special-image-record.interface.d.ts} +0 -0
- package/lib/specials/{esolve-special-image.d.ts → esolve-special-image.model.d.ts} +1 -1
- package/lib/specials/{esolve-special-options.d.ts → esolve-special-options.interface.d.ts} +0 -0
- package/lib/specials/{esolve-special-record.d.ts → esolve-special-record.interface.d.ts} +1 -1
- package/lib/specials/{esolve-special.d.ts → esolve-special.model.d.ts} +6 -5
- package/lib/specials/esolve-specials.service.d.ts +2 -2
- package/lib/specials/index.d.ts +7 -7
- package/lib/stock/esolve-colour-record.interface.d.ts +5 -0
- package/lib/stock/esolve-colour.model.d.ts +7 -0
- package/lib/stock/esolve-linked-stock-item.model.d.ts +7 -0
- package/lib/stock/esolve-linked-stock-record.interface.d.ts +7 -0
- package/lib/stock/esolve-recipe-item-record.interface.d.ts +7 -0
- package/lib/stock/esolve-recipe-stock-item.model.d.ts +7 -0
- package/lib/stock/{esolve-stock-badge-record.d.ts → esolve-stock-badge-record.interface.d.ts} +0 -0
- package/lib/stock/{esolve-stock-badge.d.ts → esolve-stock-badge.model.d.ts} +0 -0
- package/lib/stock/{esolve-stock-record.d.ts → esolve-stock-base-record.interface.d.ts} +17 -13
- package/lib/stock/esolve-stock-group-item-record.interface.d.ts +4 -0
- package/lib/stock/esolve-stock-group-item.model.d.ts +6 -0
- package/lib/stock/esolve-stock-group.model.d.ts +8 -0
- package/lib/stock/esolve-stock-item-base.model.d.ts +139 -0
- package/lib/stock/esolve-stock-item-list.model.d.ts +11 -0
- package/lib/stock/{esolve-stock-item-options.d.ts → esolve-stock-item-options.interface.d.ts} +0 -0
- package/lib/stock/esolve-stock-item.model.d.ts +14 -0
- package/lib/stock/esolve-stock-linked-category-record.interface.d.ts +5 -0
- package/lib/stock/{esolve-stock-price.d.ts → esolve-stock-price.model.d.ts} +10 -10
- package/lib/stock/esolve-stock-record.interface.d.ts +9 -0
- package/lib/stock/esolve-stock.service.d.ts +41 -10
- package/lib/stock/index.d.ts +20 -0
- package/lib/tags/{esolve-tag-record.d.ts → esolve-tag-record.interface.d.ts} +0 -0
- package/lib/tags/{esolve-tag.d.ts → esolve-tag.model.d.ts} +0 -0
- package/lib/tags/index.d.ts +2 -0
- package/lib/topics/{esolve-topic-record.d.ts → esolve-topic-record.interface.d.ts} +0 -0
- package/lib/topics/{esolve-topic.d.ts → esolve-topic.model.d.ts} +0 -0
- package/lib/topics/esolve-topic.service.d.ts +1 -1
- package/lib/topics/index.d.ts +3 -0
- package/package.json +1 -1
- package/public-api.d.ts +24 -81
- package/esm2020/lib/account/esolve-address-record.mjs +0 -2
- package/esm2020/lib/account/esolve-address-response.mjs +0 -2
- package/esm2020/lib/account/esolve-address-result.mjs +0 -11
- package/esm2020/lib/account/esolve-address-set-data.mjs +0 -2
- package/esm2020/lib/account/esolve-address.mjs +0 -19
- package/esm2020/lib/account/esolve-change-password-result.mjs +0 -8
- package/esm2020/lib/account/esolve-forgot-password-response.mjs +0 -2
- package/esm2020/lib/account/esolve-geocode-result.mjs +0 -2
- package/esm2020/lib/account/esolve-location-update-result.mjs +0 -8
- package/esm2020/lib/account/esolve-registration-data.mjs +0 -2
- package/esm2020/lib/account/esolve-registration-post-response-item.mjs +0 -2
- package/esm2020/lib/account/esolve-registration-result.mjs +0 -12
- package/esm2020/lib/account/esolve-reset-password-result.mjs +0 -11
- package/esm2020/lib/account/esolve-transaction-list.mjs +0 -4
- package/esm2020/lib/account/esolve-transaction-options.mjs +0 -2
- package/esm2020/lib/account/esolve-transaction-record.mjs +0 -2
- package/esm2020/lib/account/esolve-transaction.mjs +0 -145
- package/esm2020/lib/account/esolve-user-account-data.mjs +0 -2
- package/esm2020/lib/account/esolve-user-account-record.mjs +0 -2
- package/esm2020/lib/account/esolve-user-account-result.mjs +0 -9
- package/esm2020/lib/account/esolve-user-account.mjs +0 -29
- package/esm2020/lib/auth/esolve-auth-response.mjs +0 -4
- package/esm2020/lib/auth/esolve-login-post-response-item.mjs +0 -2
- package/esm2020/lib/banners/esolve-banner-image-hotspot-record.mjs +0 -2
- package/esm2020/lib/banners/esolve-banner-image-hotspot.mjs +0 -9
- package/esm2020/lib/banners/esolve-banner-image-record.mjs +0 -2
- package/esm2020/lib/banners/esolve-banner-image.mjs +0 -14
- package/esm2020/lib/banners/esolve-banner-record.mjs +0 -2
- package/esm2020/lib/banners/esolve-banner-type.mjs +0 -2
- package/esm2020/lib/banners/esolve-banner.mjs +0 -25
- package/esm2020/lib/cart/esolve-cart-item-record.mjs +0 -2
- package/esm2020/lib/cart/esolve-cart-item-response.mjs +0 -2
- package/esm2020/lib/cart/esolve-cart-item.mjs +0 -24
- package/esm2020/lib/cart/esolve-cart-stock-item.mjs +0 -43
- package/esm2020/lib/cart/esolve-cart-totals-record.mjs +0 -2
- package/esm2020/lib/cart/esolve-cart-totals.mjs +0 -39
- package/esm2020/lib/cart/esolve-checkout-result.mjs +0 -9
- package/esm2020/lib/cart/esolve-checkout.mjs +0 -2
- package/esm2020/lib/category-tree/esolve-category-tree-item-options.mjs +0 -2
- package/esm2020/lib/category-tree/esolve-category-tree-item-record.mjs +0 -2
- package/esm2020/lib/category-tree/esolve-category-tree-item.mjs +0 -48
- package/esm2020/lib/locations/esolve-stock-location-record.mjs +0 -2
- package/esm2020/lib/locations/esolve-stock-location.mjs +0 -76
- package/esm2020/lib/manufacturers/esolve-manufacturer-options.mjs +0 -2
- package/esm2020/lib/manufacturers/esolve-manufacturer-record.mjs +0 -2
- package/esm2020/lib/manufacturers/esolve-manufacturer.mjs +0 -38
- package/esm2020/lib/media/esolve-heading-record.mjs +0 -2
- package/esm2020/lib/media/esolve-heading.mjs +0 -7
- package/esm2020/lib/media/esolve-media-article.mjs +0 -16
- package/esm2020/lib/media/esolve-media-record.mjs +0 -2
- package/esm2020/lib/menu/esolve-menu-item.mjs +0 -9
- package/esm2020/lib/menu/esolve-menu-tree-record.mjs +0 -2
- package/esm2020/lib/news/esolve-news-article-author-record.mjs +0 -2
- package/esm2020/lib/news/esolve-news-article-author.mjs +0 -9
- package/esm2020/lib/news/esolve-news-article-list.mjs +0 -8
- package/esm2020/lib/news/esolve-news-article-options.mjs +0 -2
- package/esm2020/lib/news/esolve-news-article-record.mjs +0 -2
- package/esm2020/lib/news/esolve-news-article.mjs +0 -20
- package/esm2020/lib/news/esolve-news-group-record.mjs +0 -2
- package/esm2020/lib/news/esolve-news-group.mjs +0 -9
- package/esm2020/lib/news/esolve-news-manufacturer-record.mjs +0 -2
- package/esm2020/lib/news/esolve-news-range-record.mjs +0 -2
- package/esm2020/lib/payment/esolve-card-data.mjs +0 -2
- package/esm2020/lib/payment/esolve-payment-method-options.mjs +0 -2
- package/esm2020/lib/payment/esolve-payment-method-record.mjs +0 -2
- package/esm2020/lib/payment/esolve-payment-method.mjs +0 -45
- package/esm2020/lib/payment/esolve-payment-response.mjs +0 -2
- package/esm2020/lib/payment/esolve-payment-result.mjs +0 -22
- package/esm2020/lib/payment/esolve-vault-item-result.mjs +0 -20
- package/esm2020/lib/payment/esolve-vault-item.mjs +0 -20
- package/esm2020/lib/payment/esolve-vault-record.mjs +0 -2
- package/esm2020/lib/payment/esolve-vault-response.mjs +0 -2
- package/esm2020/lib/ranges/esolve-range-options.mjs +0 -2
- package/esm2020/lib/ranges/esolve-range-record.mjs +0 -2
- package/esm2020/lib/ranges/esolve-range.mjs +0 -33
- package/esm2020/lib/session/esolve-session-data.mjs +0 -2
- package/esm2020/lib/session/esolve-session.mjs +0 -28
- package/esm2020/lib/session/esolve-stored-session.mjs +0 -2
- package/esm2020/lib/shared/assets/esolve-asset-type.mjs +0 -2
- package/esm2020/lib/shared/assets/esolve-linked-asset-record.mjs +0 -2
- package/esm2020/lib/shared/assets/esolve-linked-asset.mjs +0 -10
- package/esm2020/lib/shared/error-handler/esolve-error-handler.service.mjs +0 -91
- package/esm2020/lib/shared/error-handler/esolve-http-error.mjs +0 -8
- package/esm2020/lib/shared/esolve-list.mjs +0 -9
- package/esm2020/lib/shared/esolve-response.mjs +0 -2
- package/esm2020/lib/shared/esolve-result.mjs +0 -8
- package/esm2020/lib/shared/esolve-url-target.mjs +0 -2
- package/esm2020/lib/shared/geocoder/esolve-geocode-address-record.mjs +0 -2
- package/esm2020/lib/shared/geocoder/esolve-geocode-address-result.mjs +0 -12
- package/esm2020/lib/shared/geocoder/esolve-geocode-coords-result.mjs +0 -7
- package/esm2020/lib/shared/geocoder/esolve-geocode-result-record.mjs +0 -2
- package/esm2020/lib/shared/geocoder/esolve-geocode-result.mjs +0 -11
- package/esm2020/lib/shared/response-handler/esolve-response-handler.service.mjs +0 -32
- package/esm2020/lib/shared/response-handler/esolve-response-result.mjs +0 -9
- package/esm2020/lib/shared/seo/esolve-seo-info.mjs +0 -11
- package/esm2020/lib/shipping/esolve-shipping-cost-record.mjs +0 -2
- package/esm2020/lib/shipping/esolve-shipping-cost.mjs +0 -18
- package/esm2020/lib/shipping/esolve-shipping-method-options.mjs +0 -2
- package/esm2020/lib/shipping/esolve-shipping-method-record.mjs +0 -2
- package/esm2020/lib/shipping/esolve-shipping-method.mjs +0 -33
- package/esm2020/lib/specials/esolve-special-image-collection-record.mjs +0 -2
- package/esm2020/lib/specials/esolve-special-image-collection.mjs +0 -25
- package/esm2020/lib/specials/esolve-special-image-record.mjs +0 -2
- package/esm2020/lib/specials/esolve-special-image.mjs +0 -9
- package/esm2020/lib/specials/esolve-special-options.mjs +0 -2
- package/esm2020/lib/specials/esolve-special-record.mjs +0 -2
- package/esm2020/lib/specials/esolve-special.mjs +0 -38
- package/esm2020/lib/stock/esolve-stock-badge-record.mjs +0 -2
- package/esm2020/lib/stock/esolve-stock-badge.mjs +0 -11
- package/esm2020/lib/stock/esolve-stock-item-list.mjs +0 -11
- package/esm2020/lib/stock/esolve-stock-item-options.mjs +0 -2
- package/esm2020/lib/stock/esolve-stock-item.mjs +0 -137
- package/esm2020/lib/stock/esolve-stock-price.mjs +0 -43
- package/esm2020/lib/stock/esolve-stock-record.mjs +0 -2
- package/esm2020/lib/tags/esolve-tag-record.mjs +0 -2
- package/esm2020/lib/tags/esolve-tag.mjs +0 -9
- package/esm2020/lib/topics/esolve-topic-record.mjs +0 -2
- package/esm2020/lib/topics/esolve-topic.mjs +0 -9
- package/lib/account/esolve-change-password-result.d.ts +0 -6
- package/lib/account/esolve-location-update-result.d.ts +0 -6
- package/lib/account/esolve-transaction-list.d.ts +0 -4
- package/lib/account/esolve-transaction-record.d.ts +0 -98
- package/lib/account/esolve-transaction.d.ts +0 -132
- package/lib/account/esolve-user-account-result.d.ts +0 -6
- package/lib/auth/esolve-auth-response.d.ts +0 -25
- package/lib/banners/esolve-banner-type.d.ts +0 -7
- package/lib/cart/esolve-checkout-result.d.ts +0 -6
- package/lib/cart/esolve-checkout.d.ts +0 -7
- package/lib/category-tree/esolve-category-tree-item-record.d.ts +0 -51
- package/lib/locations/esolve-stock-location.d.ts +0 -60
- package/lib/media/esolve-media-article.d.ts +0 -13
- package/lib/shared/esolve-response.d.ts +0 -40
- package/lib/shipping/esolve-shipping-method.d.ts +0 -32
- package/lib/stock/esolve-stock-item-list.d.ts +0 -10
- package/lib/stock/esolve-stock-item.d.ts +0 -174
|
@@ -9,14 +9,7 @@ import { BehaviorSubject, throwError, of, iif } from 'rxjs';
|
|
|
9
9
|
import * as i1$1 from '@angular/platform-browser';
|
|
10
10
|
import { map, tap, catchError, switchMap } from 'rxjs/operators';
|
|
11
11
|
|
|
12
|
-
const ESOLVE_CONNECT_CONFIG = new InjectionToken('esolve.connect.config');
|
|
13
|
-
// For future development
|
|
14
|
-
// export const GLOBAL_CONFIG = {
|
|
15
|
-
// images_url: '',
|
|
16
|
-
// media_path: '/media',
|
|
17
|
-
// stock_path: '/stock',
|
|
18
|
-
// banner_path: '/banners'
|
|
19
|
-
// };
|
|
12
|
+
const ESOLVE_CONNECT_CONFIG = new InjectionToken('esolve.connect.config');
|
|
20
13
|
|
|
21
14
|
class EsolveSession {
|
|
22
15
|
constructor(id = -1, location_id = 0, key = '', expiration_date) {
|
|
@@ -259,7 +252,7 @@ class EsolveAuthInterceptorService {
|
|
|
259
252
|
});
|
|
260
253
|
const modified_req = req.clone({
|
|
261
254
|
url: modified_url,
|
|
262
|
-
params
|
|
255
|
+
params,
|
|
263
256
|
});
|
|
264
257
|
return next.handle(modified_req);
|
|
265
258
|
}
|
|
@@ -330,6 +323,47 @@ class EsolveResult {
|
|
|
330
323
|
}
|
|
331
324
|
}
|
|
332
325
|
|
|
326
|
+
class EsolveResponseResult {
|
|
327
|
+
constructor(response) {
|
|
328
|
+
this.success_log = [];
|
|
329
|
+
this.error_log = [];
|
|
330
|
+
this.error_log.push(...response.log.filter(log_item => log_item.type === 'error'));
|
|
331
|
+
this.success_log.push(...response.log.filter(log_item => log_item.type === 'success'));
|
|
332
|
+
}
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
class EsolveResponseHandlerService {
|
|
336
|
+
constructor() { }
|
|
337
|
+
/**
|
|
338
|
+
* Parse single HTTP response
|
|
339
|
+
*
|
|
340
|
+
* @param http_response HTTP Response to eSolve service
|
|
341
|
+
* @param resultHandler Function to parse response to a result
|
|
342
|
+
*
|
|
343
|
+
* @returns Parsed result of response
|
|
344
|
+
*/
|
|
345
|
+
validateSingleHttpResponse(http_response, resultHandler) {
|
|
346
|
+
if ((http_response.responses === undefined) ||
|
|
347
|
+
(http_response.responses.length <= 0)) {
|
|
348
|
+
throw http_response;
|
|
349
|
+
}
|
|
350
|
+
const response = http_response.responses[0];
|
|
351
|
+
if ((response.status.state === 'error') ||
|
|
352
|
+
(response.status.state === 'none')) {
|
|
353
|
+
throw response;
|
|
354
|
+
}
|
|
355
|
+
return resultHandler(response);
|
|
356
|
+
}
|
|
357
|
+
}
|
|
358
|
+
EsolveResponseHandlerService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveResponseHandlerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
359
|
+
EsolveResponseHandlerService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveResponseHandlerService, providedIn: 'root' });
|
|
360
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveResponseHandlerService, decorators: [{
|
|
361
|
+
type: Injectable,
|
|
362
|
+
args: [{
|
|
363
|
+
providedIn: 'root',
|
|
364
|
+
}]
|
|
365
|
+
}], ctorParameters: function () { return []; } });
|
|
366
|
+
|
|
333
367
|
class EsolveHttpError {
|
|
334
368
|
constructor(type, message, error_code) {
|
|
335
369
|
this.type = type;
|
|
@@ -340,9 +374,12 @@ class EsolveHttpError {
|
|
|
340
374
|
|
|
341
375
|
class EsolveErrorHandlerService {
|
|
342
376
|
constructor() { }
|
|
343
|
-
|
|
377
|
+
throwError(code, message) {
|
|
344
378
|
throw new EsolveHttpError('error', message, code);
|
|
345
379
|
}
|
|
380
|
+
emitError(code, message) {
|
|
381
|
+
return throwError(new EsolveHttpError('error', message, code));
|
|
382
|
+
}
|
|
346
383
|
handleHttpPostError(service_type, errorRes) {
|
|
347
384
|
if (!(errorRes instanceof HttpErrorResponse) &&
|
|
348
385
|
!('service_type' in errorRes) &&
|
|
@@ -424,49 +461,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
424
461
|
}]
|
|
425
462
|
}], ctorParameters: function () { return []; } });
|
|
426
463
|
|
|
427
|
-
class EsolveResponseResult {
|
|
428
|
-
constructor(response) {
|
|
429
|
-
this.success_log = [];
|
|
430
|
-
this.error_log = [];
|
|
431
|
-
this.error_log.push(...response.log.filter(log_item => log_item.type === 'error'));
|
|
432
|
-
this.success_log.push(...response.log.filter(log_item => log_item.type === 'success'));
|
|
433
|
-
}
|
|
434
|
-
}
|
|
435
|
-
|
|
436
|
-
class EsolveResponseHandlerService {
|
|
437
|
-
constructor() { }
|
|
438
|
-
/**
|
|
439
|
-
* Parse single HTTP response
|
|
440
|
-
* @param http_response HTTP Response to eSolve service
|
|
441
|
-
* @param resultHandler Function to parse response to a result
|
|
442
|
-
* @returns Parsed result of response
|
|
443
|
-
*/
|
|
444
|
-
validateSingleHttpResponse(http_response, resultHandler) {
|
|
445
|
-
if ((http_response.responses === undefined) ||
|
|
446
|
-
(http_response.responses.length <= 0)) {
|
|
447
|
-
throw http_response;
|
|
448
|
-
}
|
|
449
|
-
const response = http_response.responses[0];
|
|
450
|
-
if ((response.status.state === 'error') ||
|
|
451
|
-
(response.status.state === 'none')) {
|
|
452
|
-
throw response;
|
|
453
|
-
}
|
|
454
|
-
return resultHandler(response);
|
|
455
|
-
}
|
|
456
|
-
}
|
|
457
|
-
EsolveResponseHandlerService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveResponseHandlerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
458
|
-
EsolveResponseHandlerService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveResponseHandlerService, providedIn: 'root' });
|
|
459
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveResponseHandlerService, decorators: [{
|
|
460
|
-
type: Injectable,
|
|
461
|
-
args: [{
|
|
462
|
-
providedIn: 'root'
|
|
463
|
-
}]
|
|
464
|
-
}], ctorParameters: function () { return []; } });
|
|
465
|
-
|
|
466
464
|
/**
|
|
467
465
|
* Search Engine Optimization information.
|
|
468
466
|
*/
|
|
469
|
-
class
|
|
467
|
+
class EsolveSeoInfo {
|
|
470
468
|
constructor(title = '', description = '', keywords = '') {
|
|
471
469
|
this.title = title;
|
|
472
470
|
this.description = description;
|
|
@@ -487,6 +485,16 @@ class EsolveSeoService {
|
|
|
487
485
|
this.default_seo_keywords = '';
|
|
488
486
|
this.init();
|
|
489
487
|
}
|
|
488
|
+
/**
|
|
489
|
+
* Sets SEO tags for page
|
|
490
|
+
* @param seoInfo SEO object
|
|
491
|
+
*/
|
|
492
|
+
setTags(seoInfo) {
|
|
493
|
+
seoInfo = this.validateAndSanitizeSeoInfo(seoInfo);
|
|
494
|
+
this.setPageTitleTags(seoInfo.title);
|
|
495
|
+
this.setPageDescriptionTags(seoInfo.description);
|
|
496
|
+
this.setPageKeywordsTags(seoInfo.keywords);
|
|
497
|
+
}
|
|
490
498
|
init() {
|
|
491
499
|
if (typeof this.config.title_prefix !== 'undefined') {
|
|
492
500
|
this.title_prefix = this.config.title_prefix;
|
|
@@ -519,7 +527,7 @@ class EsolveSeoService {
|
|
|
519
527
|
this.meta.updateTag({ name: 'keywords', content: keywords });
|
|
520
528
|
}
|
|
521
529
|
validateAndSanitizeSeoInfo(seoInfo) {
|
|
522
|
-
const pageSeo = new
|
|
530
|
+
const pageSeo = new EsolveSeoInfo(this.default_seo_title, this.default_seo_description, this.default_seo_keywords);
|
|
523
531
|
if (seoInfo.description.trim() !== '') {
|
|
524
532
|
pageSeo.description = seoInfo.description;
|
|
525
533
|
}
|
|
@@ -560,23 +568,13 @@ class EsolveSeoService {
|
|
|
560
568
|
}
|
|
561
569
|
return pageSeo;
|
|
562
570
|
}
|
|
563
|
-
/**
|
|
564
|
-
* Sets SEO tags for page
|
|
565
|
-
* @param seoInfo SEO object
|
|
566
|
-
*/
|
|
567
|
-
setTags(seoInfo) {
|
|
568
|
-
seoInfo = this.validateAndSanitizeSeoInfo(seoInfo);
|
|
569
|
-
this.setPageTitleTags(seoInfo.title);
|
|
570
|
-
this.setPageDescriptionTags(seoInfo.description);
|
|
571
|
-
this.setPageKeywordsTags(seoInfo.keywords);
|
|
572
|
-
}
|
|
573
571
|
}
|
|
574
572
|
EsolveSeoService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveSeoService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$1.Title }, { token: i1$1.Meta }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
575
573
|
EsolveSeoService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveSeoService, providedIn: 'root' });
|
|
576
574
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveSeoService, decorators: [{
|
|
577
575
|
type: Injectable,
|
|
578
576
|
args: [{
|
|
579
|
-
providedIn: 'root'
|
|
577
|
+
providedIn: 'root',
|
|
580
578
|
}]
|
|
581
579
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
582
580
|
type: Inject,
|
|
@@ -890,7 +888,16 @@ class EsolveUserAccount {
|
|
|
890
888
|
this.gender = gender;
|
|
891
889
|
this.identification_number = identification_number;
|
|
892
890
|
}
|
|
893
|
-
}
|
|
891
|
+
}
|
|
892
|
+
|
|
893
|
+
class EsolveUserAccountResult extends EsolveResponseResult {
|
|
894
|
+
constructor(response) {
|
|
895
|
+
super(response);
|
|
896
|
+
this.id = 0;
|
|
897
|
+
this.id = +response.esolve_id;
|
|
898
|
+
}
|
|
899
|
+
}
|
|
900
|
+
|
|
894
901
|
class EsolveUserAccountBusiness {
|
|
895
902
|
constructor(name, vat_number, description, type) {
|
|
896
903
|
this.name = name;
|
|
@@ -898,7 +905,8 @@ class EsolveUserAccountBusiness {
|
|
|
898
905
|
this.description = description;
|
|
899
906
|
this.type = type;
|
|
900
907
|
}
|
|
901
|
-
}
|
|
908
|
+
}
|
|
909
|
+
|
|
902
910
|
class EsolveUserAccountContact {
|
|
903
911
|
constructor(tel_number, cell_number, fax_number) {
|
|
904
912
|
this.tel_number = tel_number;
|
|
@@ -907,44 +915,73 @@ class EsolveUserAccountContact {
|
|
|
907
915
|
}
|
|
908
916
|
}
|
|
909
917
|
|
|
910
|
-
class
|
|
911
|
-
constructor(
|
|
912
|
-
|
|
913
|
-
this.
|
|
914
|
-
this.
|
|
918
|
+
class EsolveTransactionAddress {
|
|
919
|
+
constructor(recipient, address_type, address_description, street_number, street, suburb, city, province, country, postal_code, pobox) {
|
|
920
|
+
this.recipient = recipient;
|
|
921
|
+
this.address_type = address_type;
|
|
922
|
+
this.address_description = address_description;
|
|
923
|
+
this.street_number = street_number;
|
|
924
|
+
this.street = street;
|
|
925
|
+
this.suburb = suburb;
|
|
926
|
+
this.city = city;
|
|
927
|
+
this.province = province;
|
|
928
|
+
this.country = country;
|
|
929
|
+
this.postal_code = postal_code;
|
|
930
|
+
this.pobox = pobox;
|
|
915
931
|
}
|
|
916
932
|
}
|
|
917
933
|
|
|
918
|
-
class
|
|
919
|
-
constructor(
|
|
920
|
-
this.id =
|
|
921
|
-
this.
|
|
922
|
-
this.
|
|
923
|
-
this.
|
|
924
|
-
this.
|
|
925
|
-
this.
|
|
926
|
-
this.
|
|
927
|
-
this.
|
|
928
|
-
this.importance = +record.importance;
|
|
929
|
-
this.active = record.is_active;
|
|
930
|
-
this.website_url = record.website_url;
|
|
931
|
-
this.address = new EsolveStockLocationAddress(record.street, record.suburb, record.city, record.province, record.country, record.postal_code, +record.latitude, +record.longitude);
|
|
932
|
-
this.pobox_address = new EsolveStockLocationPOBoxAddress(record.pobox, record.pobox_city, record.pobox_postal_code);
|
|
933
|
-
const telnumbers = [];
|
|
934
|
-
if (record.branch_telnumber.length > 0) {
|
|
935
|
-
telnumbers.push(record.branch_telnumber);
|
|
936
|
-
}
|
|
937
|
-
if (record.branch_telnumber_2.length > 0) {
|
|
938
|
-
telnumbers.push(record.branch_telnumber_2);
|
|
939
|
-
}
|
|
940
|
-
if (record.branch_telnumber_3.length > 0) {
|
|
941
|
-
telnumbers.push(record.branch_telnumber_3);
|
|
942
|
-
}
|
|
943
|
-
this.contact_info = new EsolveStockLocationContactInfo(telnumbers, record.branch_cellnumber, record.branch_email, record.branch_fax);
|
|
944
|
-
this.trading_times = new EsolveStockLocationTradingTimes(new EsolveStockLocationTradingTimesDay(record.monday_open_time, record.monday_close_time), new EsolveStockLocationTradingTimesDay(record.tuesday_open_time, record.tuesday_close_time), new EsolveStockLocationTradingTimesDay(record.wednesday_open_time, record.wednesday_close_time), new EsolveStockLocationTradingTimesDay(record.thursday_open_time, record.thursday_close_time), new EsolveStockLocationTradingTimesDay(record.friday_open_time, record.friday_close_time), new EsolveStockLocationTradingTimesDay(record.saturday_open_time, record.saturday_close_time), new EsolveStockLocationTradingTimesDay(record.sunday_open_time, record.sunday_close_time), new EsolveStockLocationTradingTimesDay(record.public_holiday_open_time, record.public_holiday_close_time), record.trading_hours_additional_info);
|
|
934
|
+
class EsolveTransactionClient {
|
|
935
|
+
constructor(id, account, company_name, branch_code, email, first_name, last_name, contact_number) {
|
|
936
|
+
this.id = id;
|
|
937
|
+
this.account = account;
|
|
938
|
+
this.company_name = company_name;
|
|
939
|
+
this.branch_code = branch_code;
|
|
940
|
+
this.email = email;
|
|
941
|
+
this.first_name = first_name;
|
|
942
|
+
this.last_name = last_name;
|
|
943
|
+
this.contact_number = contact_number;
|
|
945
944
|
}
|
|
946
|
-
}
|
|
947
|
-
|
|
945
|
+
}
|
|
946
|
+
|
|
947
|
+
class EsolveTransactionItem {
|
|
948
|
+
constructor(code, name, qty, discount, vat_rate, price, line_total) {
|
|
949
|
+
this.code = code;
|
|
950
|
+
this.name = name;
|
|
951
|
+
this.qty = qty;
|
|
952
|
+
this.discount = discount;
|
|
953
|
+
this.vat_rate = vat_rate;
|
|
954
|
+
this.price = price;
|
|
955
|
+
this.line_total = line_total;
|
|
956
|
+
}
|
|
957
|
+
}
|
|
958
|
+
|
|
959
|
+
class EsolveTransactionItemPrice {
|
|
960
|
+
constructor(
|
|
961
|
+
/**
|
|
962
|
+
* Price without tax
|
|
963
|
+
*/
|
|
964
|
+
price,
|
|
965
|
+
/**
|
|
966
|
+
* Price with tax
|
|
967
|
+
*/
|
|
968
|
+
price_with_tax,
|
|
969
|
+
/**
|
|
970
|
+
* Price without tax and with discounts applied if applicable
|
|
971
|
+
*/
|
|
972
|
+
price_discounted,
|
|
973
|
+
/**
|
|
974
|
+
* Price with tax and with discounts applied if applicable
|
|
975
|
+
*/
|
|
976
|
+
price_with_tax_discounted) {
|
|
977
|
+
this.price = price;
|
|
978
|
+
this.price_with_tax = price_with_tax;
|
|
979
|
+
this.price_discounted = price_discounted;
|
|
980
|
+
this.price_with_tax_discounted = price_with_tax_discounted;
|
|
981
|
+
}
|
|
982
|
+
}
|
|
983
|
+
|
|
984
|
+
class EsolveLocationAddress {
|
|
948
985
|
constructor(street, suburb, city, province, country, postal_code, latitude, longitude) {
|
|
949
986
|
this.street = street;
|
|
950
987
|
this.suburb = suburb;
|
|
@@ -955,23 +992,26 @@ class EsolveStockLocationAddress {
|
|
|
955
992
|
this.latitude = latitude;
|
|
956
993
|
this.longitude = longitude;
|
|
957
994
|
}
|
|
958
|
-
}
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
this.pobox = pobox;
|
|
962
|
-
this.city = city;
|
|
963
|
-
this.postal_code = postal_code;
|
|
964
|
-
}
|
|
965
|
-
}
|
|
966
|
-
class EsolveStockLocationContactInfo {
|
|
995
|
+
}
|
|
996
|
+
|
|
997
|
+
class EsolveLocationContactInfo {
|
|
967
998
|
constructor(telnumber, cellnumber, email, fax) {
|
|
968
999
|
this.telnumber = telnumber;
|
|
969
1000
|
this.cellnumber = cellnumber;
|
|
970
1001
|
this.email = email;
|
|
971
1002
|
this.fax = fax;
|
|
972
1003
|
}
|
|
973
|
-
}
|
|
974
|
-
|
|
1004
|
+
}
|
|
1005
|
+
|
|
1006
|
+
class EsolveLocationPOBoxAddress {
|
|
1007
|
+
constructor(pobox, city, postal_code) {
|
|
1008
|
+
this.pobox = pobox;
|
|
1009
|
+
this.city = city;
|
|
1010
|
+
this.postal_code = postal_code;
|
|
1011
|
+
}
|
|
1012
|
+
}
|
|
1013
|
+
|
|
1014
|
+
class EsolveLocationTradingTimes {
|
|
975
1015
|
constructor(monday, tuesday, wednesday, thursday, friday, saturday, sunday, public_holiday, trading_hours_additional_info = '') {
|
|
976
1016
|
this.monday = monday;
|
|
977
1017
|
this.tuesday = tuesday;
|
|
@@ -983,87 +1023,104 @@ class EsolveStockLocationTradingTimes {
|
|
|
983
1023
|
this.public_holiday = public_holiday;
|
|
984
1024
|
this.trading_hours_additional_info = trading_hours_additional_info;
|
|
985
1025
|
}
|
|
986
|
-
}
|
|
987
|
-
|
|
1026
|
+
}
|
|
1027
|
+
|
|
1028
|
+
class EsolveLocationTradingDay {
|
|
988
1029
|
constructor(open, close) {
|
|
989
1030
|
this.open = open;
|
|
990
1031
|
this.close = close;
|
|
991
1032
|
}
|
|
992
1033
|
}
|
|
993
1034
|
|
|
994
|
-
class
|
|
1035
|
+
class EsolveLocation {
|
|
995
1036
|
constructor(record) {
|
|
996
|
-
// Transaction Items
|
|
997
|
-
this.items = [];
|
|
998
1037
|
this.id = +record.id;
|
|
999
|
-
this.
|
|
1000
|
-
this.
|
|
1001
|
-
this.
|
|
1002
|
-
this.
|
|
1003
|
-
this.
|
|
1004
|
-
this.
|
|
1005
|
-
this.
|
|
1006
|
-
this.
|
|
1007
|
-
this.
|
|
1008
|
-
this.
|
|
1009
|
-
this.
|
|
1010
|
-
this.
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
this.payment_description = record.payment_description;
|
|
1015
|
-
this.gateway_transaction_id = record.gateway_transaction_id;
|
|
1016
|
-
this.address = new EsolveTransactionAddress(record.recipient, record.address_type, record.address_description, record.street_number, record.street, record.suburb, record.city, record.province, record.country, record.postal_code, record.pobox);
|
|
1017
|
-
if (record.user) {
|
|
1018
|
-
this.user = new EsolveTransactionUser(+record.user.id, record.user.email, record.user.firstname, record.user.surname, record.user.telnumber, record.user.cellnumber);
|
|
1019
|
-
}
|
|
1020
|
-
if (record.client) {
|
|
1021
|
-
this.client = new EsolveTransactionClient(+record.client.id, record.client.account, record.client.company_name, record.client.branch_code, record.client.email, record.client.firstname, record.client.surname, record.client.contact_number);
|
|
1022
|
-
}
|
|
1023
|
-
if (record.location_details) {
|
|
1024
|
-
this.location = new EsolveTransactionLocation(record.location_details);
|
|
1038
|
+
this.identifier = record.identifier;
|
|
1039
|
+
this.description = record.description;
|
|
1040
|
+
this.head_office = record.head_office;
|
|
1041
|
+
this.erp_identifier = record.erp_identifier;
|
|
1042
|
+
this.external_system_code = record.external_system_code;
|
|
1043
|
+
this.default_location_for_payment_methods = record.default_location_for_payment_methods;
|
|
1044
|
+
this.userid = +record.userid;
|
|
1045
|
+
this.importance = +record.importance;
|
|
1046
|
+
this.active = record.is_active;
|
|
1047
|
+
this.website_url = record.website_url;
|
|
1048
|
+
this.address = new EsolveLocationAddress(record.street, record.suburb, record.city, record.province, record.country, record.postal_code, +record.latitude, +record.longitude);
|
|
1049
|
+
this.pobox_address = new EsolveLocationPOBoxAddress(record.pobox, record.pobox_city, record.pobox_postal_code);
|
|
1050
|
+
const telnumbers = [];
|
|
1051
|
+
if (record.branch_telnumber.length > 0) {
|
|
1052
|
+
telnumbers.push(record.branch_telnumber);
|
|
1025
1053
|
}
|
|
1026
|
-
if (record.
|
|
1027
|
-
|
|
1054
|
+
if (record.branch_telnumber_2.length > 0) {
|
|
1055
|
+
telnumbers.push(record.branch_telnumber_2);
|
|
1028
1056
|
}
|
|
1029
|
-
if (record.
|
|
1030
|
-
|
|
1057
|
+
if (record.branch_telnumber_3.length > 0) {
|
|
1058
|
+
telnumbers.push(record.branch_telnumber_3);
|
|
1031
1059
|
}
|
|
1032
|
-
this.
|
|
1060
|
+
this.contact_info = new EsolveLocationContactInfo(telnumbers, record.branch_cellnumber, record.branch_email, record.branch_fax);
|
|
1061
|
+
const monday = new EsolveLocationTradingDay(record.monday_open_time, record.monday_close_time);
|
|
1062
|
+
const tuesday = new EsolveLocationTradingDay(record.tuesday_open_time, record.tuesday_close_time);
|
|
1063
|
+
const wednesday = new EsolveLocationTradingDay(record.wednesday_open_time, record.wednesday_close_time);
|
|
1064
|
+
const thursday = new EsolveLocationTradingDay(record.thursday_open_time, record.thursday_close_time);
|
|
1065
|
+
const friday = new EsolveLocationTradingDay(record.friday_open_time, record.friday_close_time);
|
|
1066
|
+
const saturday = new EsolveLocationTradingDay(record.saturday_open_time, record.saturday_close_time);
|
|
1067
|
+
const sunday = new EsolveLocationTradingDay(record.sunday_open_time, record.sunday_close_time);
|
|
1068
|
+
const public_holiday = new EsolveLocationTradingDay(record.public_holiday_open_time, record.public_holiday_close_time);
|
|
1069
|
+
this.trading_times = new EsolveLocationTradingTimes(monday, tuesday, wednesday, thursday, friday, saturday, sunday, public_holiday, record.trading_hours_additional_info);
|
|
1033
1070
|
}
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
}
|
|
1071
|
+
}
|
|
1072
|
+
|
|
1073
|
+
class EsolveLocationsService {
|
|
1074
|
+
constructor(config, http) {
|
|
1075
|
+
this.config = config;
|
|
1076
|
+
this.http = http;
|
|
1041
1077
|
}
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
this.
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1078
|
+
/**
|
|
1079
|
+
* Retrieves a list of stock locations
|
|
1080
|
+
*
|
|
1081
|
+
* @returns An `Observable` with an array of stock locations
|
|
1082
|
+
*/
|
|
1083
|
+
getStockLocations() {
|
|
1084
|
+
return this.http
|
|
1085
|
+
.get(`${this.config.api_url}/get-locations.php`)
|
|
1086
|
+
.pipe(map((response) => {
|
|
1087
|
+
if (response.records === undefined) {
|
|
1088
|
+
throw response;
|
|
1089
|
+
}
|
|
1090
|
+
return this.processStockLocations(response.records);
|
|
1091
|
+
}));
|
|
1053
1092
|
}
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1093
|
+
/**
|
|
1094
|
+
* Processes the eSolve stock location records.
|
|
1095
|
+
*
|
|
1096
|
+
* @param records Records to process
|
|
1097
|
+
* @returns An array of processed stock location records
|
|
1098
|
+
*/
|
|
1099
|
+
processStockLocations(records) {
|
|
1100
|
+
const stock_locations = [];
|
|
1101
|
+
if (records) {
|
|
1102
|
+
for (const record of records) {
|
|
1103
|
+
stock_locations.push(new EsolveLocation(record));
|
|
1104
|
+
}
|
|
1105
|
+
}
|
|
1106
|
+
return stock_locations;
|
|
1063
1107
|
}
|
|
1064
1108
|
}
|
|
1065
|
-
|
|
1066
|
-
}
|
|
1109
|
+
EsolveLocationsService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveLocationsService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1110
|
+
EsolveLocationsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveLocationsService, providedIn: 'root' });
|
|
1111
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveLocationsService, decorators: [{
|
|
1112
|
+
type: Injectable,
|
|
1113
|
+
args: [{
|
|
1114
|
+
providedIn: 'root',
|
|
1115
|
+
}]
|
|
1116
|
+
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
1117
|
+
type: Inject,
|
|
1118
|
+
args: [ESOLVE_CONNECT_CONFIG]
|
|
1119
|
+
}] }, { type: i1$2.HttpClient }]; } });
|
|
1120
|
+
|
|
1121
|
+
class EsolveTransactionLocation extends EsolveLocation {
|
|
1122
|
+
}
|
|
1123
|
+
|
|
1067
1124
|
class EsolveTransactionPaymentMethod {
|
|
1068
1125
|
constructor(id, name, description, integration_type, service_provider) {
|
|
1069
1126
|
this.id = id;
|
|
@@ -1072,7 +1129,8 @@ class EsolveTransactionPaymentMethod {
|
|
|
1072
1129
|
this.integration_type = integration_type;
|
|
1073
1130
|
this.service_provider = service_provider;
|
|
1074
1131
|
}
|
|
1075
|
-
}
|
|
1132
|
+
}
|
|
1133
|
+
|
|
1076
1134
|
class EsolveTransactionShippingMethod {
|
|
1077
1135
|
constructor(id, name, delivery_category, location, description, pricing, client_to_collect) {
|
|
1078
1136
|
this.id = id;
|
|
@@ -1083,71 +1141,73 @@ class EsolveTransactionShippingMethod {
|
|
|
1083
1141
|
this.pricing = pricing;
|
|
1084
1142
|
this.client_to_collect = client_to_collect;
|
|
1085
1143
|
}
|
|
1086
|
-
}
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
this.
|
|
1091
|
-
this.
|
|
1092
|
-
this.
|
|
1093
|
-
this.
|
|
1094
|
-
this.
|
|
1095
|
-
this.
|
|
1096
|
-
this.province = province;
|
|
1097
|
-
this.country = country;
|
|
1098
|
-
this.postal_code = postal_code;
|
|
1099
|
-
this.pobox = pobox;
|
|
1144
|
+
}
|
|
1145
|
+
|
|
1146
|
+
class EsolveTransactionUser {
|
|
1147
|
+
constructor(id, email, first_name, last_name, tel_number, cell_number) {
|
|
1148
|
+
this.id = id;
|
|
1149
|
+
this.email = email;
|
|
1150
|
+
this.first_name = first_name;
|
|
1151
|
+
this.last_name = last_name;
|
|
1152
|
+
this.tel_number = tel_number;
|
|
1153
|
+
this.cell_number = cell_number;
|
|
1100
1154
|
}
|
|
1101
|
-
}
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
this.
|
|
1107
|
-
this.
|
|
1108
|
-
this.
|
|
1109
|
-
this.
|
|
1110
|
-
this.
|
|
1155
|
+
}
|
|
1156
|
+
|
|
1157
|
+
class EsolveTransaction {
|
|
1158
|
+
constructor(record) {
|
|
1159
|
+
// Transaction Items
|
|
1160
|
+
this.items = [];
|
|
1161
|
+
this.id = +record.id;
|
|
1162
|
+
this.type = record.transaction_type;
|
|
1163
|
+
this.status = record.status;
|
|
1164
|
+
this.loyalty_number = record.loyaltynumber;
|
|
1165
|
+
this.external_order_number = record.external_order_number;
|
|
1166
|
+
this.external_invoice_number = record.external_invoice_number;
|
|
1167
|
+
this.date = new Date(+record.txdate_timestamp * 1000);
|
|
1168
|
+
this.expected_date = new Date(+record.expected_date_timestamp * 1000);
|
|
1169
|
+
this.invoice_amount = +record.invoice_amount;
|
|
1170
|
+
this.vat = +record.vat;
|
|
1171
|
+
this.discount = +record.discount;
|
|
1172
|
+
this.total = +record.total;
|
|
1173
|
+
this.shipping_total = +record.shipping_total;
|
|
1174
|
+
this.insurance_total = +record.insurance_total;
|
|
1175
|
+
this.payment = +record.payment;
|
|
1176
|
+
this.payment_reference = record.payment_reference;
|
|
1177
|
+
this.payment_description = record.payment_description;
|
|
1178
|
+
this.gateway_transaction_id = record.gateway_transaction_id;
|
|
1179
|
+
this.address = new EsolveTransactionAddress(record.recipient, record.address_type, record.address_description, record.street_number, record.street, record.suburb, record.city, record.province, record.country, record.postal_code, record.pobox);
|
|
1180
|
+
if (record.user) {
|
|
1181
|
+
this.user = new EsolveTransactionUser(+record.user.id, record.user.email, record.user.firstname, record.user.surname, record.user.telnumber, record.user.cellnumber);
|
|
1182
|
+
}
|
|
1183
|
+
if (record.client) {
|
|
1184
|
+
this.client = new EsolveTransactionClient(+record.client.id, record.client.account, record.client.company_name, record.client.branch_code, record.client.email, record.client.firstname, record.client.surname, record.client.contact_number);
|
|
1185
|
+
}
|
|
1186
|
+
if (record.location_details) {
|
|
1187
|
+
this.location = new EsolveTransactionLocation(record.location_details);
|
|
1188
|
+
}
|
|
1189
|
+
if (record.payment_method_details) {
|
|
1190
|
+
this.payment_method = new EsolveTransactionPaymentMethod(record.payment_method_details.id, record.payment_method_details.paymethod_name, record.payment_method_details.description, record.payment_method_details.integration_type, record.payment_method_details.service_provider);
|
|
1191
|
+
}
|
|
1192
|
+
if (record.shipping_method_details) {
|
|
1193
|
+
this.shipping_method = new EsolveTransactionShippingMethod(+record.shipping_method_details.id, record.shipping_method_details.carrier_name, record.shipping_method_details.delivery_category, record.shipping_method_details.location, record.shipping_method_details.description, record.shipping_method_details.pricing, !!record.shipping_method_details.client_to_collect);
|
|
1194
|
+
}
|
|
1195
|
+
this.parseTransactionItems(record.transaction_items);
|
|
1111
1196
|
}
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
/**
|
|
1120
|
-
* Price with tax
|
|
1121
|
-
*/
|
|
1122
|
-
price_with_tax,
|
|
1123
|
-
/**
|
|
1124
|
-
* Price without tax and with discounts applied if appilcable
|
|
1125
|
-
*/
|
|
1126
|
-
price_discounted,
|
|
1127
|
-
/**
|
|
1128
|
-
* Price with tax and with discounts applied if appilcable
|
|
1129
|
-
*/
|
|
1130
|
-
price_with_tax_discounted) {
|
|
1131
|
-
this.price = price;
|
|
1132
|
-
this.price_with_tax = price_with_tax;
|
|
1133
|
-
this.price_discounted = price_discounted;
|
|
1134
|
-
this.price_with_tax_discounted = price_with_tax_discounted;
|
|
1197
|
+
parseTransactionItems(record_items) {
|
|
1198
|
+
for (const record_item of record_items) {
|
|
1199
|
+
const price = new EsolveTransactionItemPrice(+record_item.price_exclusive, +record_item.price_inclusive, +record_item.price_exclusive_after_discount, +record_item.price_inclusive_after_discount);
|
|
1200
|
+
const line_total = new EsolveTransactionItemPrice(+record_item.line_total_exclusive, +record_item.line_total_inclusive, +record_item.line_total_exclusive_after_discount, +record_item.line_total_inclusive_after_discount);
|
|
1201
|
+
const item = new EsolveTransactionItem(record_item.code, record_item.name, +record_item.qty, +record_item.discount, +record_item.vat_rate, price, line_total);
|
|
1202
|
+
this.items.push(item);
|
|
1203
|
+
}
|
|
1135
1204
|
}
|
|
1136
1205
|
}
|
|
1137
1206
|
|
|
1138
1207
|
class EsolveTransactionList extends EsolveList {
|
|
1139
1208
|
}
|
|
1140
1209
|
|
|
1141
|
-
|
|
1142
|
-
constructor(response) {
|
|
1143
|
-
super(response);
|
|
1144
|
-
this.user_id = response.esolve_id;
|
|
1145
|
-
this.guest = response.guest;
|
|
1146
|
-
this.auto_login = response.auto_login;
|
|
1147
|
-
this.authentication_required = response.authentication_required;
|
|
1148
|
-
this.location_id = response.session_data.location_id;
|
|
1149
|
-
}
|
|
1150
|
-
}
|
|
1210
|
+
// Classes
|
|
1151
1211
|
|
|
1152
1212
|
class EsolveChangePasswordResult extends EsolveResponseResult {
|
|
1153
1213
|
constructor(response) {
|
|
@@ -1166,6 +1226,17 @@ class EsolveResetPasswordResult extends EsolveResponseResult {
|
|
|
1166
1226
|
}
|
|
1167
1227
|
}
|
|
1168
1228
|
|
|
1229
|
+
class EsolveRegistrationResult extends EsolveResponseResult {
|
|
1230
|
+
constructor(response) {
|
|
1231
|
+
super(response);
|
|
1232
|
+
this.user_id = response.esolve_id;
|
|
1233
|
+
this.guest = response.guest;
|
|
1234
|
+
this.auto_login = response.auto_login;
|
|
1235
|
+
this.authentication_required = response.authentication_required;
|
|
1236
|
+
this.location_id = response.session_data.location_id;
|
|
1237
|
+
}
|
|
1238
|
+
}
|
|
1239
|
+
|
|
1169
1240
|
class EsolveLocationUpdateResult extends EsolveResponseResult {
|
|
1170
1241
|
constructor(response) {
|
|
1171
1242
|
super(response);
|
|
@@ -1456,7 +1527,7 @@ class EsolveAccountService {
|
|
|
1456
1527
|
}
|
|
1457
1528
|
loginGuard() {
|
|
1458
1529
|
if (this.user_id <= 0) {
|
|
1459
|
-
this.errorHandler.
|
|
1530
|
+
this.errorHandler.throwError('login_required', 'Login is required');
|
|
1460
1531
|
}
|
|
1461
1532
|
}
|
|
1462
1533
|
}
|
|
@@ -1465,34 +1536,178 @@ EsolveAccountService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0",
|
|
|
1465
1536
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveAccountService, decorators: [{
|
|
1466
1537
|
type: Injectable,
|
|
1467
1538
|
args: [{
|
|
1468
|
-
providedIn: 'root'
|
|
1539
|
+
providedIn: 'root',
|
|
1469
1540
|
}]
|
|
1470
1541
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
1471
1542
|
type: Inject,
|
|
1472
1543
|
args: [ESOLVE_CONNECT_CONFIG]
|
|
1473
1544
|
}] }, { type: i1$2.HttpClient }, { type: EsolveSessionService }, { type: EsolveErrorHandlerService }, { type: EsolveResponseHandlerService }]; } });
|
|
1474
1545
|
|
|
1475
|
-
class
|
|
1476
|
-
constructor(identifier,
|
|
1477
|
-
this.
|
|
1478
|
-
this.
|
|
1479
|
-
}
|
|
1480
|
-
}
|
|
1481
|
-
|
|
1482
|
-
class EsolveMediaArticle {
|
|
1483
|
-
constructor(identifier, title, article, image_url = '', tags = [], topics = [], seo_title = '', seo_keywords = '', seo_description = '') {
|
|
1546
|
+
class EsolveBanner {
|
|
1547
|
+
constructor(id, banner_display_container, identifier, type, title, article, sort_priority, link, images) {
|
|
1548
|
+
this.id = id;
|
|
1549
|
+
this.banner_display_container = banner_display_container;
|
|
1484
1550
|
this.identifier = identifier;
|
|
1551
|
+
this.type = type;
|
|
1485
1552
|
this.title = title;
|
|
1486
1553
|
this.article = article;
|
|
1487
|
-
this.
|
|
1488
|
-
this.
|
|
1489
|
-
this.
|
|
1490
|
-
|
|
1491
|
-
|
|
1554
|
+
this.sort_priority = sort_priority;
|
|
1555
|
+
this.link = link;
|
|
1556
|
+
this.desktop_images = [];
|
|
1557
|
+
this.mobile_images = [];
|
|
1558
|
+
this.sub_images = [];
|
|
1559
|
+
if (images.desktop) {
|
|
1560
|
+
this.desktop_images = images.desktop;
|
|
1492
1561
|
}
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
}
|
|
1562
|
+
if (images.mobile) {
|
|
1563
|
+
this.mobile_images = images.mobile;
|
|
1564
|
+
}
|
|
1565
|
+
if (images.sub) {
|
|
1566
|
+
this.sub_images = images.sub;
|
|
1567
|
+
}
|
|
1568
|
+
}
|
|
1569
|
+
}
|
|
1570
|
+
|
|
1571
|
+
class EsolveBannerImage {
|
|
1572
|
+
constructor(id, image_type, width, height, filename, hotspots) {
|
|
1573
|
+
this.id = id;
|
|
1574
|
+
this.image_type = image_type;
|
|
1575
|
+
this.width = width;
|
|
1576
|
+
this.height = height;
|
|
1577
|
+
this.filename = filename;
|
|
1578
|
+
this.hotspots = hotspots;
|
|
1579
|
+
}
|
|
1580
|
+
get src() {
|
|
1581
|
+
return '/images/banners/' + this.filename;
|
|
1582
|
+
}
|
|
1583
|
+
}
|
|
1584
|
+
|
|
1585
|
+
class EsolveBannerImageHotspot {
|
|
1586
|
+
constructor(url, target, coords, coords_string) {
|
|
1587
|
+
this.url = url;
|
|
1588
|
+
this.target = target;
|
|
1589
|
+
this.coords = coords;
|
|
1590
|
+
this.coords_string = coords_string;
|
|
1591
|
+
}
|
|
1592
|
+
}
|
|
1593
|
+
|
|
1594
|
+
class EsolveBannerService {
|
|
1595
|
+
constructor(config, http) {
|
|
1596
|
+
this.config = config;
|
|
1597
|
+
this.http = http;
|
|
1598
|
+
}
|
|
1599
|
+
/**
|
|
1600
|
+
* Retrieves banners records from eSolve instance
|
|
1601
|
+
*
|
|
1602
|
+
* @returns An observable of eSolve banners.
|
|
1603
|
+
*/
|
|
1604
|
+
getBanners(identifier, banner_display_container, enable_date_filter = false) {
|
|
1605
|
+
let params = new HttpParams({
|
|
1606
|
+
fromObject: { enable_date_filter }
|
|
1607
|
+
});
|
|
1608
|
+
if (identifier) {
|
|
1609
|
+
params = params.set('identifier', identifier);
|
|
1610
|
+
}
|
|
1611
|
+
if (banner_display_container) {
|
|
1612
|
+
params = params.set('banner_display_container', banner_display_container);
|
|
1613
|
+
}
|
|
1614
|
+
return this.http
|
|
1615
|
+
.get(`${this.config.api_url}/get-banners.php`, { params })
|
|
1616
|
+
.pipe(map((response) => {
|
|
1617
|
+
if (response.records === undefined) {
|
|
1618
|
+
throw response;
|
|
1619
|
+
}
|
|
1620
|
+
return this.processBanners(response.records);
|
|
1621
|
+
}));
|
|
1622
|
+
}
|
|
1623
|
+
processBannerImageHotspots(hotspot_records) {
|
|
1624
|
+
const hotspots = [];
|
|
1625
|
+
if (hotspot_records.length > 0) {
|
|
1626
|
+
for (const hotspot_record of hotspot_records) {
|
|
1627
|
+
const hotspot = new EsolveBannerImageHotspot(hotspot_record.url, hotspot_record.target, hotspot_record.coords, hotspot_record.coords_string);
|
|
1628
|
+
hotspots.push(hotspot);
|
|
1629
|
+
}
|
|
1630
|
+
}
|
|
1631
|
+
return hotspots;
|
|
1632
|
+
}
|
|
1633
|
+
processBannerImages(image_records, banner_type) {
|
|
1634
|
+
const images = [];
|
|
1635
|
+
if (image_records.length > 0) {
|
|
1636
|
+
for (const image_record of image_records) {
|
|
1637
|
+
const image = new EsolveBannerImage(+image_record.id, image_record.image_type, +image_record.width, +image_record.height, image_record.filename);
|
|
1638
|
+
if ((banner_type === 'hotspot') && (image_record.hotspots)) {
|
|
1639
|
+
const hotspots = this.processBannerImageHotspots(image_record.hotspots);
|
|
1640
|
+
image.hotspots = hotspots;
|
|
1641
|
+
}
|
|
1642
|
+
images.push(image);
|
|
1643
|
+
}
|
|
1644
|
+
}
|
|
1645
|
+
return images;
|
|
1646
|
+
}
|
|
1647
|
+
/**
|
|
1648
|
+
* Process banner records into banner objects
|
|
1649
|
+
* @param records Array of records
|
|
1650
|
+
* @returns List of banners
|
|
1651
|
+
*/
|
|
1652
|
+
processBanners(records) {
|
|
1653
|
+
const banners = [];
|
|
1654
|
+
if ((records) && (records.length > 0)) {
|
|
1655
|
+
for (const record of records) {
|
|
1656
|
+
const image_sets = {};
|
|
1657
|
+
if (record.images.desktop) {
|
|
1658
|
+
image_sets.desktop = this.processBannerImages(record.images.desktop, record.type);
|
|
1659
|
+
}
|
|
1660
|
+
if (record.images.mobile) {
|
|
1661
|
+
image_sets.mobile = this.processBannerImages(record.images.mobile, record.type);
|
|
1662
|
+
}
|
|
1663
|
+
if (record.images.sub) {
|
|
1664
|
+
image_sets.sub = this.processBannerImages(record.images.sub, record.type);
|
|
1665
|
+
}
|
|
1666
|
+
const banner = new EsolveBanner(+record.id, record.banner_display_container, record.identifier, record.type, record.title, record.article, +record.sort_priority, {
|
|
1667
|
+
url: record.link.url,
|
|
1668
|
+
target: record.link.target
|
|
1669
|
+
}, image_sets);
|
|
1670
|
+
banners.push(banner);
|
|
1671
|
+
}
|
|
1672
|
+
}
|
|
1673
|
+
return banners;
|
|
1674
|
+
}
|
|
1675
|
+
}
|
|
1676
|
+
EsolveBannerService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveBannerService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1677
|
+
EsolveBannerService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveBannerService, providedIn: 'root' });
|
|
1678
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveBannerService, decorators: [{
|
|
1679
|
+
type: Injectable,
|
|
1680
|
+
args: [{
|
|
1681
|
+
providedIn: 'root',
|
|
1682
|
+
}]
|
|
1683
|
+
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
1684
|
+
type: Inject,
|
|
1685
|
+
args: [ESOLVE_CONNECT_CONFIG]
|
|
1686
|
+
}] }, { type: i1$2.HttpClient }]; } });
|
|
1687
|
+
|
|
1688
|
+
// Types
|
|
1689
|
+
|
|
1690
|
+
class EsolveHeading {
|
|
1691
|
+
constructor(identifier, value) {
|
|
1692
|
+
this.identifier = identifier;
|
|
1693
|
+
this.value = value;
|
|
1694
|
+
}
|
|
1695
|
+
}
|
|
1696
|
+
|
|
1697
|
+
class EsolveMediaArticle {
|
|
1698
|
+
constructor(identifier, title, article, image_url = '', tags = [], topics = [], seo_title = '', seo_keywords = '', seo_description = '') {
|
|
1699
|
+
this.identifier = identifier;
|
|
1700
|
+
this.title = title;
|
|
1701
|
+
this.article = article;
|
|
1702
|
+
this.image_url = image_url;
|
|
1703
|
+
this.tags = tags;
|
|
1704
|
+
this.topics = topics;
|
|
1705
|
+
if (seo_title.trim() === '') {
|
|
1706
|
+
seo_title = this.title;
|
|
1707
|
+
}
|
|
1708
|
+
this.seo_details = new EsolveSeoInfo(seo_title, seo_description, seo_keywords);
|
|
1709
|
+
}
|
|
1710
|
+
}
|
|
1496
1711
|
|
|
1497
1712
|
class EsolveTag {
|
|
1498
1713
|
constructor(id, tag_phrase, tag_weight, description) {
|
|
@@ -1512,6 +1727,52 @@ class EsolveTopic {
|
|
|
1512
1727
|
}
|
|
1513
1728
|
}
|
|
1514
1729
|
|
|
1730
|
+
class EsolveTopicService {
|
|
1731
|
+
constructor(config, http) {
|
|
1732
|
+
this.config = config;
|
|
1733
|
+
this.http = http;
|
|
1734
|
+
}
|
|
1735
|
+
/**
|
|
1736
|
+
* Retrieves active topics from the list of topic ID's. Note that inactive or expired
|
|
1737
|
+
* topics will not be retrieved.
|
|
1738
|
+
*
|
|
1739
|
+
* @param topic_id_list List of topic ID's that need to be retrieved
|
|
1740
|
+
*/
|
|
1741
|
+
getTopics(topic_id_list = []) {
|
|
1742
|
+
let params = new HttpParams();
|
|
1743
|
+
if (topic_id_list.length > 0) {
|
|
1744
|
+
params = params.append('topic_id', topic_id_list.join(','));
|
|
1745
|
+
}
|
|
1746
|
+
return this.http.get(`${this.config.api_url}/get-topics.php`, { params }).pipe(map(response => {
|
|
1747
|
+
if (response.records === undefined) {
|
|
1748
|
+
throw response;
|
|
1749
|
+
}
|
|
1750
|
+
return this.processTopics(response.records);
|
|
1751
|
+
}));
|
|
1752
|
+
}
|
|
1753
|
+
processTopics(records) {
|
|
1754
|
+
const topics = [];
|
|
1755
|
+
if (records) {
|
|
1756
|
+
for (const record of records) {
|
|
1757
|
+
const topic = new EsolveTopic(+record.id, record.name, record.short_description, +record.sort_priority);
|
|
1758
|
+
topics.push(topic);
|
|
1759
|
+
}
|
|
1760
|
+
}
|
|
1761
|
+
return topics;
|
|
1762
|
+
}
|
|
1763
|
+
}
|
|
1764
|
+
EsolveTopicService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveTopicService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1765
|
+
EsolveTopicService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveTopicService, providedIn: 'root' });
|
|
1766
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveTopicService, decorators: [{
|
|
1767
|
+
type: Injectable,
|
|
1768
|
+
args: [{
|
|
1769
|
+
providedIn: 'root',
|
|
1770
|
+
}]
|
|
1771
|
+
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
1772
|
+
type: Inject,
|
|
1773
|
+
args: [ESOLVE_CONNECT_CONFIG]
|
|
1774
|
+
}] }, { type: i1$2.HttpClient }]; } });
|
|
1775
|
+
|
|
1515
1776
|
class EsolveMediaService {
|
|
1516
1777
|
constructor(config, http) {
|
|
1517
1778
|
this.config = config;
|
|
@@ -1631,6 +1892,55 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
1631
1892
|
args: [ESOLVE_CONNECT_CONFIG]
|
|
1632
1893
|
}] }, { type: i1$2.HttpClient }]; } });
|
|
1633
1894
|
|
|
1895
|
+
class EsolveMenuItem {
|
|
1896
|
+
constructor(url, name, target, children = []) {
|
|
1897
|
+
this.url = url;
|
|
1898
|
+
this.name = name;
|
|
1899
|
+
this.target = target;
|
|
1900
|
+
this.children = children;
|
|
1901
|
+
}
|
|
1902
|
+
}
|
|
1903
|
+
|
|
1904
|
+
class EsolveMenuService {
|
|
1905
|
+
constructor(config, http) {
|
|
1906
|
+
this.config = config;
|
|
1907
|
+
this.http = http;
|
|
1908
|
+
}
|
|
1909
|
+
getMenuTree(identifier) {
|
|
1910
|
+
return this.http
|
|
1911
|
+
.get(`${this.config.api_url}/get-menu-tree.php`, { params: { identifier } })
|
|
1912
|
+
.pipe(map((response) => {
|
|
1913
|
+
if ((!response) || (response.records === undefined)) {
|
|
1914
|
+
throw response;
|
|
1915
|
+
}
|
|
1916
|
+
else if (response.records.length === 0) {
|
|
1917
|
+
return [];
|
|
1918
|
+
}
|
|
1919
|
+
return this.handleMenu(response.records);
|
|
1920
|
+
}));
|
|
1921
|
+
}
|
|
1922
|
+
handleMenu(records) {
|
|
1923
|
+
const menu = [];
|
|
1924
|
+
if (typeof records !== 'undefined') {
|
|
1925
|
+
for (const menuTreeRecord of records) {
|
|
1926
|
+
menu.push(new EsolveMenuItem(menuTreeRecord.sef_url, menuTreeRecord.name, menuTreeRecord.target, this.handleMenu(menuTreeRecord.children)));
|
|
1927
|
+
}
|
|
1928
|
+
}
|
|
1929
|
+
return menu;
|
|
1930
|
+
}
|
|
1931
|
+
}
|
|
1932
|
+
EsolveMenuService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveMenuService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1933
|
+
EsolveMenuService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveMenuService, providedIn: 'root' });
|
|
1934
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveMenuService, decorators: [{
|
|
1935
|
+
type: Injectable,
|
|
1936
|
+
args: [{
|
|
1937
|
+
providedIn: 'root',
|
|
1938
|
+
}]
|
|
1939
|
+
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
1940
|
+
type: Inject,
|
|
1941
|
+
args: [ESOLVE_CONNECT_CONFIG]
|
|
1942
|
+
}] }, { type: i1$2.HttpClient }]; } });
|
|
1943
|
+
|
|
1634
1944
|
class EsolveNewsGroup {
|
|
1635
1945
|
constructor(id, name, description, sef_name) {
|
|
1636
1946
|
this.id = id;
|
|
@@ -1655,7 +1965,7 @@ class EsolveNewsArticle {
|
|
|
1655
1965
|
if (seo_title.trim() === '') {
|
|
1656
1966
|
seo_title = this.title;
|
|
1657
1967
|
}
|
|
1658
|
-
this.seo_details = new
|
|
1968
|
+
this.seo_details = new EsolveSeoInfo(seo_title, short_description, seo_keywords);
|
|
1659
1969
|
}
|
|
1660
1970
|
}
|
|
1661
1971
|
|
|
@@ -1769,139 +2079,175 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
1769
2079
|
args: [ESOLVE_CONNECT_CONFIG]
|
|
1770
2080
|
}] }, { type: i1$2.HttpClient }]; } });
|
|
1771
2081
|
|
|
1772
|
-
class
|
|
1773
|
-
constructor(
|
|
1774
|
-
this.id = id;
|
|
1775
|
-
this.
|
|
1776
|
-
this.
|
|
2082
|
+
class EsolveColour {
|
|
2083
|
+
constructor(record) {
|
|
2084
|
+
this.id = record.id ?? 0;
|
|
2085
|
+
this.colour = record.colour ?? '';
|
|
2086
|
+
this.description = record.description ?? '';
|
|
2087
|
+
}
|
|
2088
|
+
}
|
|
2089
|
+
|
|
2090
|
+
class EsolveCategoryTreeItem {
|
|
2091
|
+
constructor(type, esolve_id, parent_id, description, sef_description, short_description, sort_priority, active, display_only, image_name, seo_title, seo_keywords, seo_description, children) {
|
|
1777
2092
|
this.type = type;
|
|
1778
|
-
this.
|
|
1779
|
-
this.
|
|
1780
|
-
this.
|
|
1781
|
-
this.
|
|
1782
|
-
this.
|
|
1783
|
-
this.
|
|
1784
|
-
this.
|
|
1785
|
-
|
|
1786
|
-
|
|
2093
|
+
this.esolve_id = esolve_id;
|
|
2094
|
+
this.parent_id = parent_id;
|
|
2095
|
+
this.description = description;
|
|
2096
|
+
this.sef_description = sef_description;
|
|
2097
|
+
this.short_description = short_description;
|
|
2098
|
+
this.sort_priority = sort_priority;
|
|
2099
|
+
this.active = active;
|
|
2100
|
+
this.display_only = display_only;
|
|
2101
|
+
this.image_name = image_name;
|
|
2102
|
+
this.id = '';
|
|
2103
|
+
this.image_path = '';
|
|
2104
|
+
if (this.type === 'category') {
|
|
2105
|
+
this.id = `<<CAT>>${this.esolve_id}`;
|
|
2106
|
+
if (children != null) {
|
|
2107
|
+
this.children = children;
|
|
2108
|
+
}
|
|
2109
|
+
this.image_path = '/images/categories/';
|
|
1787
2110
|
}
|
|
1788
|
-
|
|
1789
|
-
this.
|
|
2111
|
+
else {
|
|
2112
|
+
this.id = `<<SUB>>${this.esolve_id}`;
|
|
2113
|
+
this.image_path = '/images/subcategories/';
|
|
1790
2114
|
}
|
|
1791
|
-
if (
|
|
1792
|
-
|
|
2115
|
+
if (seo_title.trim() === '') {
|
|
2116
|
+
seo_title = this.description;
|
|
1793
2117
|
}
|
|
2118
|
+
this.seo_details = new EsolveSeoInfo(seo_title, seo_description, seo_keywords);
|
|
1794
2119
|
}
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
class EsolveBannerImage {
|
|
1798
|
-
constructor(id, image_type, width, height, filename, hotspots) {
|
|
1799
|
-
this.id = id;
|
|
1800
|
-
this.image_type = image_type;
|
|
1801
|
-
this.width = width;
|
|
1802
|
-
this.height = height;
|
|
1803
|
-
this.filename = filename;
|
|
1804
|
-
this.hotspots = hotspots;
|
|
2120
|
+
get small_image_src() {
|
|
2121
|
+
return this.getImagePath('small');
|
|
1805
2122
|
}
|
|
1806
|
-
get
|
|
1807
|
-
return '
|
|
2123
|
+
get thumbnail_image_src() {
|
|
2124
|
+
return this.getImagePath('thumb');
|
|
1808
2125
|
}
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
this.
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
2126
|
+
get tiny_image_src() {
|
|
2127
|
+
return this.getImagePath('tiny');
|
|
2128
|
+
}
|
|
2129
|
+
getImagePath(image_size) {
|
|
2130
|
+
if (this.image_name !== '') {
|
|
2131
|
+
return `${this.image_path}${image_size}/${this.image_name}`;
|
|
2132
|
+
}
|
|
2133
|
+
return '';
|
|
1817
2134
|
}
|
|
1818
2135
|
}
|
|
1819
2136
|
|
|
1820
|
-
class
|
|
2137
|
+
class EsolveCategoryTreeService {
|
|
1821
2138
|
constructor(config, http) {
|
|
1822
2139
|
this.config = config;
|
|
1823
2140
|
this.http = http;
|
|
1824
2141
|
}
|
|
1825
2142
|
/**
|
|
1826
|
-
* Retrieves
|
|
1827
|
-
*
|
|
1828
|
-
* @returns An observable of eSolve banners.
|
|
2143
|
+
* Retrieves the category tree from eSolve instance and coverts it to the correct format.
|
|
1829
2144
|
*/
|
|
1830
|
-
|
|
1831
|
-
let params = new HttpParams({
|
|
1832
|
-
fromObject: { enable_date_filter }
|
|
1833
|
-
});
|
|
1834
|
-
if (identifier) {
|
|
1835
|
-
params = params.set('identifier', identifier);
|
|
1836
|
-
}
|
|
1837
|
-
if (banner_display_container) {
|
|
1838
|
-
params = params.set('banner_display_container', banner_display_container);
|
|
1839
|
-
}
|
|
2145
|
+
getCategoryTree() {
|
|
1840
2146
|
return this.http
|
|
1841
|
-
.get(`${this.config.api_url}/get-
|
|
2147
|
+
.get(`${this.config.api_url}/get-tree.php`)
|
|
1842
2148
|
.pipe(map((response) => {
|
|
1843
2149
|
if (response.records === undefined) {
|
|
1844
2150
|
throw response;
|
|
1845
2151
|
}
|
|
1846
|
-
return this.
|
|
2152
|
+
return this.processTree(response.records);
|
|
1847
2153
|
}));
|
|
1848
2154
|
}
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
2155
|
+
/**
|
|
2156
|
+
* Retrieve the details of a category tree item from the eSolve instance and
|
|
2157
|
+
* converts it to the correct format.
|
|
2158
|
+
*
|
|
2159
|
+
* @param options Filter options
|
|
2160
|
+
*/
|
|
2161
|
+
getCategoryTreeItem(options) {
|
|
2162
|
+
let type;
|
|
2163
|
+
let esolve_id;
|
|
2164
|
+
let sef_description;
|
|
2165
|
+
if (options.id) {
|
|
2166
|
+
const categoryIdentifier = this.processID(options.id);
|
|
2167
|
+
if (categoryIdentifier) {
|
|
2168
|
+
type = categoryIdentifier.type;
|
|
2169
|
+
esolve_id = categoryIdentifier.esolve_id;
|
|
1855
2170
|
}
|
|
1856
2171
|
}
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
if ((banner_type === 'hotspot') && (image_record.hotspots)) {
|
|
1865
|
-
const hotspots = this.processBannerImageHotspots(image_record.hotspots);
|
|
1866
|
-
image.hotspots = hotspots;
|
|
1867
|
-
}
|
|
1868
|
-
images.push(image);
|
|
2172
|
+
else if (options.type) {
|
|
2173
|
+
type = options.type;
|
|
2174
|
+
if (options.esolve_id) {
|
|
2175
|
+
esolve_id = options.esolve_id;
|
|
2176
|
+
}
|
|
2177
|
+
else if (options.sef_description) {
|
|
2178
|
+
sef_description = options.sef_description;
|
|
1869
2179
|
}
|
|
1870
2180
|
}
|
|
1871
|
-
|
|
2181
|
+
if (type && (esolve_id || sef_description)) {
|
|
2182
|
+
let params = new HttpParams();
|
|
2183
|
+
params = params.set('type', type);
|
|
2184
|
+
if (esolve_id) {
|
|
2185
|
+
params = params.set('id', esolve_id);
|
|
2186
|
+
}
|
|
2187
|
+
if (sef_description) {
|
|
2188
|
+
params = params.set('sef_description', sef_description);
|
|
2189
|
+
}
|
|
2190
|
+
return this.http
|
|
2191
|
+
.get(`${this.config.api_url}/get-tree-item.php`, { params })
|
|
2192
|
+
.pipe(map((response) => {
|
|
2193
|
+
if ((response.records === undefined) ||
|
|
2194
|
+
(response.records.length <= 0)) {
|
|
2195
|
+
throw response;
|
|
2196
|
+
}
|
|
2197
|
+
return this.processTreeItem(response.records[0]);
|
|
2198
|
+
}));
|
|
2199
|
+
}
|
|
2200
|
+
return throwError('Invalid options');
|
|
1872
2201
|
}
|
|
1873
2202
|
/**
|
|
1874
|
-
*
|
|
1875
|
-
*
|
|
1876
|
-
* @
|
|
2203
|
+
* Processes the eSolve tree records and converts them into the correct format.
|
|
2204
|
+
*
|
|
2205
|
+
* @param tree_records Records to process
|
|
1877
2206
|
*/
|
|
1878
|
-
|
|
1879
|
-
const
|
|
1880
|
-
if (
|
|
1881
|
-
for (const
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
2207
|
+
processTree(tree_records) {
|
|
2208
|
+
const tree_items = [];
|
|
2209
|
+
if (tree_records) {
|
|
2210
|
+
for (const tree_record of tree_records) {
|
|
2211
|
+
let esolve_id = '';
|
|
2212
|
+
let parent_id = '';
|
|
2213
|
+
let children = [];
|
|
2214
|
+
if (tree_record.type === 'category') {
|
|
2215
|
+
children = this.processTree(tree_record.children);
|
|
2216
|
+
esolve_id = tree_record.menu_id;
|
|
2217
|
+
parent_id = tree_record.owner_menu_id;
|
|
1888
2218
|
}
|
|
1889
|
-
|
|
1890
|
-
|
|
2219
|
+
else {
|
|
2220
|
+
esolve_id = tree_record.id;
|
|
2221
|
+
parent_id = tree_record.menu_id;
|
|
1891
2222
|
}
|
|
1892
|
-
|
|
1893
|
-
url: record.link.url,
|
|
1894
|
-
target: record.link.target
|
|
1895
|
-
}, image_sets);
|
|
1896
|
-
banners.push(banner);
|
|
2223
|
+
tree_items.push(new EsolveCategoryTreeItem(tree_record.type, esolve_id, parent_id, tree_record.description, tree_record.sef_description, tree_record.seo_description, tree_record.sort_priority, tree_record.active, tree_record.display_only, tree_record.image, tree_record.seo_page_title, tree_record.seo_keywords, tree_record.short_description, children));
|
|
1897
2224
|
}
|
|
1898
2225
|
}
|
|
1899
|
-
return
|
|
2226
|
+
return tree_items;
|
|
2227
|
+
}
|
|
2228
|
+
processTreeItem(record) {
|
|
2229
|
+
return new EsolveCategoryTreeItem(record.type, record.id, record.parent_id, record.description, record.sef_description, record.short_description, record.sort_priority, record.active, record.display_only, record.image, record.seo_page_title, record.seo_keywords, record.seo_description);
|
|
2230
|
+
}
|
|
2231
|
+
processID(id) {
|
|
2232
|
+
let type;
|
|
2233
|
+
let esolve_id;
|
|
2234
|
+
const type_code_regex = /^\<\<(CAT|SUB)\>\>/g;
|
|
2235
|
+
const match_results = id.match(type_code_regex);
|
|
2236
|
+
if (match_results) {
|
|
2237
|
+
const type_code = match_results[0];
|
|
2238
|
+
type = (type_code === '<<CAT>>' ? 'category' : 'subcategory');
|
|
2239
|
+
esolve_id = id.replace(type_code_regex, '');
|
|
2240
|
+
return {
|
|
2241
|
+
type,
|
|
2242
|
+
esolve_id
|
|
2243
|
+
};
|
|
2244
|
+
}
|
|
2245
|
+
return null;
|
|
1900
2246
|
}
|
|
1901
2247
|
}
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type:
|
|
2248
|
+
EsolveCategoryTreeService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveCategoryTreeService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2249
|
+
EsolveCategoryTreeService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveCategoryTreeService, providedIn: 'root' });
|
|
2250
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveCategoryTreeService, decorators: [{
|
|
1905
2251
|
type: Injectable,
|
|
1906
2252
|
args: [{
|
|
1907
2253
|
providedIn: 'root',
|
|
@@ -1911,46 +2257,102 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
1911
2257
|
args: [ESOLVE_CONNECT_CONFIG]
|
|
1912
2258
|
}] }, { type: i1$2.HttpClient }]; } });
|
|
1913
2259
|
|
|
1914
|
-
class
|
|
1915
|
-
constructor(
|
|
1916
|
-
this.
|
|
1917
|
-
this.
|
|
1918
|
-
this.
|
|
1919
|
-
this.
|
|
2260
|
+
class EsolveManufacturer {
|
|
2261
|
+
constructor(id, manufacturer, sef_manufacturer, title, article, sort_priority, is_active, featured, image_name, seo_title = '', seo_keywords = '', seo_description = '') {
|
|
2262
|
+
this.id = id;
|
|
2263
|
+
this.manufacturer = manufacturer;
|
|
2264
|
+
this.sef_manufacturer = sef_manufacturer;
|
|
2265
|
+
this.title = title;
|
|
2266
|
+
this.article = article;
|
|
2267
|
+
this.sort_priority = sort_priority;
|
|
2268
|
+
this.is_active = is_active;
|
|
2269
|
+
this.featured = featured;
|
|
2270
|
+
this.image_name = image_name;
|
|
2271
|
+
this.image_path = '/images/manufacturers/';
|
|
2272
|
+
if (this.title.trim() === '') {
|
|
2273
|
+
this.title = this.manufacturer;
|
|
2274
|
+
}
|
|
2275
|
+
if (seo_title.trim() === '') {
|
|
2276
|
+
seo_title = this.title;
|
|
2277
|
+
}
|
|
2278
|
+
this.seo_details = new EsolveSeoInfo(seo_title, seo_description, seo_keywords);
|
|
2279
|
+
}
|
|
2280
|
+
get original_image_src() {
|
|
2281
|
+
return this.getImagePath('original');
|
|
2282
|
+
}
|
|
2283
|
+
get small_image_src() {
|
|
2284
|
+
return this.getImagePath('small');
|
|
2285
|
+
}
|
|
2286
|
+
get thumbnail_image_src() {
|
|
2287
|
+
return this.getImagePath('thumb');
|
|
2288
|
+
}
|
|
2289
|
+
get tiny_image_src() {
|
|
2290
|
+
return this.getImagePath('tiny');
|
|
2291
|
+
}
|
|
2292
|
+
getImagePath(image_size) {
|
|
2293
|
+
if (this.image_name !== '') {
|
|
2294
|
+
return `${this.image_path}${image_size}/${this.image_name}`;
|
|
2295
|
+
}
|
|
2296
|
+
return '';
|
|
1920
2297
|
}
|
|
1921
2298
|
}
|
|
1922
2299
|
|
|
1923
|
-
class
|
|
2300
|
+
class EsolveManufacturersService {
|
|
1924
2301
|
constructor(config, http) {
|
|
1925
2302
|
this.config = config;
|
|
1926
2303
|
this.http = http;
|
|
1927
2304
|
}
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
2305
|
+
getManufacturer(id) {
|
|
2306
|
+
const params = new HttpParams({
|
|
2307
|
+
fromObject: { manufacturers_id: id }
|
|
2308
|
+
});
|
|
2309
|
+
return this.getManufacturerSingle(params);
|
|
2310
|
+
}
|
|
2311
|
+
getManufacturerFromSEF(sef_manufacturer) {
|
|
2312
|
+
const params = new HttpParams({
|
|
2313
|
+
fromObject: { sef_manufacturer }
|
|
2314
|
+
});
|
|
2315
|
+
return this.getManufacturerSingle(params);
|
|
2316
|
+
}
|
|
2317
|
+
getManufacturers(options) {
|
|
2318
|
+
let params = new HttpParams();
|
|
2319
|
+
if (options?.featured_only) {
|
|
2320
|
+
params = params.set('featured_only', options.featured_only);
|
|
2321
|
+
}
|
|
2322
|
+
return this.getManufacturerRecords(params).pipe(map((records) => {
|
|
2323
|
+
const manufacturers = [];
|
|
2324
|
+
for (const record of records) {
|
|
2325
|
+
manufacturers.push(this.processManufacturer(record));
|
|
2326
|
+
}
|
|
2327
|
+
return manufacturers;
|
|
2328
|
+
}), catchError(() => {
|
|
2329
|
+
return of([]);
|
|
1939
2330
|
}));
|
|
1940
2331
|
}
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
2332
|
+
getManufacturerSingle(params) {
|
|
2333
|
+
return this.getManufacturerRecords(params).pipe(map((records) => {
|
|
2334
|
+
const record = records[0];
|
|
2335
|
+
return this.processManufacturer(record);
|
|
2336
|
+
}));
|
|
2337
|
+
}
|
|
2338
|
+
getManufacturerRecords(params) {
|
|
2339
|
+
return this.http
|
|
2340
|
+
.get(`${this.config.api_url}/get-manufacturers.php`, { params })
|
|
2341
|
+
.pipe(map((response) => {
|
|
2342
|
+
if ((response.records === undefined) ||
|
|
2343
|
+
(response.records.length <= 0)) {
|
|
2344
|
+
throw response;
|
|
1946
2345
|
}
|
|
1947
|
-
|
|
1948
|
-
|
|
2346
|
+
return response.records;
|
|
2347
|
+
}));
|
|
2348
|
+
}
|
|
2349
|
+
processManufacturer(record) {
|
|
2350
|
+
return new EsolveManufacturer(+record.id, record.manufacturer, record.sef_manufacturer, record.title, record.article, +record.sort_priority, !!+record.is_active, !!+record.featured, record.image_name, record.seo_page_title, record.seo_keywords, record.seo_description);
|
|
1949
2351
|
}
|
|
1950
2352
|
}
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type:
|
|
2353
|
+
EsolveManufacturersService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveManufacturersService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2354
|
+
EsolveManufacturersService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveManufacturersService, providedIn: 'root' });
|
|
2355
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveManufacturersService, decorators: [{
|
|
1954
2356
|
type: Injectable,
|
|
1955
2357
|
args: [{
|
|
1956
2358
|
providedIn: 'root',
|
|
@@ -1960,46 +2362,100 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
1960
2362
|
args: [ESOLVE_CONNECT_CONFIG]
|
|
1961
2363
|
}] }, { type: i1$2.HttpClient }]; } });
|
|
1962
2364
|
|
|
1963
|
-
class
|
|
2365
|
+
class EsolveRange {
|
|
2366
|
+
constructor(id, range, sef_range, manufacturers_id, title, article, is_active, featured, sort_priority, image_name, seo_title = '', seo_keywords = '', seo_description = '') {
|
|
2367
|
+
this.id = id;
|
|
2368
|
+
this.range = range;
|
|
2369
|
+
this.sef_range = sef_range;
|
|
2370
|
+
this.manufacturers_id = manufacturers_id;
|
|
2371
|
+
this.title = title;
|
|
2372
|
+
this.article = article;
|
|
2373
|
+
this.is_active = is_active;
|
|
2374
|
+
this.featured = featured;
|
|
2375
|
+
this.sort_priority = sort_priority;
|
|
2376
|
+
this.image_name = image_name;
|
|
2377
|
+
this.image_path = '/images/ranges/';
|
|
2378
|
+
if (this.title.trim() === '') {
|
|
2379
|
+
this.title = this.range;
|
|
2380
|
+
}
|
|
2381
|
+
if (seo_title.trim() === '') {
|
|
2382
|
+
seo_title = this.title;
|
|
2383
|
+
}
|
|
2384
|
+
this.seo_details = new EsolveSeoInfo(seo_title, seo_description, seo_keywords);
|
|
2385
|
+
}
|
|
2386
|
+
get image_src() {
|
|
2387
|
+
return this.getImagePath();
|
|
2388
|
+
}
|
|
2389
|
+
getImagePath() {
|
|
2390
|
+
if (this.image_name !== '') {
|
|
2391
|
+
return `${this.image_path}${this.image_name}`;
|
|
2392
|
+
}
|
|
2393
|
+
return '';
|
|
2394
|
+
}
|
|
2395
|
+
}
|
|
2396
|
+
|
|
2397
|
+
class EsolveRangesService {
|
|
1964
2398
|
constructor(config, http) {
|
|
1965
2399
|
this.config = config;
|
|
1966
2400
|
this.http = http;
|
|
1967
2401
|
}
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
2402
|
+
getRange(id) {
|
|
2403
|
+
const params = new HttpParams({
|
|
2404
|
+
fromObject: { ranges_id: id }
|
|
2405
|
+
});
|
|
2406
|
+
return this.getRangeSingle(params);
|
|
2407
|
+
}
|
|
2408
|
+
getRangeFromSEF(sef_range) {
|
|
2409
|
+
const params = new HttpParams({
|
|
2410
|
+
fromObject: { sef_range }
|
|
2411
|
+
});
|
|
2412
|
+
return this.getRangeSingle(params);
|
|
2413
|
+
}
|
|
2414
|
+
getRanges(options) {
|
|
1975
2415
|
let params = new HttpParams();
|
|
1976
|
-
if (
|
|
1977
|
-
params = params.
|
|
2416
|
+
if (options?.featured_only) {
|
|
2417
|
+
params = params.set('featured_only', options.featured_only);
|
|
1978
2418
|
}
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
2419
|
+
if (options?.manufacturers_id) {
|
|
2420
|
+
params = params.set('manufacturers_id', options.manufacturers_id);
|
|
2421
|
+
}
|
|
2422
|
+
return this.getRangeRecords(params).pipe(map((records) => {
|
|
2423
|
+
const ranges = [];
|
|
2424
|
+
for (const record of records) {
|
|
2425
|
+
ranges.push(this.processRange(record));
|
|
1982
2426
|
}
|
|
1983
|
-
return
|
|
2427
|
+
return ranges;
|
|
2428
|
+
}), catchError(() => {
|
|
2429
|
+
return of([]);
|
|
1984
2430
|
}));
|
|
1985
2431
|
}
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
2432
|
+
getRangeSingle(params) {
|
|
2433
|
+
return this.getRangeRecords(params).pipe(map((records) => {
|
|
2434
|
+
const record = records[0];
|
|
2435
|
+
return this.processRange(record);
|
|
2436
|
+
}));
|
|
2437
|
+
}
|
|
2438
|
+
getRangeRecords(params) {
|
|
2439
|
+
return this.http
|
|
2440
|
+
.get(`${this.config.api_url}/get-ranges.php`, { params })
|
|
2441
|
+
.pipe(map((response) => {
|
|
2442
|
+
if ((response.records === undefined) ||
|
|
2443
|
+
(response.records.length <= 0)) {
|
|
2444
|
+
throw response;
|
|
1992
2445
|
}
|
|
1993
|
-
|
|
1994
|
-
|
|
2446
|
+
return response.records;
|
|
2447
|
+
}));
|
|
2448
|
+
}
|
|
2449
|
+
processRange(record) {
|
|
2450
|
+
return new EsolveRange(+record.id, record.range, record.sef_range, record.manufacturers_id, record.title, record.article, !!+record.is_active, !!+record.featured, +record.sort_priority, record.image_name, record.seo_page_title, record.seo_keywords, record.seo_description);
|
|
1995
2451
|
}
|
|
1996
2452
|
}
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type:
|
|
2453
|
+
EsolveRangesService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveRangesService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2454
|
+
EsolveRangesService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveRangesService, providedIn: 'root' });
|
|
2455
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveRangesService, decorators: [{
|
|
2000
2456
|
type: Injectable,
|
|
2001
2457
|
args: [{
|
|
2002
|
-
providedIn: 'root'
|
|
2458
|
+
providedIn: 'root',
|
|
2003
2459
|
}]
|
|
2004
2460
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
2005
2461
|
type: Inject,
|
|
@@ -2025,26 +2481,26 @@ class EsolveStockPrice {
|
|
|
2025
2481
|
* Create stock price instance
|
|
2026
2482
|
* @param base_price Price without tax
|
|
2027
2483
|
* @param base_price_with_tax Price with tax
|
|
2028
|
-
* @param sell_price Price without tax and with discounts applied if
|
|
2029
|
-
* @param sell_price_with_tax Price with tax and with discounts applied if
|
|
2484
|
+
* @param sell_price Price without tax and with discounts applied if applicable
|
|
2485
|
+
* @param sell_price_with_tax Price with tax and with discounts applied if applicable
|
|
2030
2486
|
*/
|
|
2031
2487
|
constructor(
|
|
2032
2488
|
/**
|
|
2033
2489
|
* Price without tax
|
|
2034
2490
|
*/
|
|
2035
|
-
base_price,
|
|
2491
|
+
base_price = 0,
|
|
2036
2492
|
/**
|
|
2037
2493
|
* Price with tax
|
|
2038
2494
|
*/
|
|
2039
|
-
base_price_with_tax,
|
|
2495
|
+
base_price_with_tax = 0,
|
|
2040
2496
|
/**
|
|
2041
|
-
* Price without tax and with discounts applied if
|
|
2497
|
+
* Price without tax and with discounts applied if applicable
|
|
2042
2498
|
*/
|
|
2043
|
-
sell_price,
|
|
2499
|
+
sell_price = 0,
|
|
2044
2500
|
/**
|
|
2045
|
-
* Price with tax and with discounts applied if
|
|
2501
|
+
* Price with tax and with discounts applied if applicable
|
|
2046
2502
|
*/
|
|
2047
|
-
sell_price_with_tax) {
|
|
2503
|
+
sell_price_with_tax = 0) {
|
|
2048
2504
|
this.base_price = base_price;
|
|
2049
2505
|
this.base_price_with_tax = base_price_with_tax;
|
|
2050
2506
|
this.sell_price = sell_price;
|
|
@@ -2060,139 +2516,220 @@ class EsolveStockPrice {
|
|
|
2060
2516
|
}
|
|
2061
2517
|
}
|
|
2062
2518
|
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
|
|
2079
|
-
|
|
2080
|
-
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
|
|
2093
|
-
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2519
|
+
class EsolveStockItemBase {
|
|
2520
|
+
constructor(record = {}) {
|
|
2521
|
+
/**
|
|
2522
|
+
* eSolve Generated ID
|
|
2523
|
+
*/
|
|
2524
|
+
this.id = 0;
|
|
2525
|
+
/**
|
|
2526
|
+
* Code identifying the stock item
|
|
2527
|
+
*/
|
|
2528
|
+
this.code = '';
|
|
2529
|
+
/**
|
|
2530
|
+
* Name of the stock item
|
|
2531
|
+
*/
|
|
2532
|
+
this.name = '';
|
|
2533
|
+
/**
|
|
2534
|
+
* Search engine friendly name
|
|
2535
|
+
*/
|
|
2536
|
+
this.sef_name = '';
|
|
2537
|
+
/**
|
|
2538
|
+
* Short description of stock item
|
|
2539
|
+
*/
|
|
2540
|
+
this.description = '';
|
|
2541
|
+
/**
|
|
2542
|
+
* Full description of stock item
|
|
2543
|
+
*/
|
|
2544
|
+
this.extended_description = '';
|
|
2545
|
+
/**
|
|
2546
|
+
* Active state
|
|
2547
|
+
*/
|
|
2548
|
+
this.active = false;
|
|
2549
|
+
/**
|
|
2550
|
+
* Featured state
|
|
2551
|
+
*/
|
|
2552
|
+
this.featured = false;
|
|
2553
|
+
/**
|
|
2554
|
+
* ID of default category linked to the stock item
|
|
2555
|
+
*
|
|
2556
|
+
* @deprecated Use `category.esolve_id` field instead
|
|
2557
|
+
*/
|
|
2558
|
+
this.category_id = '';
|
|
2559
|
+
/**
|
|
2560
|
+
* ID of default subcategory linked to the stock item
|
|
2561
|
+
*
|
|
2562
|
+
* @deprecated Use `subcategory.esolve_id` field instead
|
|
2563
|
+
*/
|
|
2564
|
+
this.subcategory_id = 0;
|
|
2565
|
+
/**
|
|
2566
|
+
* ID of linked manufacturer
|
|
2567
|
+
*
|
|
2568
|
+
* @deprecated Use `manufacturer.id` field instead
|
|
2569
|
+
*/
|
|
2570
|
+
this.manufacturers_id = 0;
|
|
2571
|
+
/**
|
|
2572
|
+
* ID of linked range
|
|
2573
|
+
*
|
|
2574
|
+
* @deprecated Use `range.id` field instead
|
|
2575
|
+
*/
|
|
2576
|
+
this.ranges_id = 0;
|
|
2577
|
+
/**
|
|
2578
|
+
* Linked tags
|
|
2579
|
+
*/
|
|
2580
|
+
this.tags = [];
|
|
2581
|
+
/**
|
|
2582
|
+
* Linked topics
|
|
2583
|
+
*/
|
|
2584
|
+
this.topics = [];
|
|
2585
|
+
/**
|
|
2586
|
+
* Stock badges
|
|
2587
|
+
*/
|
|
2588
|
+
this.badges = [];
|
|
2589
|
+
/**
|
|
2590
|
+
* Colours
|
|
2591
|
+
*/
|
|
2592
|
+
this.colours = [];
|
|
2593
|
+
/**
|
|
2594
|
+
* Image filename
|
|
2595
|
+
*/
|
|
2596
|
+
this.image_name = '';
|
|
2597
|
+
let seo_title = '';
|
|
2598
|
+
let seo_keywords = '';
|
|
2599
|
+
let base_price = 0;
|
|
2600
|
+
let base_price_with_tax = 0;
|
|
2601
|
+
let sell_price = 0;
|
|
2602
|
+
let sell_price_with_tax = 0;
|
|
2603
|
+
if (record) {
|
|
2604
|
+
this.id = +(record.id ?? 0);
|
|
2605
|
+
this.code = record.code ?? '';
|
|
2606
|
+
this.name = record.name ?? '';
|
|
2607
|
+
this.sef_name = record.sef_name ?? '';
|
|
2608
|
+
this.description = record.description ?? '';
|
|
2609
|
+
this.extended_description = record.extended_description ?? '';
|
|
2610
|
+
this.image_name = record.image_name ?? '';
|
|
2611
|
+
this.category_id = record.category_id ?? '';
|
|
2612
|
+
this.subcategory_id = +(record.subcategory_id ?? 0);
|
|
2613
|
+
this.manufacturers_id = +(record.manufacturers_id ?? 0);
|
|
2614
|
+
this.ranges_id = +(record.ranges_id ?? 0);
|
|
2615
|
+
this.active = !!+(record.is_active ?? false);
|
|
2616
|
+
this.featured = !!+(record.is_featured ?? false);
|
|
2617
|
+
base_price = +(record.regular_sellprice ?? 0);
|
|
2618
|
+
base_price_with_tax = +(record.regular_sellprice_inclusive ?? 0);
|
|
2619
|
+
sell_price = +(record.sellprice ?? 0);
|
|
2620
|
+
sell_price_with_tax = +(record.sellprice_inclusive ?? 0);
|
|
2621
|
+
if ((record.tags) && (record.tags.length > 0)) {
|
|
2622
|
+
for (const tag of record.tags) {
|
|
2623
|
+
this.tags.push(new EsolveTag(+tag.id, tag.tag_phrase, +tag.tag_weight, tag.description));
|
|
2624
|
+
}
|
|
2625
|
+
}
|
|
2626
|
+
if ((record.topics) && (record.topics.length > 0)) {
|
|
2627
|
+
for (const topic of record.topics) {
|
|
2628
|
+
this.topics.push(new EsolveTopic(+topic.id, topic.name, topic.short_description, +topic.sort_priority));
|
|
2629
|
+
}
|
|
2630
|
+
}
|
|
2631
|
+
if ((record.badges) && (record.badges.length > 0)) {
|
|
2632
|
+
for (const badge of record.badges) {
|
|
2633
|
+
this.badges.push(new EsolveStockBadge(+badge.id, badge.text, badge.identifier, badge.font_colour, badge.badge_colour, +badge.sort_priority));
|
|
2634
|
+
}
|
|
2635
|
+
}
|
|
2636
|
+
if (record.category) {
|
|
2637
|
+
this.category = new EsolveCategoryTreeItem(record.category.type, record.category.id, record.category.parent_id, record.category.description, record.category.sef_description, record.category.short_description, record.category.sort_priority, record.category.active, record.category.display_only, record.category.image, record.category.seo_page_title, record.category.seo_keywords, record.category.seo_description);
|
|
2638
|
+
}
|
|
2639
|
+
if (record.subcategory) {
|
|
2640
|
+
this.subcategory = new EsolveCategoryTreeItem(record.subcategory.type, record.subcategory.id, record.subcategory.parent_id, record.subcategory.description, record.subcategory.sef_description, record.subcategory.short_description, record.subcategory.sort_priority, record.subcategory.active, record.subcategory.display_only, record.subcategory.image, record.subcategory.seo_page_title, record.subcategory.seo_keywords, record.subcategory.seo_description);
|
|
2641
|
+
}
|
|
2642
|
+
if (record.manufacturer) {
|
|
2643
|
+
this.manufacturer = new EsolveManufacturer(record.manufacturer.id, record.manufacturer.manufacturer, record.manufacturer.sef_manufacturer, record.manufacturer.title, record.manufacturer.article, record.manufacturer.sort_priority, record.manufacturer.is_active, record.manufacturer.featured, record.manufacturer.image_name, record.manufacturer.seo_page_title, record.manufacturer.seo_keywords, record.manufacturer.seo_description);
|
|
2644
|
+
}
|
|
2645
|
+
if (record.range) {
|
|
2646
|
+
this.range = new EsolveRange(record.range.id, record.range.range, record.range.sef_range, record.range.manufacturers_id, record.range.title, record.range.article, record.range.is_active, record.range.featured, record.range.sort_priority, record.range.image_name, record.range.seo_page_title, record.range.seo_keywords, record.range.seo_description);
|
|
2647
|
+
}
|
|
2648
|
+
if (record.colours && record.colours.length > 0) {
|
|
2649
|
+
for (const colour of record.colours) {
|
|
2650
|
+
this.colours.push(new EsolveColour(colour));
|
|
2651
|
+
}
|
|
2652
|
+
}
|
|
2653
|
+
if (record.custom_fields) {
|
|
2654
|
+
this.custom_fields = record.custom_fields;
|
|
2655
|
+
}
|
|
2656
|
+
seo_title = record.seo_page_title ?? '';
|
|
2657
|
+
seo_keywords = record.seo_keywords ?? '';
|
|
2658
|
+
}
|
|
2659
|
+
this.price = new EsolveStockPrice(base_price, base_price_with_tax, sell_price, sell_price_with_tax);
|
|
2162
2660
|
if (seo_title.trim() === '') {
|
|
2163
2661
|
seo_title = this.name;
|
|
2164
2662
|
}
|
|
2165
|
-
this.seo_details = new
|
|
2663
|
+
this.seo_details = new EsolveSeoInfo(seo_title, this.description, seo_keywords);
|
|
2166
2664
|
}
|
|
2167
2665
|
/**
|
|
2168
2666
|
* Path to tiny stock image
|
|
2169
2667
|
*/
|
|
2170
2668
|
get tiny_image_src() {
|
|
2171
|
-
return
|
|
2669
|
+
return this.getImagePath('tiny');
|
|
2172
2670
|
}
|
|
2173
2671
|
/**
|
|
2174
2672
|
* Path to thumbnail stock image
|
|
2175
2673
|
*/
|
|
2176
2674
|
get thumbnail_image_src() {
|
|
2177
|
-
return
|
|
2675
|
+
return this.getImagePath('thumb');
|
|
2178
2676
|
}
|
|
2179
2677
|
/**
|
|
2180
2678
|
* Path to small stock image
|
|
2181
2679
|
*/
|
|
2182
2680
|
get small_image_src() {
|
|
2183
|
-
return
|
|
2681
|
+
return this.getImagePath('small');
|
|
2184
2682
|
}
|
|
2185
2683
|
/**
|
|
2186
2684
|
* Path to big stock image
|
|
2187
2685
|
*/
|
|
2188
2686
|
get big_image_src() {
|
|
2189
|
-
return
|
|
2687
|
+
return this.getImagePath('big');
|
|
2190
2688
|
}
|
|
2191
2689
|
/**
|
|
2192
2690
|
* Path to original stock image
|
|
2193
2691
|
*/
|
|
2194
2692
|
get original_image_src() {
|
|
2195
|
-
return
|
|
2693
|
+
return this.getImagePath('original');
|
|
2694
|
+
}
|
|
2695
|
+
getImagePath(image_size) {
|
|
2696
|
+
if (this.image_name !== '') {
|
|
2697
|
+
return `/images/stock/${image_size}/${this.image_name}`;
|
|
2698
|
+
}
|
|
2699
|
+
return '';
|
|
2700
|
+
}
|
|
2701
|
+
}
|
|
2702
|
+
|
|
2703
|
+
class EsolveStockGroupItem extends EsolveStockItemBase {
|
|
2704
|
+
constructor(record) {
|
|
2705
|
+
super(record);
|
|
2706
|
+
}
|
|
2707
|
+
}
|
|
2708
|
+
|
|
2709
|
+
class EsolveStockGroup {
|
|
2710
|
+
constructor(group, records = []) {
|
|
2711
|
+
this.group = group;
|
|
2712
|
+
this.items = [];
|
|
2713
|
+
if (records.length > 0) {
|
|
2714
|
+
for (const record of records) {
|
|
2715
|
+
this.items.push(new EsolveStockGroupItem(record));
|
|
2716
|
+
}
|
|
2717
|
+
}
|
|
2718
|
+
}
|
|
2719
|
+
}
|
|
2720
|
+
|
|
2721
|
+
/**
|
|
2722
|
+
* Stock Item object. It can be a service or a product (physical and/or digital).
|
|
2723
|
+
*/
|
|
2724
|
+
class EsolveStockItem extends EsolveStockItemBase {
|
|
2725
|
+
/**
|
|
2726
|
+
* Constructs an instance of EsolveStockItem
|
|
2727
|
+
*/
|
|
2728
|
+
constructor(record) {
|
|
2729
|
+
super(record);
|
|
2730
|
+
if (record?.group && record.grouped_items) {
|
|
2731
|
+
this.group = new EsolveStockGroup(record.group, record.grouped_items);
|
|
2732
|
+
}
|
|
2196
2733
|
}
|
|
2197
2734
|
}
|
|
2198
2735
|
|
|
@@ -2207,413 +2744,200 @@ class EsolveStockItemList {
|
|
|
2207
2744
|
}
|
|
2208
2745
|
}
|
|
2209
2746
|
|
|
2210
|
-
class
|
|
2211
|
-
constructor(
|
|
2212
|
-
|
|
2213
|
-
this.
|
|
2747
|
+
class EsolveRecipeStockItem extends EsolveStockItemBase {
|
|
2748
|
+
constructor(record) {
|
|
2749
|
+
super(record);
|
|
2750
|
+
this.qty = 0;
|
|
2751
|
+
this.qty = +(record?.qty ?? 0);
|
|
2214
2752
|
}
|
|
2215
|
-
|
|
2216
|
-
* Retrieves the stock record from the eSolve instance using the code.
|
|
2217
|
-
* @param code eSolve stock code
|
|
2218
|
-
*/
|
|
2219
|
-
getStockItem(code) {
|
|
2220
|
-
const params = new HttpParams({
|
|
2221
|
-
fromObject: {
|
|
2222
|
-
code
|
|
2223
|
-
}
|
|
2224
|
-
});
|
|
2225
|
-
return this.getStockRecords(params).pipe(map(response => {
|
|
2226
|
-
if ((response.records === undefined) || (response.records.length <= 0)) {
|
|
2227
|
-
throw response;
|
|
2228
|
-
}
|
|
2229
|
-
const stockRecord = response.records[0];
|
|
2230
|
-
return this.processStockItem(stockRecord);
|
|
2231
|
-
}));
|
|
2232
|
-
}
|
|
2233
|
-
/**
|
|
2234
|
-
* Retrieves the stock record from the eSolve instance using the SEF name.
|
|
2235
|
-
* @param sef_name SEF name of the stock item
|
|
2236
|
-
*/
|
|
2237
|
-
getStockItemFromSEF(sef_name) {
|
|
2238
|
-
const params = new HttpParams({
|
|
2239
|
-
fromObject: {
|
|
2240
|
-
sef_name
|
|
2241
|
-
}
|
|
2242
|
-
});
|
|
2243
|
-
return this.getStockRecords(params).pipe(map(response => {
|
|
2244
|
-
if ((response.records === undefined) || (response.records.length <= 0)) {
|
|
2245
|
-
throw response;
|
|
2246
|
-
}
|
|
2247
|
-
const stockRecord = response.records[0];
|
|
2248
|
-
return this.processStockItem(stockRecord);
|
|
2249
|
-
}));
|
|
2250
|
-
}
|
|
2251
|
-
/**
|
|
2252
|
-
* Retrieves list of stock from the eSolve instance using info provided
|
|
2253
|
-
* @param options Stock filter options
|
|
2254
|
-
*/
|
|
2255
|
-
getStockItems(options) {
|
|
2256
|
-
let params = new HttpParams();
|
|
2257
|
-
if (options.page) {
|
|
2258
|
-
params = params.set('page', options.page);
|
|
2259
|
-
}
|
|
2260
|
-
if (options.rows) {
|
|
2261
|
-
params = params.set('rows', options.rows);
|
|
2262
|
-
}
|
|
2263
|
-
if (options.search_phrase) {
|
|
2264
|
-
params = params.set('search_phrase', options.search_phrase);
|
|
2265
|
-
}
|
|
2266
|
-
if (options.display_only) {
|
|
2267
|
-
params = params.set('display_only', options.display_only);
|
|
2268
|
-
}
|
|
2269
|
-
if (options.is_active) {
|
|
2270
|
-
params = params.set('is_active', options.is_active);
|
|
2271
|
-
}
|
|
2272
|
-
if (options.category_id) {
|
|
2273
|
-
params = params.set('category_id', options.category_id);
|
|
2274
|
-
}
|
|
2275
|
-
if (options.subcategory_id) {
|
|
2276
|
-
params = params.set('subcategory_id', options.subcategory_id);
|
|
2277
|
-
}
|
|
2278
|
-
if (options.manufacturers_id) {
|
|
2279
|
-
params = params.set('manufacturers_id', options.manufacturers_id);
|
|
2280
|
-
}
|
|
2281
|
-
if (options.ranges_id) {
|
|
2282
|
-
params = params.set('ranges_id', options.ranges_id);
|
|
2283
|
-
}
|
|
2284
|
-
if (options.specials_id) {
|
|
2285
|
-
params = params.set('specials_id', options.specials_id);
|
|
2286
|
-
}
|
|
2287
|
-
if (options.tag_id_list) {
|
|
2288
|
-
if (options.tag_id_list.length > 0) {
|
|
2289
|
-
params = params.set('tag_id', options.tag_id_list.join(','));
|
|
2290
|
-
}
|
|
2291
|
-
}
|
|
2292
|
-
if (options.topic_id_list) {
|
|
2293
|
-
if (options.topic_id_list.length > 0) {
|
|
2294
|
-
params = params.set('topic_id', options.topic_id_list.join(','));
|
|
2295
|
-
}
|
|
2296
|
-
}
|
|
2297
|
-
return this.getStockRecords(params).pipe(map(response => {
|
|
2298
|
-
if ((response.records === undefined) || (response.records.length <= 0)) {
|
|
2299
|
-
throw response;
|
|
2300
|
-
}
|
|
2301
|
-
const stockItems = [];
|
|
2302
|
-
response.records.forEach(stockRecord => {
|
|
2303
|
-
stockItems.push(this.processStockItem(stockRecord));
|
|
2304
|
-
});
|
|
2305
|
-
return new EsolveStockItemList(stockItems, +response.additional_data.total_records, options.page ?? 0);
|
|
2306
|
-
}));
|
|
2307
|
-
}
|
|
2308
|
-
/**
|
|
2309
|
-
* Processes the eSolve stock item record and converts it to StockItem object.
|
|
2310
|
-
* @param record eSolve stock item record
|
|
2311
|
-
*/
|
|
2312
|
-
processStockItem(record) {
|
|
2313
|
-
const tags = [];
|
|
2314
|
-
const topics = [];
|
|
2315
|
-
const badges = [];
|
|
2316
|
-
if ((record.tags) && (record.tags.length > 0)) {
|
|
2317
|
-
for (const tag of record.tags) {
|
|
2318
|
-
tags.push(new EsolveTag(+tag.id, tag.tag_phrase, +tag.tag_weight, tag.description));
|
|
2319
|
-
}
|
|
2320
|
-
}
|
|
2321
|
-
if ((record.topics) && (record.topics.length > 0)) {
|
|
2322
|
-
for (const topic of record.topics) {
|
|
2323
|
-
topics.push(new EsolveTopic(+topic.id, topic.name, topic.short_description, +topic.sort_priority));
|
|
2324
|
-
}
|
|
2325
|
-
}
|
|
2326
|
-
if ((record.badges) && (record.badges.length > 0)) {
|
|
2327
|
-
for (const badge of record.badges) {
|
|
2328
|
-
badges.push(new EsolveStockBadge(+badge.id, badge.text, badge.identifier, badge.font_colour, badge.badge_colour, +badge.sort_priority));
|
|
2329
|
-
}
|
|
2330
|
-
}
|
|
2331
|
-
const price = new EsolveStockPrice(record.regular_sellprice, record.regular_sellprice_inclusive, record.sellprice, record.sellprice_inclusive);
|
|
2332
|
-
return new EsolveStockItem(+record.id, record.code, record.name, record.sef_name, record.description, record.extended_description, !!+record.is_active, !!+record.is_featured, record.image_name, price, tags, topics, badges, record.category_id, +record.subcategory_id, +record.manufacturers_id, +record.ranges_id, record.seo_page_title, record.seo_keywords);
|
|
2333
|
-
}
|
|
2334
|
-
/**
|
|
2335
|
-
* Retrieves stock records from HTTP params.
|
|
2336
|
-
* @param params HTTP client parameters
|
|
2337
|
-
*/
|
|
2338
|
-
getStockRecords(params) {
|
|
2339
|
-
return this.http.get(`${this.config.api_url}/get-items.php`, { params });
|
|
2340
|
-
}
|
|
2341
|
-
}
|
|
2342
|
-
EsolveStockService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveStockService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2343
|
-
EsolveStockService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveStockService, providedIn: 'root' });
|
|
2344
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveStockService, decorators: [{
|
|
2345
|
-
type: Injectable,
|
|
2346
|
-
args: [{
|
|
2347
|
-
providedIn: 'root',
|
|
2348
|
-
}]
|
|
2349
|
-
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
2350
|
-
type: Inject,
|
|
2351
|
-
args: [ESOLVE_CONNECT_CONFIG]
|
|
2352
|
-
}] }, { type: i1$2.HttpClient }]; } });
|
|
2753
|
+
}
|
|
2353
2754
|
|
|
2354
|
-
class
|
|
2355
|
-
constructor(
|
|
2356
|
-
|
|
2357
|
-
this.
|
|
2358
|
-
this.
|
|
2359
|
-
this.description = description;
|
|
2360
|
-
this.sef_description = sef_description;
|
|
2361
|
-
this.short_description = short_description;
|
|
2362
|
-
this.sort_priority = sort_priority;
|
|
2363
|
-
this.active = active;
|
|
2364
|
-
this.display_only = display_only;
|
|
2365
|
-
this.image_name = image_name;
|
|
2366
|
-
this.image_path = '';
|
|
2367
|
-
this.id = '';
|
|
2368
|
-
if (this.type === 'category') {
|
|
2369
|
-
this.id = `<<CAT>>${this.esolve_id}`;
|
|
2370
|
-
if (children != null) {
|
|
2371
|
-
this.children = children;
|
|
2372
|
-
}
|
|
2373
|
-
this.image_path = '/images/categories/';
|
|
2374
|
-
}
|
|
2375
|
-
else {
|
|
2376
|
-
this.id = `<<SUB>>${this.esolve_id}`;
|
|
2377
|
-
this.image_path = '/images/subcategories/';
|
|
2378
|
-
}
|
|
2379
|
-
if (seo_title.trim() === '') {
|
|
2380
|
-
seo_title = this.description;
|
|
2381
|
-
}
|
|
2382
|
-
this.seo_details = new EsolveSEOInfo(seo_title, seo_description, seo_keywords);
|
|
2383
|
-
}
|
|
2384
|
-
generateImagePath(image_size) {
|
|
2385
|
-
if (this.image_name !== '') {
|
|
2386
|
-
return `${this.image_path}${image_size}/${this.image_name}`;
|
|
2387
|
-
}
|
|
2388
|
-
return '';
|
|
2389
|
-
}
|
|
2390
|
-
get small_image_src() {
|
|
2391
|
-
return this.generateImagePath('small');
|
|
2392
|
-
}
|
|
2393
|
-
get thumbnail_image_src() {
|
|
2394
|
-
return this.generateImagePath('thumb');
|
|
2395
|
-
}
|
|
2396
|
-
get tiny_image_src() {
|
|
2397
|
-
return this.generateImagePath('tiny');
|
|
2755
|
+
class EsolveLinkedStockItem extends EsolveStockItemBase {
|
|
2756
|
+
constructor(record) {
|
|
2757
|
+
super(record);
|
|
2758
|
+
this.qty = 0;
|
|
2759
|
+
this.qty = +(record?.qty ?? 0);
|
|
2398
2760
|
}
|
|
2399
2761
|
}
|
|
2400
2762
|
|
|
2401
|
-
class
|
|
2763
|
+
class EsolveStockService {
|
|
2402
2764
|
constructor(config, http) {
|
|
2403
2765
|
this.config = config;
|
|
2404
2766
|
this.http = http;
|
|
2405
2767
|
}
|
|
2406
2768
|
/**
|
|
2407
|
-
* Retrieves the
|
|
2408
|
-
*/
|
|
2409
|
-
getCategoryTree() {
|
|
2410
|
-
return this.http
|
|
2411
|
-
.get(`${this.config.api_url}/get-tree.php`)
|
|
2412
|
-
.pipe(map((response) => {
|
|
2413
|
-
if (response.records === undefined) {
|
|
2414
|
-
throw response;
|
|
2415
|
-
}
|
|
2416
|
-
return this.processTree(response.records);
|
|
2417
|
-
}));
|
|
2418
|
-
}
|
|
2419
|
-
/**
|
|
2420
|
-
* Retrieve the details of a category tree item from the eSolve instance and
|
|
2421
|
-
* converts it to the correct format.
|
|
2422
|
-
*
|
|
2423
|
-
* @param options Filter options
|
|
2424
|
-
*/
|
|
2425
|
-
getCategoryTreeItem(options) {
|
|
2426
|
-
let type;
|
|
2427
|
-
let esolve_id;
|
|
2428
|
-
let sef_description;
|
|
2429
|
-
if (options.id) {
|
|
2430
|
-
const categoryIdentifier = this.processID(options.id);
|
|
2431
|
-
if (categoryIdentifier) {
|
|
2432
|
-
type = categoryIdentifier.type;
|
|
2433
|
-
esolve_id = categoryIdentifier.esolve_id;
|
|
2434
|
-
}
|
|
2435
|
-
}
|
|
2436
|
-
else if (options.type) {
|
|
2437
|
-
type = options.type;
|
|
2438
|
-
if (options.esolve_id) {
|
|
2439
|
-
esolve_id = options.esolve_id;
|
|
2440
|
-
}
|
|
2441
|
-
else if (options.sef_description) {
|
|
2442
|
-
sef_description = options.sef_description;
|
|
2443
|
-
}
|
|
2444
|
-
}
|
|
2445
|
-
if (type && (esolve_id || sef_description)) {
|
|
2446
|
-
let params = new HttpParams();
|
|
2447
|
-
params = params.set('type', type);
|
|
2448
|
-
if (esolve_id) {
|
|
2449
|
-
params = params.set('id', esolve_id);
|
|
2450
|
-
}
|
|
2451
|
-
if (sef_description) {
|
|
2452
|
-
params = params.set('sef_description', sef_description);
|
|
2453
|
-
}
|
|
2454
|
-
return this.http
|
|
2455
|
-
.get(`${this.config.api_url}/get-tree-item.php`, { params })
|
|
2456
|
-
.pipe(map((response) => {
|
|
2457
|
-
if ((response.records === undefined) ||
|
|
2458
|
-
(response.records.length <= 0)) {
|
|
2459
|
-
throw response;
|
|
2460
|
-
}
|
|
2461
|
-
return this.processTreeItem(response.records[0]);
|
|
2462
|
-
}));
|
|
2463
|
-
}
|
|
2464
|
-
return throwError('Invalid options');
|
|
2465
|
-
}
|
|
2466
|
-
/**
|
|
2467
|
-
* Processes the eSolve tree records and converts them into the correct format.
|
|
2769
|
+
* Retrieves the stock record from the eSolve instance using the code.
|
|
2468
2770
|
*
|
|
2469
|
-
* @param
|
|
2771
|
+
* @param code eSolve stock code
|
|
2470
2772
|
*/
|
|
2471
|
-
|
|
2472
|
-
const tree_items = [];
|
|
2473
|
-
if (tree_records) {
|
|
2474
|
-
for (const tree_record of tree_records) {
|
|
2475
|
-
let esolve_id = '';
|
|
2476
|
-
let parent_id = '';
|
|
2477
|
-
let children = [];
|
|
2478
|
-
if (tree_record.type === 'category') {
|
|
2479
|
-
children = this.processTree(tree_record.children);
|
|
2480
|
-
esolve_id = tree_record.menu_id;
|
|
2481
|
-
parent_id = tree_record.owner_menu_id;
|
|
2482
|
-
}
|
|
2483
|
-
else {
|
|
2484
|
-
esolve_id = tree_record.id;
|
|
2485
|
-
parent_id = tree_record.menu_id;
|
|
2486
|
-
}
|
|
2487
|
-
tree_items.push(new EsolveCategoryTreeItem(tree_record.type, esolve_id, parent_id, tree_record.description, tree_record.sef_description, tree_record.seo_description, tree_record.sort_priority, tree_record.active, tree_record.display_only, tree_record.image, tree_record.seo_page_title, tree_record.seo_keywords, tree_record.short_description, children));
|
|
2488
|
-
}
|
|
2489
|
-
}
|
|
2490
|
-
return tree_items;
|
|
2491
|
-
}
|
|
2492
|
-
processTreeItem(record) {
|
|
2493
|
-
return new EsolveCategoryTreeItem(record.type, record.id, record.parent_id, record.description, record.sef_description, record.short_description, record.sort_priority, record.active, record.display_only, '', record.seo_page_title, record.seo_keywords, record.seo_description);
|
|
2494
|
-
}
|
|
2495
|
-
processID(id) {
|
|
2496
|
-
let type;
|
|
2497
|
-
let esolve_id;
|
|
2498
|
-
const type_code_regex = /^\<\<(CAT|SUB)\>\>/g;
|
|
2499
|
-
const match_results = id.match(type_code_regex);
|
|
2500
|
-
if (match_results) {
|
|
2501
|
-
const type_code = match_results[0];
|
|
2502
|
-
type = (type_code === '<<CAT>>' ? 'category' : 'subcategory');
|
|
2503
|
-
esolve_id = id.replace(type_code_regex, '');
|
|
2504
|
-
return {
|
|
2505
|
-
type,
|
|
2506
|
-
esolve_id
|
|
2507
|
-
};
|
|
2508
|
-
}
|
|
2509
|
-
return null;
|
|
2510
|
-
}
|
|
2511
|
-
}
|
|
2512
|
-
EsolveCategoryTreeService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveCategoryTreeService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2513
|
-
EsolveCategoryTreeService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveCategoryTreeService, providedIn: 'root' });
|
|
2514
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveCategoryTreeService, decorators: [{
|
|
2515
|
-
type: Injectable,
|
|
2516
|
-
args: [{
|
|
2517
|
-
providedIn: 'root',
|
|
2518
|
-
}]
|
|
2519
|
-
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
2520
|
-
type: Inject,
|
|
2521
|
-
args: [ESOLVE_CONNECT_CONFIG]
|
|
2522
|
-
}] }, { type: i1$2.HttpClient }]; } });
|
|
2523
|
-
|
|
2524
|
-
class EsolveManufacturer {
|
|
2525
|
-
constructor(id, manufacturer, sef_manufacturer, title, article, sort_priority, is_active, featured, image_name, seo_title = '', seo_keywords = '', seo_description = '') {
|
|
2526
|
-
this.id = id;
|
|
2527
|
-
this.manufacturer = manufacturer;
|
|
2528
|
-
this.sef_manufacturer = sef_manufacturer;
|
|
2529
|
-
this.title = title;
|
|
2530
|
-
this.article = article;
|
|
2531
|
-
this.sort_priority = sort_priority;
|
|
2532
|
-
this.is_active = is_active;
|
|
2533
|
-
this.featured = featured;
|
|
2534
|
-
this.image_name = image_name;
|
|
2535
|
-
this.image_path = '/images/manufacturers/';
|
|
2536
|
-
if (this.title.trim() === '') {
|
|
2537
|
-
this.title = this.manufacturer;
|
|
2538
|
-
}
|
|
2539
|
-
if (seo_title.trim() === '') {
|
|
2540
|
-
seo_title = this.title;
|
|
2541
|
-
}
|
|
2542
|
-
this.seo_details = new EsolveSEOInfo(seo_title, seo_description, seo_keywords);
|
|
2543
|
-
}
|
|
2544
|
-
get small_image_src() {
|
|
2545
|
-
return this.generateImagePath('small');
|
|
2546
|
-
}
|
|
2547
|
-
get thumbnail_image_src() {
|
|
2548
|
-
return this.generateImagePath('thumb');
|
|
2549
|
-
}
|
|
2550
|
-
get tiny_image_src() {
|
|
2551
|
-
return this.generateImagePath('tiny');
|
|
2552
|
-
}
|
|
2553
|
-
generateImagePath(image_size) {
|
|
2554
|
-
if (this.image_name !== '') {
|
|
2555
|
-
return `${this.image_path}${image_size}/${this.image_name}`;
|
|
2556
|
-
}
|
|
2557
|
-
return '';
|
|
2558
|
-
}
|
|
2559
|
-
}
|
|
2560
|
-
|
|
2561
|
-
class EsolveManufacturersService {
|
|
2562
|
-
constructor(config, http) {
|
|
2563
|
-
this.config = config;
|
|
2564
|
-
this.http = http;
|
|
2565
|
-
}
|
|
2566
|
-
getManufacturer(id) {
|
|
2773
|
+
getStockItem(code) {
|
|
2567
2774
|
const params = new HttpParams({
|
|
2568
|
-
fromObject: {
|
|
2775
|
+
fromObject: {
|
|
2776
|
+
code
|
|
2777
|
+
}
|
|
2569
2778
|
});
|
|
2570
|
-
return this.
|
|
2779
|
+
return this.getStockRecords(params).pipe(map(response => {
|
|
2780
|
+
if ((response.records === undefined) || (response.records.length <= 0)) {
|
|
2781
|
+
throw response;
|
|
2782
|
+
}
|
|
2783
|
+
const stockRecord = response.records[0];
|
|
2784
|
+
return this.processStockItem(stockRecord);
|
|
2785
|
+
}));
|
|
2571
2786
|
}
|
|
2572
|
-
|
|
2787
|
+
/**
|
|
2788
|
+
* Retrieves the stock record from the eSolve instance using the SEF name.
|
|
2789
|
+
*
|
|
2790
|
+
* @param sef_name SEF name of the stock item
|
|
2791
|
+
*/
|
|
2792
|
+
getStockItemFromSEF(sef_name) {
|
|
2573
2793
|
const params = new HttpParams({
|
|
2574
|
-
fromObject: {
|
|
2794
|
+
fromObject: {
|
|
2795
|
+
sef_name
|
|
2796
|
+
}
|
|
2575
2797
|
});
|
|
2576
|
-
return this.
|
|
2798
|
+
return this.getStockRecords(params).pipe(map(response => {
|
|
2799
|
+
if ((response.records === undefined) || (response.records.length <= 0)) {
|
|
2800
|
+
throw response;
|
|
2801
|
+
}
|
|
2802
|
+
const stockRecord = response.records[0];
|
|
2803
|
+
return this.processStockItem(stockRecord);
|
|
2804
|
+
}));
|
|
2577
2805
|
}
|
|
2578
|
-
|
|
2806
|
+
/**
|
|
2807
|
+
* Retrieves list of stock from the eSolve instance using info provided
|
|
2808
|
+
*
|
|
2809
|
+
* @param options Stock filter options
|
|
2810
|
+
*/
|
|
2811
|
+
getStockItems(options) {
|
|
2579
2812
|
let params = new HttpParams();
|
|
2580
|
-
if (options
|
|
2581
|
-
params = params.set('
|
|
2813
|
+
if (options.page) {
|
|
2814
|
+
params = params.set('page', options.page);
|
|
2582
2815
|
}
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
|
|
2816
|
+
if (options.rows) {
|
|
2817
|
+
params = params.set('rows', options.rows);
|
|
2818
|
+
}
|
|
2819
|
+
if (options.search_phrase) {
|
|
2820
|
+
params = params.set('search_phrase', options.search_phrase);
|
|
2821
|
+
}
|
|
2822
|
+
if (options.display_only) {
|
|
2823
|
+
params = params.set('display_only', options.display_only);
|
|
2824
|
+
}
|
|
2825
|
+
if (options.is_active) {
|
|
2826
|
+
params = params.set('is_active', options.is_active);
|
|
2827
|
+
}
|
|
2828
|
+
if (options.category_id) {
|
|
2829
|
+
params = params.set('category_id', options.category_id);
|
|
2830
|
+
}
|
|
2831
|
+
if (options.subcategory_id) {
|
|
2832
|
+
params = params.set('subcategory_id', options.subcategory_id);
|
|
2833
|
+
}
|
|
2834
|
+
if (options.manufacturers_id) {
|
|
2835
|
+
params = params.set('manufacturers_id', options.manufacturers_id);
|
|
2836
|
+
}
|
|
2837
|
+
if (options.ranges_id) {
|
|
2838
|
+
params = params.set('ranges_id', options.ranges_id);
|
|
2839
|
+
}
|
|
2840
|
+
if (options.specials_id) {
|
|
2841
|
+
params = params.set('specials_id', options.specials_id);
|
|
2842
|
+
}
|
|
2843
|
+
if (options.tag_id_list) {
|
|
2844
|
+
if (options.tag_id_list.length > 0) {
|
|
2845
|
+
params = params.set('tag_id', options.tag_id_list.join(','));
|
|
2587
2846
|
}
|
|
2588
|
-
|
|
2589
|
-
|
|
2590
|
-
|
|
2847
|
+
}
|
|
2848
|
+
if (options.topic_id_list) {
|
|
2849
|
+
if (options.topic_id_list.length > 0) {
|
|
2850
|
+
params = params.set('topic_id', options.topic_id_list.join(','));
|
|
2851
|
+
}
|
|
2852
|
+
}
|
|
2853
|
+
return this.getStockRecords(params).pipe(map(response => {
|
|
2854
|
+
if ((response.records === undefined) || (response.records.length <= 0)) {
|
|
2855
|
+
throw response;
|
|
2856
|
+
}
|
|
2857
|
+
const stockItems = [];
|
|
2858
|
+
response.records.forEach(stockRecord => {
|
|
2859
|
+
stockItems.push(this.processStockItem(stockRecord));
|
|
2860
|
+
});
|
|
2861
|
+
return new EsolveStockItemList(stockItems, +response.additional_data.total_records, options.page ?? 0);
|
|
2591
2862
|
}));
|
|
2592
2863
|
}
|
|
2593
|
-
|
|
2594
|
-
|
|
2595
|
-
|
|
2596
|
-
|
|
2864
|
+
/**
|
|
2865
|
+
* Retrieve list of stock items linked to a stock item from the eSolve API
|
|
2866
|
+
*
|
|
2867
|
+
* @param code Stock item code
|
|
2868
|
+
*/
|
|
2869
|
+
getLinkedItems(code) {
|
|
2870
|
+
return this.http
|
|
2871
|
+
.get(`${this.config.api_url}/get-linked-items.php`, { params: { code } })
|
|
2872
|
+
.pipe(map((response) => {
|
|
2873
|
+
if ((response.records === undefined) || (response.records.length <= 0)) {
|
|
2874
|
+
throw response;
|
|
2875
|
+
}
|
|
2876
|
+
return this.processLinkedItems(response.records);
|
|
2597
2877
|
}));
|
|
2598
2878
|
}
|
|
2599
|
-
|
|
2879
|
+
/**
|
|
2880
|
+
* Retrieve list of stock items on a recipe from the eSolve API
|
|
2881
|
+
*
|
|
2882
|
+
* @param code Stock item code
|
|
2883
|
+
*/
|
|
2884
|
+
getRecipeItems(code) {
|
|
2600
2885
|
return this.http
|
|
2601
|
-
.get(`${this.config.api_url}/get-
|
|
2886
|
+
.get(`${this.config.api_url}/get-recipe-items.php`, { params: { code } })
|
|
2602
2887
|
.pipe(map((response) => {
|
|
2603
|
-
if ((response.records === undefined) ||
|
|
2604
|
-
(response.records.length <= 0)) {
|
|
2888
|
+
if ((response.records === undefined) || (response.records.length <= 0)) {
|
|
2605
2889
|
throw response;
|
|
2606
2890
|
}
|
|
2607
|
-
return response.records;
|
|
2891
|
+
return this.processRecipeItems(response.records);
|
|
2608
2892
|
}));
|
|
2609
2893
|
}
|
|
2610
|
-
|
|
2611
|
-
|
|
2894
|
+
/**
|
|
2895
|
+
* Processes the eSolve stock item record and converts it to an object.
|
|
2896
|
+
*
|
|
2897
|
+
* @param record eSolve stock item record
|
|
2898
|
+
*/
|
|
2899
|
+
processStockItem(record) {
|
|
2900
|
+
return new EsolveStockItem(record);
|
|
2901
|
+
}
|
|
2902
|
+
/**
|
|
2903
|
+
* Processes the linked eSolve stock item records and converts them to objects.
|
|
2904
|
+
*
|
|
2905
|
+
* @param records Linked eSolve stock item records
|
|
2906
|
+
*/
|
|
2907
|
+
processLinkedItems(records) {
|
|
2908
|
+
const items = [];
|
|
2909
|
+
if (records.length > 0) {
|
|
2910
|
+
for (const record of records) {
|
|
2911
|
+
items.push(new EsolveLinkedStockItem(record));
|
|
2912
|
+
}
|
|
2913
|
+
}
|
|
2914
|
+
return items;
|
|
2915
|
+
}
|
|
2916
|
+
/**
|
|
2917
|
+
* Processes the recipe eSolve stock item records and converts them to objects.
|
|
2918
|
+
*
|
|
2919
|
+
* @param records Recipe eSolve stock item records
|
|
2920
|
+
*/
|
|
2921
|
+
processRecipeItems(records) {
|
|
2922
|
+
const items = [];
|
|
2923
|
+
if (records.length > 0) {
|
|
2924
|
+
for (const record of records) {
|
|
2925
|
+
items.push(new EsolveRecipeStockItem(record));
|
|
2926
|
+
}
|
|
2927
|
+
}
|
|
2928
|
+
return items;
|
|
2929
|
+
}
|
|
2930
|
+
/**
|
|
2931
|
+
* Retrieves stock records from HTTP params.
|
|
2932
|
+
* @param params HTTP client parameters
|
|
2933
|
+
*/
|
|
2934
|
+
getStockRecords(params) {
|
|
2935
|
+
return this.http.get(`${this.config.api_url}/get-items.php`, { params });
|
|
2612
2936
|
}
|
|
2613
2937
|
}
|
|
2614
|
-
|
|
2615
|
-
|
|
2616
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type:
|
|
2938
|
+
EsolveStockService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveStockService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2939
|
+
EsolveStockService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveStockService, providedIn: 'root' });
|
|
2940
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveStockService, decorators: [{
|
|
2617
2941
|
type: Injectable,
|
|
2618
2942
|
args: [{
|
|
2619
2943
|
providedIn: 'root',
|
|
@@ -2623,6 +2947,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
2623
2947
|
args: [ESOLVE_CONNECT_CONFIG]
|
|
2624
2948
|
}] }, { type: i1$2.HttpClient }]; } });
|
|
2625
2949
|
|
|
2950
|
+
// Models
|
|
2951
|
+
|
|
2626
2952
|
class EsolveSpecialImage {
|
|
2627
2953
|
constructor(record) {
|
|
2628
2954
|
this.id = +record.id;
|
|
@@ -2666,181 +2992,81 @@ class EsolveSpecial {
|
|
|
2666
2992
|
this.discount_type = +record.discount_type;
|
|
2667
2993
|
this.special_type = record.special_type;
|
|
2668
2994
|
this.location_id = +record.location_id;
|
|
2669
|
-
this.active = !!+record.active;
|
|
2670
|
-
this.featured = !!+record.featured;
|
|
2671
|
-
this.assets = [];
|
|
2672
|
-
if (record.assets.length > 0) {
|
|
2673
|
-
for (const asset_record of record.assets) {
|
|
2674
|
-
this.assets.push(new EsolveLinkedAsset(asset_record));
|
|
2675
|
-
}
|
|
2676
|
-
}
|
|
2677
|
-
if (record.images &&
|
|
2678
|
-
((record.images.thumb &&
|
|
2679
|
-
record.images.thumb.length > 0) ||
|
|
2680
|
-
(record.images.banner &&
|
|
2681
|
-
record.images.banner.length > 0) ||
|
|
2682
|
-
(record.images.banner_mobile &&
|
|
2683
|
-
record.images.banner_mobile.length > 0)) &&
|
|
2684
|
-
record.image_container.trim() !== '') {
|
|
2685
|
-
this.images = new EsolveSpecialImageCollection(record.image_container, record.images);
|
|
2686
|
-
}
|
|
2687
|
-
if (record.seo_page_title.trim() === '') {
|
|
2688
|
-
record.seo_page_title = this.name;
|
|
2689
|
-
}
|
|
2690
|
-
this.seo_details = new EsolveSEOInfo(record.seo_page_title, record.seo_description, record.seo_keywords);
|
|
2691
|
-
}
|
|
2692
|
-
}
|
|
2693
|
-
|
|
2694
|
-
class EsolveSpecialsService {
|
|
2695
|
-
constructor(config, http) {
|
|
2696
|
-
this.config = config;
|
|
2697
|
-
this.http = http;
|
|
2698
|
-
}
|
|
2699
|
-
getSpecial(specials_id) {
|
|
2700
|
-
const params = new HttpParams({
|
|
2701
|
-
fromObject: { specials_id }
|
|
2702
|
-
});
|
|
2703
|
-
return this.getSpecialSingle(params);
|
|
2704
|
-
}
|
|
2705
|
-
getSpecialFromIdentifier(identifier) {
|
|
2706
|
-
const params = new HttpParams({
|
|
2707
|
-
fromObject: { identifier }
|
|
2708
|
-
});
|
|
2709
|
-
return this.getSpecialSingle(params);
|
|
2710
|
-
}
|
|
2711
|
-
getSpecials(options) {
|
|
2712
|
-
let params = new HttpParams();
|
|
2713
|
-
if (options?.featured_only) {
|
|
2714
|
-
params = params.set('featured_only', options.featured_only);
|
|
2715
|
-
}
|
|
2716
|
-
if (options?.image_container) {
|
|
2717
|
-
params = params.set('image_container', options.image_container);
|
|
2718
|
-
}
|
|
2719
|
-
if (options?.location_id) {
|
|
2720
|
-
params = params.set('location_id', options.location_id);
|
|
2721
|
-
}
|
|
2722
|
-
if (options?.special_type) {
|
|
2723
|
-
params = params.set('special_type', options.special_type);
|
|
2724
|
-
}
|
|
2725
|
-
return this.getSpecialRecords(params).pipe(map((records) => {
|
|
2726
|
-
const specials = [];
|
|
2727
|
-
for (const record of records) {
|
|
2728
|
-
specials.push(this.processSpecial(record));
|
|
2729
|
-
}
|
|
2730
|
-
return specials;
|
|
2731
|
-
}), catchError(() => {
|
|
2732
|
-
return of([]);
|
|
2733
|
-
}));
|
|
2734
|
-
}
|
|
2735
|
-
getSpecialSingle(params) {
|
|
2736
|
-
return this.getSpecialRecords(params).pipe(map((records) => {
|
|
2737
|
-
const record = records[0];
|
|
2738
|
-
return this.processSpecial(record);
|
|
2739
|
-
}));
|
|
2740
|
-
}
|
|
2741
|
-
getSpecialRecords(params) {
|
|
2742
|
-
return this.http
|
|
2743
|
-
.get(`${this.config.api_url}/get-specials.php`, { params })
|
|
2744
|
-
.pipe(map((response) => {
|
|
2745
|
-
if ((response.records === undefined) ||
|
|
2746
|
-
(response.records.length <= 0)) {
|
|
2747
|
-
throw response;
|
|
2748
|
-
}
|
|
2749
|
-
return response.records;
|
|
2750
|
-
}));
|
|
2751
|
-
}
|
|
2752
|
-
processSpecial(record) {
|
|
2753
|
-
return new EsolveSpecial(record);
|
|
2754
|
-
}
|
|
2755
|
-
}
|
|
2756
|
-
EsolveSpecialsService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveSpecialsService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2757
|
-
EsolveSpecialsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveSpecialsService, providedIn: 'root' });
|
|
2758
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveSpecialsService, decorators: [{
|
|
2759
|
-
type: Injectable,
|
|
2760
|
-
args: [{
|
|
2761
|
-
providedIn: 'root'
|
|
2762
|
-
}]
|
|
2763
|
-
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
2764
|
-
type: Inject,
|
|
2765
|
-
args: [ESOLVE_CONNECT_CONFIG]
|
|
2766
|
-
}] }, { type: i1$2.HttpClient }]; } });
|
|
2767
|
-
|
|
2768
|
-
class EsolveRange {
|
|
2769
|
-
constructor(id, range, sef_range, manufacturers_id, title, article, is_active, featured, sort_priority, image_name, seo_title = '', seo_keywords = '', seo_description = '') {
|
|
2770
|
-
this.id = id;
|
|
2771
|
-
this.range = range;
|
|
2772
|
-
this.sef_range = sef_range;
|
|
2773
|
-
this.manufacturers_id = manufacturers_id;
|
|
2774
|
-
this.title = title;
|
|
2775
|
-
this.article = article;
|
|
2776
|
-
this.is_active = is_active;
|
|
2777
|
-
this.featured = featured;
|
|
2778
|
-
this.sort_priority = sort_priority;
|
|
2779
|
-
this.image_name = image_name;
|
|
2780
|
-
this.image_path = '/images/ranges/';
|
|
2781
|
-
if (this.title.trim() === '') {
|
|
2782
|
-
this.title = this.range;
|
|
2995
|
+
this.active = !!+record.active;
|
|
2996
|
+
this.featured = !!+record.featured;
|
|
2997
|
+
this.assets = [];
|
|
2998
|
+
if (record.assets.length > 0) {
|
|
2999
|
+
for (const asset_record of record.assets) {
|
|
3000
|
+
this.assets.push(new EsolveLinkedAsset(asset_record));
|
|
3001
|
+
}
|
|
2783
3002
|
}
|
|
2784
|
-
if (
|
|
2785
|
-
|
|
3003
|
+
if (record.images &&
|
|
3004
|
+
((record.images.thumb &&
|
|
3005
|
+
record.images.thumb.length > 0) ||
|
|
3006
|
+
(record.images.banner &&
|
|
3007
|
+
record.images.banner.length > 0) ||
|
|
3008
|
+
(record.images.banner_mobile &&
|
|
3009
|
+
record.images.banner_mobile.length > 0)) &&
|
|
3010
|
+
record.image_container.trim() !== '') {
|
|
3011
|
+
this.images = new EsolveSpecialImageCollection(record.image_container, record.images);
|
|
2786
3012
|
}
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
get image_src() {
|
|
2790
|
-
return this.generateImagePath();
|
|
2791
|
-
}
|
|
2792
|
-
generateImagePath() {
|
|
2793
|
-
if (this.image_name !== '') {
|
|
2794
|
-
return `${this.image_path}${this.image_name}`;
|
|
3013
|
+
if (record.seo_page_title.trim() === '') {
|
|
3014
|
+
record.seo_page_title = this.name;
|
|
2795
3015
|
}
|
|
2796
|
-
|
|
3016
|
+
this.seo_details = new EsolveSeoInfo(record.seo_page_title, record.seo_description, record.seo_keywords);
|
|
2797
3017
|
}
|
|
2798
3018
|
}
|
|
2799
3019
|
|
|
2800
|
-
class
|
|
3020
|
+
class EsolveSpecialsService {
|
|
2801
3021
|
constructor(config, http) {
|
|
2802
3022
|
this.config = config;
|
|
2803
3023
|
this.http = http;
|
|
2804
3024
|
}
|
|
2805
|
-
|
|
3025
|
+
getSpecial(specials_id) {
|
|
2806
3026
|
const params = new HttpParams({
|
|
2807
|
-
fromObject: {
|
|
3027
|
+
fromObject: { specials_id }
|
|
2808
3028
|
});
|
|
2809
|
-
return this.
|
|
3029
|
+
return this.getSpecialSingle(params);
|
|
2810
3030
|
}
|
|
2811
|
-
|
|
3031
|
+
getSpecialFromIdentifier(identifier) {
|
|
2812
3032
|
const params = new HttpParams({
|
|
2813
|
-
fromObject: {
|
|
3033
|
+
fromObject: { identifier }
|
|
2814
3034
|
});
|
|
2815
|
-
return this.
|
|
3035
|
+
return this.getSpecialSingle(params);
|
|
2816
3036
|
}
|
|
2817
|
-
|
|
3037
|
+
getSpecials(options) {
|
|
2818
3038
|
let params = new HttpParams();
|
|
2819
3039
|
if (options?.featured_only) {
|
|
2820
3040
|
params = params.set('featured_only', options.featured_only);
|
|
2821
3041
|
}
|
|
2822
|
-
if (options?.
|
|
2823
|
-
params = params.set('
|
|
3042
|
+
if (options?.image_container) {
|
|
3043
|
+
params = params.set('image_container', options.image_container);
|
|
2824
3044
|
}
|
|
2825
|
-
|
|
2826
|
-
|
|
3045
|
+
if (options?.location_id) {
|
|
3046
|
+
params = params.set('location_id', options.location_id);
|
|
3047
|
+
}
|
|
3048
|
+
if (options?.special_type) {
|
|
3049
|
+
params = params.set('special_type', options.special_type);
|
|
3050
|
+
}
|
|
3051
|
+
return this.getSpecialRecords(params).pipe(map((records) => {
|
|
3052
|
+
const specials = [];
|
|
2827
3053
|
for (const record of records) {
|
|
2828
|
-
|
|
3054
|
+
specials.push(this.processSpecial(record));
|
|
2829
3055
|
}
|
|
2830
|
-
return
|
|
3056
|
+
return specials;
|
|
2831
3057
|
}), catchError(() => {
|
|
2832
3058
|
return of([]);
|
|
2833
3059
|
}));
|
|
2834
3060
|
}
|
|
2835
|
-
|
|
2836
|
-
return this.
|
|
3061
|
+
getSpecialSingle(params) {
|
|
3062
|
+
return this.getSpecialRecords(params).pipe(map((records) => {
|
|
2837
3063
|
const record = records[0];
|
|
2838
|
-
return this.
|
|
3064
|
+
return this.processSpecial(record);
|
|
2839
3065
|
}));
|
|
2840
3066
|
}
|
|
2841
|
-
|
|
3067
|
+
getSpecialRecords(params) {
|
|
2842
3068
|
return this.http
|
|
2843
|
-
.get(`${this.config.api_url}/get-
|
|
3069
|
+
.get(`${this.config.api_url}/get-specials.php`, { params })
|
|
2844
3070
|
.pipe(map((response) => {
|
|
2845
3071
|
if ((response.records === undefined) ||
|
|
2846
3072
|
(response.records.length <= 0)) {
|
|
@@ -2849,13 +3075,13 @@ class EsolveRangesService {
|
|
|
2849
3075
|
return response.records;
|
|
2850
3076
|
}));
|
|
2851
3077
|
}
|
|
2852
|
-
|
|
2853
|
-
return new
|
|
3078
|
+
processSpecial(record) {
|
|
3079
|
+
return new EsolveSpecial(record);
|
|
2854
3080
|
}
|
|
2855
3081
|
}
|
|
2856
|
-
|
|
2857
|
-
|
|
2858
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type:
|
|
3082
|
+
EsolveSpecialsService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveSpecialsService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3083
|
+
EsolveSpecialsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveSpecialsService, providedIn: 'root' });
|
|
3084
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveSpecialsService, decorators: [{
|
|
2859
3085
|
type: Injectable,
|
|
2860
3086
|
args: [{
|
|
2861
3087
|
providedIn: 'root'
|
|
@@ -2897,6 +3123,55 @@ class EsolveCartItem {
|
|
|
2897
3123
|
}
|
|
2898
3124
|
}
|
|
2899
3125
|
|
|
3126
|
+
class EsolveCartStockItem {
|
|
3127
|
+
constructor(code, name, sef_name, description, active, items_in_pack, delivery_category, image_name) {
|
|
3128
|
+
this.code = code;
|
|
3129
|
+
this.name = name;
|
|
3130
|
+
this.sef_name = sef_name;
|
|
3131
|
+
this.description = description;
|
|
3132
|
+
this.active = active;
|
|
3133
|
+
this.items_in_pack = items_in_pack;
|
|
3134
|
+
this.delivery_category = delivery_category;
|
|
3135
|
+
this.image_name = image_name;
|
|
3136
|
+
}
|
|
3137
|
+
/**
|
|
3138
|
+
* Path to tiny stock image
|
|
3139
|
+
*/
|
|
3140
|
+
get tiny_image_src() {
|
|
3141
|
+
return this.getImagePath('tiny');
|
|
3142
|
+
}
|
|
3143
|
+
/**
|
|
3144
|
+
* Path to thumbnail stock image
|
|
3145
|
+
*/
|
|
3146
|
+
get thumbnail_image_src() {
|
|
3147
|
+
return this.getImagePath('thumb');
|
|
3148
|
+
}
|
|
3149
|
+
/**
|
|
3150
|
+
* Path to small stock image
|
|
3151
|
+
*/
|
|
3152
|
+
get small_image_src() {
|
|
3153
|
+
return this.getImagePath('small');
|
|
3154
|
+
}
|
|
3155
|
+
/**
|
|
3156
|
+
* Path to big stock image
|
|
3157
|
+
*/
|
|
3158
|
+
get big_image_src() {
|
|
3159
|
+
return this.getImagePath('big');
|
|
3160
|
+
}
|
|
3161
|
+
/**
|
|
3162
|
+
* Path to original stock image
|
|
3163
|
+
*/
|
|
3164
|
+
get original_image_src() {
|
|
3165
|
+
return this.getImagePath('original');
|
|
3166
|
+
}
|
|
3167
|
+
getImagePath(image_size) {
|
|
3168
|
+
if (this.image_name !== '') {
|
|
3169
|
+
return `/images/stock/${image_size}/${this.image_name}`;
|
|
3170
|
+
}
|
|
3171
|
+
return '';
|
|
3172
|
+
}
|
|
3173
|
+
}
|
|
3174
|
+
|
|
2900
3175
|
/**
|
|
2901
3176
|
* Totals in cart
|
|
2902
3177
|
*/
|
|
@@ -2936,49 +3211,6 @@ class EsolveCartTotals {
|
|
|
2936
3211
|
}
|
|
2937
3212
|
}
|
|
2938
3213
|
|
|
2939
|
-
class EsolveCartStockItem {
|
|
2940
|
-
constructor(code, name, sef_name, description, active, items_in_pack, delivery_category, image_name) {
|
|
2941
|
-
this.code = code;
|
|
2942
|
-
this.name = name;
|
|
2943
|
-
this.sef_name = sef_name;
|
|
2944
|
-
this.description = description;
|
|
2945
|
-
this.active = active;
|
|
2946
|
-
this.items_in_pack = items_in_pack;
|
|
2947
|
-
this.delivery_category = delivery_category;
|
|
2948
|
-
this.image_name = image_name;
|
|
2949
|
-
}
|
|
2950
|
-
/**
|
|
2951
|
-
* Path to tiny stock image
|
|
2952
|
-
*/
|
|
2953
|
-
get tiny_image_src() {
|
|
2954
|
-
return '/images/' + (this.image_name ? 'stock/tiny/' + this.image_name : 'no_image.jpg');
|
|
2955
|
-
}
|
|
2956
|
-
/**
|
|
2957
|
-
* Path to thumbnail stock image
|
|
2958
|
-
*/
|
|
2959
|
-
get thumbnail_image_src() {
|
|
2960
|
-
return '/images/' + (this.image_name ? 'stock/thumb/' + this.image_name : 'no_image.jpg');
|
|
2961
|
-
}
|
|
2962
|
-
/**
|
|
2963
|
-
* Path to small stock image
|
|
2964
|
-
*/
|
|
2965
|
-
get small_image_src() {
|
|
2966
|
-
return '/images/' + (this.image_name ? 'stock/small/' + this.image_name : 'no_image.jpg');
|
|
2967
|
-
}
|
|
2968
|
-
/**
|
|
2969
|
-
* Path to big stock image
|
|
2970
|
-
*/
|
|
2971
|
-
get big_image_src() {
|
|
2972
|
-
return '/images/' + (this.image_name ? 'stock/big/' + this.image_name : 'no_image.jpg');
|
|
2973
|
-
}
|
|
2974
|
-
/**
|
|
2975
|
-
* Path to original stock image
|
|
2976
|
-
*/
|
|
2977
|
-
get original_image_src() {
|
|
2978
|
-
return 'images/' + (this.image_name ? 'stock/original/' + this.image_name : 'no_image.jpg');
|
|
2979
|
-
}
|
|
2980
|
-
}
|
|
2981
|
-
|
|
2982
3214
|
class EsolveCartService {
|
|
2983
3215
|
constructor(config, http, errorHandler, responseHandler) {
|
|
2984
3216
|
this.config = config;
|
|
@@ -3141,6 +3373,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
3141
3373
|
args: [ESOLVE_CONNECT_CONFIG]
|
|
3142
3374
|
}] }, { type: i1$2.HttpClient }, { type: EsolveErrorHandlerService }, { type: EsolveResponseHandlerService }]; } });
|
|
3143
3375
|
|
|
3376
|
+
class EsolveBankingDetails {
|
|
3377
|
+
constructor(bank_name, account_holder, account, account_type, swift_number, branch_code) {
|
|
3378
|
+
this.bank_name = bank_name;
|
|
3379
|
+
this.account_holder = account_holder;
|
|
3380
|
+
this.account = account;
|
|
3381
|
+
this.account_type = account_type;
|
|
3382
|
+
this.swift_number = swift_number;
|
|
3383
|
+
this.branch_code = branch_code;
|
|
3384
|
+
}
|
|
3385
|
+
}
|
|
3386
|
+
|
|
3144
3387
|
class EsolveVaultItemResult extends EsolveResponseResult {
|
|
3145
3388
|
constructor(response) {
|
|
3146
3389
|
super(response);
|
|
@@ -3234,16 +3477,6 @@ class EsolvePaymentMethod {
|
|
|
3234
3477
|
this.image_url = record.image_url;
|
|
3235
3478
|
this.banking_details = new EsolveBankingDetails(record.bank_name, record.account_holder, record.account, record.account_type, record.swift_number, record.branch_code);
|
|
3236
3479
|
}
|
|
3237
|
-
}
|
|
3238
|
-
class EsolveBankingDetails {
|
|
3239
|
-
constructor(bank_name, account_holder, account, account_type, swift_number, branch_code) {
|
|
3240
|
-
this.bank_name = bank_name;
|
|
3241
|
-
this.account_holder = account_holder;
|
|
3242
|
-
this.account = account;
|
|
3243
|
-
this.account_type = account_type;
|
|
3244
|
-
this.swift_number = swift_number;
|
|
3245
|
-
this.branch_code = branch_code;
|
|
3246
|
-
}
|
|
3247
3480
|
}
|
|
3248
3481
|
|
|
3249
3482
|
class EsolvePaymentService {
|
|
@@ -3300,8 +3533,8 @@ class EsolvePaymentService {
|
|
|
3300
3533
|
card_number: card_data.card_number,
|
|
3301
3534
|
card_name: card_data.name,
|
|
3302
3535
|
card_cvv: card_data.cvv,
|
|
3303
|
-
card_expiry: this.generateExpiry(card_data)
|
|
3304
|
-
}
|
|
3536
|
+
card_expiry: this.generateExpiry(card_data),
|
|
3537
|
+
},
|
|
3305
3538
|
};
|
|
3306
3539
|
return this.http
|
|
3307
3540
|
.post(`${this.config.api_url}/set-vault.php`, body, {
|
|
@@ -3347,7 +3580,7 @@ class EsolvePaymentService {
|
|
|
3347
3580
|
payment: {
|
|
3348
3581
|
cart_id: transaction_id,
|
|
3349
3582
|
payment_methods_id
|
|
3350
|
-
}
|
|
3583
|
+
},
|
|
3351
3584
|
};
|
|
3352
3585
|
if (typeof card === 'number') {
|
|
3353
3586
|
body.payment.user_vault_id = card;
|
|
@@ -3357,7 +3590,7 @@ class EsolvePaymentService {
|
|
|
3357
3590
|
card_number: card.card_number,
|
|
3358
3591
|
card_name: card.name,
|
|
3359
3592
|
card_cvv: card.cvv,
|
|
3360
|
-
card_expiry: this.generateExpiry(card)
|
|
3593
|
+
card_expiry: this.generateExpiry(card),
|
|
3361
3594
|
};
|
|
3362
3595
|
}
|
|
3363
3596
|
return this.http
|
|
@@ -3453,6 +3686,14 @@ class EsolveShippingMethod {
|
|
|
3453
3686
|
}
|
|
3454
3687
|
}
|
|
3455
3688
|
|
|
3689
|
+
class EsolveShippingTotals {
|
|
3690
|
+
constructor(total, vat, savings) {
|
|
3691
|
+
this.total = total;
|
|
3692
|
+
this.vat = vat;
|
|
3693
|
+
this.savings = savings;
|
|
3694
|
+
}
|
|
3695
|
+
}
|
|
3696
|
+
|
|
3456
3697
|
class EsolveShippingCost {
|
|
3457
3698
|
constructor(
|
|
3458
3699
|
// Shipping
|
|
@@ -3462,13 +3703,6 @@ class EsolveShippingCost {
|
|
|
3462
3703
|
this.shipping = new EsolveShippingTotals(shipping_total, shipping_vat, shipping_total_savings);
|
|
3463
3704
|
this.insurance = new EsolveShippingTotals(insurance_total, insurance_vat, insurance_total_savings);
|
|
3464
3705
|
}
|
|
3465
|
-
}
|
|
3466
|
-
class EsolveShippingTotals {
|
|
3467
|
-
constructor(total, vat, savings) {
|
|
3468
|
-
this.total = total;
|
|
3469
|
-
this.vat = vat;
|
|
3470
|
-
this.savings = savings;
|
|
3471
|
-
}
|
|
3472
3706
|
}
|
|
3473
3707
|
|
|
3474
3708
|
class EsolveShippingService {
|
|
@@ -3478,6 +3712,9 @@ class EsolveShippingService {
|
|
|
3478
3712
|
}
|
|
3479
3713
|
/**
|
|
3480
3714
|
* Retrieves a list of shipping methods
|
|
3715
|
+
*
|
|
3716
|
+
* @param options Filter options
|
|
3717
|
+
*
|
|
3481
3718
|
* @returns An `Observable` with an array of shipping methods
|
|
3482
3719
|
*/
|
|
3483
3720
|
getShippingMethods(options) {
|
|
@@ -3499,7 +3736,11 @@ class EsolveShippingService {
|
|
|
3499
3736
|
}
|
|
3500
3737
|
/**
|
|
3501
3738
|
* Retrieves the shipping costs
|
|
3502
|
-
*
|
|
3739
|
+
*
|
|
3740
|
+
* @param shipping_id
|
|
3741
|
+
* @param addresses_id
|
|
3742
|
+
* @param location_id
|
|
3743
|
+
*
|
|
3503
3744
|
* @returns An `Observable` with the shipping costs
|
|
3504
3745
|
*/
|
|
3505
3746
|
getShippingCost(shipping_id, addresses_id, location_id) {
|
|
@@ -3535,7 +3776,9 @@ class EsolveShippingService {
|
|
|
3535
3776
|
}
|
|
3536
3777
|
/**
|
|
3537
3778
|
* Processes the eSolve shipping method records.
|
|
3779
|
+
*
|
|
3538
3780
|
* @param records Records to process
|
|
3781
|
+
*
|
|
3539
3782
|
* @returns An array of processed shipping methods
|
|
3540
3783
|
*/
|
|
3541
3784
|
processShippingMethods(records) {
|
|
@@ -3549,8 +3792,10 @@ class EsolveShippingService {
|
|
|
3549
3792
|
return shipping_methods;
|
|
3550
3793
|
}
|
|
3551
3794
|
/**
|
|
3552
|
-
* Processes the eSolve shipping costs record
|
|
3795
|
+
* Processes the eSolve shipping costs record.+
|
|
3796
|
+
*
|
|
3553
3797
|
* @param record Data to process
|
|
3798
|
+
*
|
|
3554
3799
|
* @returns Processed shipping costs
|
|
3555
3800
|
*/
|
|
3556
3801
|
processShippingCost(record) {
|
|
@@ -3570,45 +3815,38 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
3570
3815
|
args: [ESOLVE_CONNECT_CONFIG]
|
|
3571
3816
|
}] }, { type: i1$2.HttpClient }]; } });
|
|
3572
3817
|
|
|
3573
|
-
class
|
|
3574
|
-
constructor(
|
|
3818
|
+
class EsolveEnquiryResult extends EsolveResponseResult {
|
|
3819
|
+
constructor(response) {
|
|
3820
|
+
super(response);
|
|
3821
|
+
this.id = 0;
|
|
3822
|
+
this.id = +response.esolve_id;
|
|
3823
|
+
}
|
|
3824
|
+
}
|
|
3825
|
+
|
|
3826
|
+
class EsolveEnquiryService {
|
|
3827
|
+
constructor(config, http, errorHandler, responseHandler) {
|
|
3575
3828
|
this.config = config;
|
|
3576
3829
|
this.http = http;
|
|
3830
|
+
this.errorHandler = errorHandler;
|
|
3831
|
+
this.responseHandler = responseHandler;
|
|
3577
3832
|
}
|
|
3578
|
-
|
|
3579
|
-
|
|
3580
|
-
|
|
3581
|
-
|
|
3582
|
-
*/
|
|
3583
|
-
getStockLocations() {
|
|
3833
|
+
send(form_data) {
|
|
3834
|
+
if (!form_data.has('email')) {
|
|
3835
|
+
return this.errorHandler.emitError('email_required', 'Email is required');
|
|
3836
|
+
}
|
|
3584
3837
|
return this.http
|
|
3585
|
-
.
|
|
3586
|
-
|
|
3587
|
-
|
|
3588
|
-
|
|
3589
|
-
|
|
3590
|
-
return this.
|
|
3838
|
+
.post(`${this.config.api_url}/set-enquiry.php`, form_data, {
|
|
3839
|
+
responseType: 'json',
|
|
3840
|
+
observe: 'body',
|
|
3841
|
+
})
|
|
3842
|
+
.pipe(map((http_response) => this.responseHandler.validateSingleHttpResponse(http_response, (response) => new EsolveEnquiryResult(response))), catchError((errorRes) => {
|
|
3843
|
+
return this.errorHandler.handleHttpPostError('set-enquiry', errorRes);
|
|
3591
3844
|
}));
|
|
3592
3845
|
}
|
|
3593
|
-
/**
|
|
3594
|
-
* Processes the eSolve stock location records.
|
|
3595
|
-
*
|
|
3596
|
-
* @param records Records to process
|
|
3597
|
-
* @returns An array of processed stock location records
|
|
3598
|
-
*/
|
|
3599
|
-
processStockLocations(records) {
|
|
3600
|
-
const stock_locations = [];
|
|
3601
|
-
if (records) {
|
|
3602
|
-
for (const record of records) {
|
|
3603
|
-
stock_locations.push(new EsolveStockLocation(record));
|
|
3604
|
-
}
|
|
3605
|
-
}
|
|
3606
|
-
return stock_locations;
|
|
3607
|
-
}
|
|
3608
3846
|
}
|
|
3609
|
-
|
|
3610
|
-
|
|
3611
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type:
|
|
3847
|
+
EsolveEnquiryService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveEnquiryService, deps: [{ token: ESOLVE_CONNECT_CONFIG }, { token: i1$2.HttpClient }, { token: EsolveErrorHandlerService }, { token: EsolveResponseHandlerService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3848
|
+
EsolveEnquiryService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveEnquiryService, providedIn: 'root' });
|
|
3849
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EsolveEnquiryService, decorators: [{
|
|
3612
3850
|
type: Injectable,
|
|
3613
3851
|
args: [{
|
|
3614
3852
|
providedIn: 'root',
|
|
@@ -3616,7 +3854,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
3616
3854
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
3617
3855
|
type: Inject,
|
|
3618
3856
|
args: [ESOLVE_CONNECT_CONFIG]
|
|
3619
|
-
}] }, { type: i1$2.HttpClient }]; } });
|
|
3857
|
+
}] }, { type: i1$2.HttpClient }, { type: EsolveErrorHandlerService }, { type: EsolveResponseHandlerService }]; } });
|
|
3620
3858
|
|
|
3621
3859
|
/*
|
|
3622
3860
|
* Public API Surface of ng-esolve-connect
|
|
@@ -3626,5 +3864,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
3626
3864
|
* Generated bundle index. Do not edit.
|
|
3627
3865
|
*/
|
|
3628
3866
|
|
|
3629
|
-
export { EsolveAccountService, EsolveAddress, EsolveAddressResult, EsolveAuthService, EsolveBankingDetails, EsolveBanner, EsolveBannerImage, EsolveBannerImageHotspot, EsolveBannerService, EsolveCartItem, EsolveCartService, EsolveCartTotals, EsolveCategoryTreeItem, EsolveCategoryTreeService, EsolveChangePasswordResult, EsolveCheckoutResult, EsolveCookieService, EsolveErrorHandlerService, EsolveGeocodeAddressResult, EsolveGeocodeCoordsResult, EsolveGeocodeResult, EsolveGeocoderService, EsolveHeading, EsolveHttpError, EsolveLinkedAsset, EsolveList, EsolveLocationsService, EsolveManufacturer, EsolveManufacturersService, EsolveMediaArticle, EsolveMediaService, EsolveMenuItem, EsolveMenuService, EsolveNewsArticle, EsolveNewsArticleAuthor, EsolveNewsArticleList, EsolveNewsGroup, EsolveNewsService, EsolvePaymentMethod, EsolvePaymentResult, EsolvePaymentService, EsolveRange, EsolveRangesService, EsolveRegistrationResult, EsolveResetPasswordResult, EsolveResponseHandlerService, EsolveResponseResult, EsolveResult,
|
|
3867
|
+
export { EsolveAccountService, EsolveAddress, EsolveAddressResult, EsolveAuthService, EsolveBankingDetails, EsolveBanner, EsolveBannerImage, EsolveBannerImageHotspot, EsolveBannerService, EsolveCartItem, EsolveCartService, EsolveCartStockItem, EsolveCartTotals, EsolveCategoryTreeItem, EsolveCategoryTreeService, EsolveChangePasswordResult, EsolveCheckoutResult, EsolveColour, EsolveCookieService, EsolveEnquiryResult, EsolveEnquiryService, EsolveErrorHandlerService, EsolveGeocodeAddressResult, EsolveGeocodeCoordsResult, EsolveGeocodeResult, EsolveGeocoderService, EsolveHeading, EsolveHttpError, EsolveLinkedAsset, EsolveLinkedStockItem, EsolveList, EsolveLocation, EsolveLocationAddress, EsolveLocationContactInfo, EsolveLocationPOBoxAddress, EsolveLocationTradingDay, EsolveLocationTradingTimes, EsolveLocationsService, EsolveManufacturer, EsolveManufacturersService, EsolveMediaArticle, EsolveMediaService, EsolveMenuItem, EsolveMenuService, EsolveNewsArticle, EsolveNewsArticleAuthor, EsolveNewsArticleList, EsolveNewsGroup, EsolveNewsService, EsolvePaymentMethod, EsolvePaymentResult, EsolvePaymentService, EsolveRange, EsolveRangesService, EsolveRecipeStockItem, EsolveRegistrationResult, EsolveResetPasswordResult, EsolveResponseHandlerService, EsolveResponseResult, EsolveResult, EsolveSeoInfo, EsolveSeoService, EsolveSession, EsolveSessionService, EsolveShippingCost, EsolveShippingMethod, EsolveShippingService, EsolveShippingTotals, EsolveSpecial, EsolveSpecialImage, EsolveSpecialImageCollection, EsolveSpecialsService, EsolveStockBadge, EsolveStockGroup, EsolveStockGroupItem, EsolveStockItem, EsolveStockItemBase, EsolveStockItemList, EsolveStockPrice, EsolveStockService, EsolveTag, EsolveTopic, EsolveTopicService, EsolveTransaction, EsolveTransactionAddress, EsolveTransactionClient, EsolveTransactionItem, EsolveTransactionItemPrice, EsolveTransactionList, EsolveTransactionLocation, EsolveTransactionPaymentMethod, EsolveTransactionShippingMethod, EsolveTransactionUser, EsolveUserAccount, EsolveUserAccountBusiness, EsolveUserAccountContact, EsolveUserAccountResult, EsolveVaultItem, EsolveVaultItemResult, NgEsolveConnectModule };
|
|
3630
3868
|
//# sourceMappingURL=esolve-ng-esolve-connect.mjs.map
|