ordering-ui-admin-external 1.13.3 → 1.14.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/_bundles/{ordering-ui-admin.a97f0d1801ec4a89a98e.js → ordering-ui-admin.1a09d41a4e6cd3d1e1cf.js} +2 -2
- package/_modules/components/BusinessIntelligence/BusinessReviewList/index.js +2 -1
- package/_modules/components/BusinessIntelligence/InvoiceBusinessManager/styles.js +1 -1
- package/_modules/components/BusinessIntelligence/InvoiceDriverManager/styles.js +1 -1
- package/_modules/components/BusinessIntelligence/InvoiceManager/index.js +2 -1
- package/_modules/components/BusinessIntelligence/UsersReviewList/index.js +6 -3
- package/_modules/components/CartRecovery/OpenCartsDetail/index.js +15 -1
- package/_modules/components/CartRecovery/OpenCartsDetail/styles.js +1 -1
- package/_modules/components/CartRecovery/RecoveryActionDetail/index.js +18 -1
- package/_modules/components/CartRecovery/RecoveryActionDetail/styles.js +4 -4
- package/_modules/components/CartRecovery/RecoveryActionList/styles.js +1 -3
- package/_modules/components/Delivery/DeliveryUsersListing/index.js +2 -1
- package/_modules/components/Delivery/DriversCompaniesList/styles.js +1 -1
- package/_modules/components/Delivery/DriversCompanyDetailsForm/index.js +21 -2
- package/_modules/components/Delivery/DriversCompanyDetailsForm/styles.js +8 -6
- package/_modules/components/Delivery/DriversGroupDetails/index.js +20 -2
- package/_modules/components/Delivery/DriversGroupDetails/styles.js +6 -4
- package/_modules/components/Delivery/DriversGroupsList/index.js +5 -5
- package/_modules/components/Delivery/DriversGroupsList/styles.js +1 -1
- package/_modules/components/Delivery/UserAddForm/index.js +1 -1
- package/_modules/components/Delivery/UserDetails/index.js +20 -2
- package/_modules/components/Delivery/UserDetails/styles.js +6 -4
- package/_modules/components/Delivery/UserDetailsLateralBar/styles.js +1 -1
- package/_modules/components/Delivery/UserProfileForm/index.js +1 -1
- package/_modules/components/Delivery/UsersList/styles.js +1 -1
- package/_modules/components/Login/LoginForm/index.js +49 -7
- package/_modules/components/Login/LoginForm/styles.js +18 -14
- package/_modules/components/Loyalty/GiftCardDetail/index.js +285 -0
- package/_modules/components/Loyalty/LoyaltyLevelDetail/index.js +1 -1
- package/_modules/components/Loyalty/PointsWalletBusinessList/index.js +1 -1
- package/_modules/components/Loyalty/PointsWalletBusinessList/styles.js +3 -3
- package/_modules/components/Loyalty/PointsWalletLevels/styles.js +1 -3
- package/_modules/components/Loyalty/RewardsPrograms/index.js +45 -28
- package/_modules/components/Loyalty/RewardsPrograms/styles.js +18 -3
- package/_modules/components/Loyalty/Wallet/index.js +109 -0
- package/_modules/components/Loyalty/{PointsWallet → Wallet}/styles.js +15 -9
- package/_modules/components/Loyalty/index.js +7 -7
- package/_modules/components/Marketing/BannerDetails/styles.js +1 -1
- package/_modules/components/Marketing/BannerImageDetails/index.js +1 -1
- package/_modules/components/Marketing/CampaignDetail/index.js +20 -1
- package/_modules/components/Marketing/CampaignDetail/styles.js +4 -4
- package/_modules/components/Marketing/CampaignList/styles.js +1 -3
- package/_modules/components/Marketing/EnterprisePromotionDetails/index.js +17 -2
- package/_modules/components/Marketing/EnterprisePromotionDetails/styles.js +7 -5
- package/_modules/components/Marketing/EnterprisePromotionGeneralDetails/index.js +1 -1
- package/_modules/components/Marketing/EnterprisePromotionList/styles.js +1 -3
- package/_modules/components/Marketing/EnterprisePromotionRules/index.js +1 -0
- package/_modules/components/Marketing/PageBanner/index.js +21 -7
- package/_modules/components/Marketing/PageBanner/styles.js +26 -24
- package/_modules/components/MyProducts/AdvancedSettings/ImageBox.js +151 -0
- package/_modules/components/MyProducts/OrderingWebsite/index.js +1 -1
- package/_modules/components/OrderingProducts/OrderingProductDetails/index.js +20 -2
- package/_modules/components/OrderingProducts/OrderingProductDetails/styles.js +15 -13
- package/_modules/components/OrderingProducts/OrderingProductsListing/styles.js +1 -3
- package/_modules/components/OrderingProducts/SiteTheme/ThemeImage.js +1 -1
- package/_modules/components/Orders/Messages/index.js +10 -2
- package/_modules/components/Orders/Messages/styles.js +64 -62
- package/_modules/components/Orders/OrderDashboardSLASetting/index.js +0 -1
- package/_modules/components/Orders/OrderDetailsHeader/index.js +30 -3
- package/_modules/components/Orders/OrdersFilterGroup/index.js +6 -10
- package/_modules/components/Orders/OrdersLateralBar/index.js +22 -5
- package/_modules/components/Orders/OrdersLateralBar/styles.js +2 -2
- package/_modules/components/Settings/ApiKeysList/styles.js +10 -7
- package/_modules/components/Settings/Cms/styles.js +1 -1
- package/_modules/components/Settings/CountriesList/index.js +5 -4
- package/_modules/components/Settings/CountriesList/styles.js +1 -1
- package/_modules/components/Settings/Deliverect/index.js +15 -1
- package/_modules/components/Settings/DoordashConnect/index.js +15 -1
- package/_modules/components/Settings/DropdownOptionList/index.js +2 -1
- package/_modules/components/Settings/DropdownOptionList/styles.js +1 -1
- package/_modules/components/Settings/IntegrationListing/index.js +6 -3
- package/_modules/components/Settings/ItsaCheckmate/index.js +15 -1
- package/_modules/components/Settings/LalamoveConnect/index.js +15 -1
- package/_modules/components/Settings/LanguageTransTable/styles.js +1 -1
- package/_modules/components/Settings/PickerExpress/index.js +15 -1
- package/_modules/components/Settings/PlaceListing/index.js +2 -1
- package/_modules/components/Settings/PlaceListing/styles.js +1 -1
- package/_modules/components/Settings/PluginList/styles.js +20 -17
- package/_modules/components/Settings/Settings/index.js +2 -1
- package/_modules/components/Settings/SettingsDetail/index.js +15 -1
- package/_modules/components/Settings/SettingsDetail/styles.js +13 -11
- package/_modules/components/Settings/SettingsImage/index.js +1 -1
- package/_modules/components/Settings/SitesAuthSettings/index.js +20 -1
- package/_modules/components/Settings/SitesAuthSettings/styles.js +10 -6
- package/_modules/components/Settings/WebhookList/styles.js +14 -11
- package/_modules/components/Shared/Modal/index.js +5 -3
- package/_modules/components/Shared/ProtectedRoute/index.js +6 -1
- package/_modules/components/Shared/SideBar/index.js +22 -3
- package/_modules/components/Shared/SideBar/styles.js +10 -8
- package/_modules/components/SidebarMenu/index.js +16 -18
- package/_modules/components/Stores/AddBusinessForm/index.js +1 -1
- package/_modules/components/Stores/BusinessAdd/Images/index.js +1 -1
- package/_modules/components/Stores/BusinessAdd/Photos/index.js +1 -1
- package/_modules/components/Stores/BusinessAddStore/index.js +1 -2
- package/_modules/components/Stores/BusinessBrandGENDetail/index.js +8 -3
- package/_modules/components/Stores/BusinessBrandListing/index.js +17 -2
- package/_modules/components/Stores/BusinessBrandListing/styles.js +35 -33
- package/_modules/components/Stores/BusinessDeliveryZoneInformation/index.js +1 -1
- package/_modules/components/Stores/BusinessDetails/index.js +6 -1
- package/_modules/components/Stores/BusinessFilterGroup/index.js +110 -0
- package/_modules/components/Stores/BusinessFilterGroup/styles.js +37 -0
- package/_modules/components/Stores/BusinessInformation/index.js +1 -1
- package/_modules/components/Stores/BusinessOrderingChannels/index.js +1 -1
- package/_modules/components/Stores/BusinessProductAddForm/index.js +5 -5
- package/_modules/components/Stores/BusinessProductList/index.js +2 -1
- package/_modules/components/Stores/BusinessProductList/styles.js +1 -3
- package/_modules/components/Stores/BusinessProductsCategories/styles.js +2 -4
- package/_modules/components/Stores/BusinessProductsCategoyDetails/index.js +22 -4
- package/_modules/components/Stores/BusinessProductsCategoyDetails/styles.js +1 -1
- package/_modules/components/Stores/BusinessProductsCategoyInfo/index.js +11 -23
- package/_modules/components/Stores/BusinessProductsListing/index.js +3 -2
- package/_modules/components/Stores/BusinessPromotionList/styles.js +1 -1
- package/_modules/components/Stores/BusinessSalesChannel/index.js +142 -0
- package/_modules/components/Stores/BusinessSalesChannel/styles.js +26 -0
- package/_modules/components/Stores/BusinessSalesFacebook/FacebookPost.js +31 -0
- package/_modules/components/Stores/BusinessSalesFacebook/FacebookProfile.js +45 -0
- package/_modules/components/Stores/BusinessSalesFacebook/index.js +77 -0
- package/_modules/components/Stores/BusinessSalesFacebook/styles.js +58 -0
- package/_modules/components/Stores/BusinessSalesGoogle/index.js +85 -0
- package/_modules/components/Stores/BusinessSalesGoogle/styles.js +44 -0
- package/_modules/components/Stores/BusinessSalesInstagram/AdvancedInstagram.js +58 -0
- package/_modules/components/Stores/BusinessSalesInstagram/GeneralInstagram.js +51 -0
- package/_modules/components/{Loyalty/PointsWallet → Stores/BusinessSalesInstagram}/index.js +62 -44
- package/_modules/components/Stores/BusinessSalesInstagram/styles.js +63 -0
- package/_modules/components/Stores/BusinessSalesTiktok/index.js +100 -0
- package/_modules/components/Stores/BusinessSalesTiktok/styles.js +37 -0
- package/_modules/components/Stores/BusinessServiceProfessionals/index.js +1 -0
- package/_modules/components/Stores/BusinessSummary/index.js +33 -6
- package/_modules/components/Stores/BusinessTypeDetail/index.js +1 -1
- package/_modules/components/Stores/BusinessesList/styles.js +1 -1
- package/_modules/components/Stores/BusinessesListing/index.js +12 -6
- package/_modules/components/Stores/BusinessesListingHeader/index.js +33 -3
- package/_modules/components/Stores/BusinessesListingHeader/styles.js +5 -2
- package/_modules/components/Stores/ImportersButton/index.js +2 -1
- package/_modules/components/Stores/PaymentOption/index.js +4 -10
- package/_modules/components/Stores/PaymentOptionMethods/index.js +47 -24
- package/_modules/components/Stores/PaymentOptionPaypal/index.js +47 -24
- package/_modules/components/Stores/PaymentOptionStripeDirect/index.js +47 -24
- package/_modules/components/Stores/PaymethodOptionStripeConnect/index.js +50 -25
- package/_modules/components/Stores/PaymethodOptionStripeRedirect/index.js +47 -24
- package/_modules/components/Stores/ProductDetails/index.js +2 -1
- package/_modules/components/Stores/ProductDetailsAdvanced/index.js +30 -11
- package/_modules/components/Stores/ProductDetailsAdvanced/styles.js +10 -7
- package/_modules/components/Stores/ProductDetatilsInformation/index.js +10 -34
- package/_modules/components/Stores/ProductExtraOptionDetails/index.js +1 -1
- package/_modules/components/Stores/ProductExtraOptions/index.js +1 -1
- package/_modules/components/Stores/ProductExtraSuboption/index.js +1 -1
- package/_modules/components/Stores/ProductGallery/index.js +1 -1
- package/_modules/components/Stores/ProductSummary/index.js +23 -2
- package/_modules/components/Stores/ProductTagDetails/index.js +1 -1
- package/_modules/components/Stores/SeoOptions/index.js +14 -16
- package/_modules/components/Stores/SeoOptions/styles.js +3 -3
- package/_modules/components/Stores/ServiceDetail/index.js +1 -1
- package/_modules/components/Stores/WizardBusiness/index.js +2 -1
- package/_modules/components/Stores/index.js +7 -0
- package/_modules/components/Users/CustomerDetails/index.js +24 -2
- package/_modules/components/Users/CustomerDetails/styles.js +16 -19
- package/_modules/components/Users/CustomersListing/index.js +39 -4
- package/_modules/components/Users/CustomersListing/styles.js +1 -1
- package/_modules/components/Users/OccupationSelector/index.js +1 -1
- package/_modules/components/Users/ProfessionalDetail/index.js +19 -3
- package/_modules/components/Users/ProfessionalDetail/styles.js +11 -9
- package/_modules/components/Users/ProfessionalList/styles.js +1 -1
- package/_modules/components/Users/ProfessionalListing/index.js +8 -3
- package/_modules/components/Users/UserAddForm/index.js +1 -1
- package/_modules/components/Users/UserDetails/index.js +27 -10
- package/_modules/components/Users/UserDetails/styles.js +20 -13
- package/_modules/components/Users/UserDetailsLateralBar/styles.js +1 -1
- package/_modules/components/Users/UserFilterGroup/index.js +307 -0
- package/_modules/components/Users/UserFilterGroup/styles.js +37 -0
- package/_modules/components/Users/UserProfileForm/index.js +1 -1
- package/_modules/components/Users/UsersExportCSV/index.js +33 -1
- package/_modules/components/Users/UsersList/index.js +5 -2
- package/_modules/components/Users/UsersList/styles.js +20 -5
- package/_modules/components/Users/UsersListing/index.js +9 -3
- package/_modules/components/Users/UsersListingHeader/index.js +39 -4
- package/_modules/components/Users/UsersListingHeader/styles.js +1 -1
- package/_modules/components/Users/index.js +7 -0
- package/_modules/config/constants.js +281 -41
- package/_modules/index.js +6 -6
- package/index-template.js +72 -0
- package/package.json +2 -2
- package/src/components/BusinessIntelligence/BusinessReviewList/index.js +1 -0
- package/src/components/BusinessIntelligence/InvoiceBusinessManager/styles.js +2 -2
- package/src/components/BusinessIntelligence/InvoiceDriverManager/styles.js +2 -2
- package/src/components/BusinessIntelligence/InvoiceManager/index.js +1 -0
- package/src/components/BusinessIntelligence/UsersReviewList/index.js +5 -2
- package/src/components/CartRecovery/OpenCartsDetail/index.js +17 -1
- package/src/components/CartRecovery/OpenCartsDetail/styles.js +3 -1
- package/src/components/CartRecovery/RecoveryActionDetail/index.js +24 -6
- package/src/components/CartRecovery/RecoveryActionDetail/styles.js +2 -3
- package/src/components/CartRecovery/RecoveryActionList/styles.js +1 -5
- package/src/components/Delivery/DeliveryUsersListing/index.js +1 -0
- package/src/components/Delivery/DriversCompaniesList/styles.js +1 -1
- package/src/components/Delivery/DriversCompanyDetailsForm/index.js +38 -15
- package/src/components/Delivery/DriversCompanyDetailsForm/styles.js +9 -5
- package/src/components/Delivery/DriversGroupDetails/index.js +48 -18
- package/src/components/Delivery/DriversGroupDetails/styles.js +5 -1
- package/src/components/Delivery/DriversGroupsList/index.js +8 -6
- package/src/components/Delivery/DriversGroupsList/styles.js +1 -1
- package/src/components/Delivery/UserAddForm/index.js +1 -1
- package/src/components/Delivery/UserDetails/index.js +43 -21
- package/src/components/Delivery/UserDetails/styles.js +8 -2
- package/src/components/Delivery/UserDetailsLateralBar/styles.js +0 -1
- package/src/components/Delivery/UserProfileForm/index.js +1 -1
- package/src/components/Delivery/UsersList/styles.js +1 -1
- package/src/components/Login/LoginForm/index.js +92 -32
- package/src/components/Login/LoginForm/styles.js +16 -0
- package/src/components/Loyalty/GiftCardDetail/index.js +287 -0
- package/src/components/Loyalty/LoyaltyLevelDetail/index.js +1 -1
- package/src/components/Loyalty/PointsWalletBusinessList/index.js +1 -1
- package/src/components/Loyalty/PointsWalletBusinessList/styles.js +9 -1
- package/src/components/Loyalty/PointsWalletLevels/styles.js +1 -6
- package/src/components/Loyalty/RewardsPrograms/index.js +63 -36
- package/src/components/Loyalty/RewardsPrograms/styles.js +57 -0
- package/src/components/Loyalty/Wallet/index.js +115 -0
- package/src/components/Loyalty/{PointsWallet → Wallet}/styles.js +17 -0
- package/src/components/Loyalty/index.js +2 -2
- package/src/components/Marketing/BannerDetails/styles.js +1 -0
- package/src/components/Marketing/BannerImageDetails/index.js +1 -1
- package/src/components/Marketing/CampaignDetail/index.js +25 -5
- package/src/components/Marketing/CampaignDetail/styles.js +2 -4
- package/src/components/Marketing/CampaignList/styles.js +1 -5
- package/src/components/Marketing/EnterprisePromotionDetails/index.js +35 -17
- package/src/components/Marketing/EnterprisePromotionDetails/styles.js +7 -3
- package/src/components/Marketing/EnterprisePromotionGeneralDetails/index.js +1 -1
- package/src/components/Marketing/EnterprisePromotionList/styles.js +1 -4
- package/src/components/Marketing/EnterprisePromotionRules/index.js +1 -0
- package/src/components/Marketing/PageBanner/index.js +28 -10
- package/src/components/Marketing/PageBanner/styles.js +15 -8
- package/src/components/MyProducts/AdvancedSettings/ImageBox.js +112 -0
- package/src/components/MyProducts/OrderingWebsite/index.js +1 -1
- package/src/components/OrderingProducts/OrderingProductDetails/index.js +34 -12
- package/src/components/OrderingProducts/OrderingProductDetails/styles.js +8 -3
- package/src/components/OrderingProducts/OrderingProductsListing/styles.js +1 -5
- package/src/components/OrderingProducts/SiteTheme/ThemeImage.js +1 -1
- package/src/components/Orders/Messages/index.js +104 -84
- package/src/components/Orders/Messages/styles.js +20 -0
- package/src/components/Orders/OrderDashboardSLASetting/index.js +0 -1
- package/src/components/Orders/OrderDetailsHeader/index.js +30 -3
- package/src/components/Orders/OrdersFilterGroup/index.js +6 -6
- package/src/components/Orders/OrdersLateralBar/index.js +20 -2
- package/src/components/Orders/OrdersLateralBar/styles.js +3 -1
- package/src/components/Settings/ApiKeysList/styles.js +8 -0
- package/src/components/Settings/Cms/styles.js +1 -1
- package/src/components/Settings/CountriesList/index.js +4 -3
- package/src/components/Settings/CountriesList/styles.js +1 -1
- package/src/components/Settings/Deliverect/index.js +17 -1
- package/src/components/Settings/DoordashConnect/index.js +17 -1
- package/src/components/Settings/DropdownOptionList/index.js +1 -0
- package/src/components/Settings/DropdownOptionList/styles.js +1 -1
- package/src/components/Settings/IntegrationListing/index.js +3 -0
- package/src/components/Settings/ItsaCheckmate/index.js +17 -1
- package/src/components/Settings/LalamoveConnect/index.js +17 -1
- package/src/components/Settings/LanguageTransTable/styles.js +1 -1
- package/src/components/Settings/PickerExpress/index.js +17 -1
- package/src/components/Settings/PlaceListing/index.js +1 -0
- package/src/components/Settings/PlaceListing/styles.js +1 -1
- package/src/components/Settings/PluginList/styles.js +8 -0
- package/src/components/Settings/Settings/index.js +1 -0
- package/src/components/Settings/SettingsDetail/index.js +18 -1
- package/src/components/Settings/SettingsDetail/styles.js +9 -0
- package/src/components/Settings/SettingsImage/index.js +1 -1
- package/src/components/Settings/SitesAuthSettings/index.js +26 -2
- package/src/components/Settings/SitesAuthSettings/styles.js +14 -1
- package/src/components/Settings/WebhookList/styles.js +8 -0
- package/src/components/Shared/Modal/index.js +8 -3
- package/src/components/Shared/ProtectedRoute/index.js +7 -1
- package/src/components/Shared/SideBar/index.js +30 -10
- package/src/components/Shared/SideBar/styles.js +13 -14
- package/src/components/SidebarMenu/index.js +3 -6
- package/src/components/Stores/AddBusinessForm/index.js +1 -1
- package/src/components/Stores/BusinessAdd/Images/index.js +1 -1
- package/src/components/Stores/BusinessAdd/Photos/index.js +1 -1
- package/src/components/Stores/BusinessAddStore/index.js +0 -1
- package/src/components/Stores/BusinessBrandGENDetail/index.js +19 -18
- package/src/components/Stores/BusinessBrandListing/index.js +29 -11
- package/src/components/Stores/BusinessBrandListing/styles.js +7 -3
- package/src/components/Stores/BusinessDeliveryZoneInformation/index.js +1 -1
- package/src/components/Stores/BusinessDetails/index.js +8 -0
- package/src/components/Stores/BusinessFilterGroup/index.js +168 -0
- package/src/components/Stores/BusinessFilterGroup/styles.js +116 -0
- package/src/components/Stores/BusinessInformation/index.js +1 -1
- package/src/components/Stores/BusinessOrderingChannels/index.js +4 -2
- package/src/components/Stores/BusinessProductAddForm/index.js +2 -2
- package/src/components/Stores/BusinessProductList/index.js +1 -0
- package/src/components/Stores/BusinessProductList/styles.js +1 -4
- package/src/components/Stores/BusinessProductsCategories/styles.js +1 -5
- package/src/components/Stores/BusinessProductsCategoyDetails/index.js +23 -3
- package/src/components/Stores/BusinessProductsCategoyDetails/styles.js +2 -2
- package/src/components/Stores/BusinessProductsCategoyInfo/index.js +18 -47
- package/src/components/Stores/BusinessProductsListing/index.js +13 -10
- package/src/components/Stores/BusinessPromotionList/styles.js +1 -1
- package/src/components/Stores/BusinessSalesChannel/index.js +165 -0
- package/src/components/Stores/BusinessSalesChannel/styles.js +75 -0
- package/src/components/Stores/BusinessSalesFacebook/FacebookPost.js +29 -0
- package/src/components/Stores/BusinessSalesFacebook/FacebookProfile.js +51 -0
- package/src/components/Stores/BusinessSalesFacebook/index.js +81 -0
- package/src/components/Stores/BusinessSalesFacebook/styles.js +135 -0
- package/src/components/Stores/BusinessSalesGoogle/index.js +88 -0
- package/src/components/Stores/BusinessSalesGoogle/styles.js +119 -0
- package/src/components/Stores/BusinessSalesInstagram/AdvancedInstagram.js +54 -0
- package/src/components/Stores/BusinessSalesInstagram/GeneralInstagram.js +53 -0
- package/src/components/Stores/BusinessSalesInstagram/index.js +81 -0
- package/src/components/Stores/BusinessSalesInstagram/styles.js +157 -0
- package/src/components/Stores/BusinessSalesTiktok/index.js +116 -0
- package/src/components/Stores/BusinessSalesTiktok/styles.js +100 -0
- package/src/components/Stores/BusinessServiceProfessionals/index.js +1 -0
- package/src/components/Stores/BusinessSummary/index.js +32 -3
- package/src/components/Stores/BusinessTypeDetail/index.js +1 -1
- package/src/components/Stores/BusinessesList/styles.js +1 -1
- package/src/components/Stores/BusinessesListing/index.js +24 -11
- package/src/components/Stores/BusinessesListingHeader/index.js +25 -4
- package/src/components/Stores/BusinessesListingHeader/styles.js +13 -1
- package/src/components/Stores/ImportersButton/index.js +1 -0
- package/src/components/Stores/PaymentOption/index.js +4 -6
- package/src/components/Stores/PaymentOptionMethods/index.js +42 -21
- package/src/components/Stores/PaymentOptionPaypal/index.js +42 -21
- package/src/components/Stores/PaymentOptionStripeDirect/index.js +42 -21
- package/src/components/Stores/PaymethodOptionStripeConnect/index.js +45 -22
- package/src/components/Stores/PaymethodOptionStripeRedirect/index.js +42 -21
- package/src/components/Stores/ProductDetails/index.js +1 -0
- package/src/components/Stores/ProductDetailsAdvanced/index.js +18 -0
- package/src/components/Stores/ProductDetailsAdvanced/styles.js +5 -0
- package/src/components/Stores/ProductDetatilsInformation/index.js +2 -48
- package/src/components/Stores/ProductExtraOptionDetails/index.js +1 -1
- package/src/components/Stores/ProductExtraOptions/index.js +1 -1
- package/src/components/Stores/ProductExtraSuboption/index.js +1 -1
- package/src/components/Stores/ProductGallery/index.js +1 -1
- package/src/components/Stores/ProductSummary/index.js +24 -3
- package/src/components/Stores/ProductTagDetails/index.js +1 -1
- package/src/components/Stores/SeoOptions/index.js +18 -12
- package/src/components/Stores/SeoOptions/styles.js +5 -14
- package/src/components/Stores/ServiceDetail/index.js +1 -1
- package/src/components/Stores/WizardBusiness/index.js +1 -0
- package/src/components/Stores/index.js +2 -0
- package/src/components/Users/CustomerDetails/index.js +39 -14
- package/src/components/Users/CustomerDetails/styles.js +2 -5
- package/src/components/Users/CustomersListing/index.js +32 -15
- package/src/components/Users/CustomersListing/styles.js +1 -1
- package/src/components/Users/OccupationSelector/index.js +1 -1
- package/src/components/Users/ProfessionalDetail/index.js +43 -23
- package/src/components/Users/ProfessionalDetail/styles.js +5 -0
- package/src/components/Users/ProfessionalList/styles.js +1 -1
- package/src/components/Users/ProfessionalListing/index.js +6 -1
- package/src/components/Users/UserAddForm/index.js +1 -1
- package/src/components/Users/UserDetails/index.js +34 -17
- package/src/components/Users/UserDetails/styles.js +17 -2
- package/src/components/Users/UserDetailsLateralBar/styles.js +0 -1
- package/src/components/Users/UserFilterGroup/index.js +306 -0
- package/src/components/Users/UserFilterGroup/styles.js +116 -0
- package/src/components/Users/UserProfileForm/index.js +1 -1
- package/src/components/Users/UsersExportCSV/index.js +19 -1
- package/src/components/Users/UsersList/index.js +9 -2
- package/src/components/Users/UsersList/styles.js +28 -1
- package/src/components/Users/UsersListing/index.js +7 -1
- package/src/components/Users/UsersListingHeader/index.js +66 -33
- package/src/components/Users/UsersListingHeader/styles.js +4 -0
- package/src/components/Users/index.js +2 -0
- package/src/config/constants.js +1215 -244
- package/src/index.js +2 -2
- package/template/assets/images/icons/business-google.svg +26 -0
- package/template/assets/images/icons/facebook.svg +11 -0
- package/template/assets/images/icons/instagram.svg +19 -0
- package/template/assets/images/icons/tiktok.svg +11 -0
- package/template/assets/images/salesChannels/facebook-post-step1.png +0 -0
- package/template/assets/images/salesChannels/facebook-post-step2.png +0 -0
- package/template/assets/images/salesChannels/facebook-profile-step2.png +0 -0
- package/template/assets/images/salesChannels/facebook-profile-step3-1.png +0 -0
- package/template/assets/images/salesChannels/facebook-profile-step3-2.png +0 -0
- package/template/assets/images/salesChannels/facebook-profile-step4.png +0 -0
- package/template/assets/images/salesChannels/facebook-profile-step5.png +0 -0
- package/template/assets/images/salesChannels/google-step1.png +0 -0
- package/template/assets/images/salesChannels/google-step2.png +0 -0
- package/template/assets/images/salesChannels/google-step3.png +0 -0
- package/template/assets/images/salesChannels/instagram-advanced-step31.png +0 -0
- package/template/assets/images/salesChannels/instagram-advanced-step32.png +0 -0
- package/template/assets/images/salesChannels/instagram-advanced-step41.png +0 -0
- package/template/assets/images/salesChannels/instagram-advanced-step42.png +0 -0
- package/template/assets/images/salesChannels/instagram-general-step2.png +0 -0
- package/template/assets/images/salesChannels/instagram-general-step3.png +0 -0
- package/template/assets/images/salesChannels/instagram-general-step4.png +0 -0
- package/template/assets/images/salesChannels/instagram-general-step5.png +0 -0
- package/template/assets/images/salesChannels/instagram-general-step6.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step1.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step10.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step2.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step3.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step4.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step5.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step6.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step7.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step8.png +0 -0
- package/template/assets/images/salesChannels/tiktok-step9.png +0 -0
- package/template/pages/CustomersList/index.js +1 -1
- package/template/pages/Login/index.js +7 -1
- package/src/components/Loyalty/PointsWallet/index.js +0 -71
- /package/_bundles/{ordering-ui-admin.a97f0d1801ec4a89a98e.js.LICENSE.txt → ordering-ui-admin.1a09d41a4e6cd3d1e1cf.js.LICENSE.txt} +0 -0
|
@@ -163,6 +163,7 @@ var BusinessServiceProfessionalsUI = function BusinessServiceProfessionalsUI(pro
|
|
|
163
163
|
handleDeleteUser: handleDeleteUser
|
|
164
164
|
})) : /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, openDetail && /*#__PURE__*/_react.default.createElement(_Shared.Modal, {
|
|
165
165
|
width: "760px",
|
|
166
|
+
hideCloseDefault: true,
|
|
166
167
|
open: openDetail,
|
|
167
168
|
onClose: function onClose() {
|
|
168
169
|
return handleCloseDetail();
|
|
@@ -15,6 +15,7 @@ var _reactBootstrapIcons = require("react-bootstrap-icons");
|
|
|
15
15
|
var _styles = require("../../../styles");
|
|
16
16
|
var _Shared = require("../../Shared");
|
|
17
17
|
var _BusinessPreview = require("../BusinessPreview");
|
|
18
|
+
var _useWindowSize2 = require("../../../hooks/useWindowSize");
|
|
18
19
|
var _styles2 = require("./styles");
|
|
19
20
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
20
21
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
@@ -39,7 +40,8 @@ var BusinessSummary = function BusinessSummary(props) {
|
|
|
39
40
|
selectedItem = props.selectedItem,
|
|
40
41
|
handleSelectedItem = props.handleSelectedItem,
|
|
41
42
|
handleDuplicateBusiness = props.handleDuplicateBusiness,
|
|
42
|
-
handleDeleteBusiness = props.handleDeleteBusiness
|
|
43
|
+
handleDeleteBusiness = props.handleDeleteBusiness,
|
|
44
|
+
extraOpen = props.extraOpen;
|
|
43
45
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
44
46
|
_useLanguage2 = _slicedToArray(_useLanguage, 2),
|
|
45
47
|
t = _useLanguage2[1];
|
|
@@ -53,6 +55,8 @@ var BusinessSummary = function BusinessSummary(props) {
|
|
|
53
55
|
var _useApi = (0, _orderingComponentsAdminExternal.useApi)(),
|
|
54
56
|
_useApi2 = _slicedToArray(_useApi, 1),
|
|
55
57
|
ordering = _useApi2[0];
|
|
58
|
+
var _useWindowSize = (0, _useWindowSize2.useWindowSize)(),
|
|
59
|
+
width = _useWindowSize.width;
|
|
56
60
|
var _useState = (0, _react.useState)(false),
|
|
57
61
|
_useState2 = _slicedToArray(_useState, 2),
|
|
58
62
|
isBusinessPreview = _useState2[0],
|
|
@@ -61,14 +65,18 @@ var BusinessSummary = function BusinessSummary(props) {
|
|
|
61
65
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
62
66
|
selectedView = _useState4[0],
|
|
63
67
|
setSelectedView = _useState4[1];
|
|
64
|
-
var _useState5 = (0, _react.useState)(
|
|
68
|
+
var _useState5 = (0, _react.useState)(false),
|
|
69
|
+
_useState6 = _slicedToArray(_useState5, 2),
|
|
70
|
+
isExpand = _useState6[0],
|
|
71
|
+
setIsExpand = _useState6[1];
|
|
72
|
+
var _useState7 = (0, _react.useState)({
|
|
65
73
|
open: false,
|
|
66
74
|
content: null,
|
|
67
75
|
handleOnAccept: null
|
|
68
76
|
}),
|
|
69
|
-
|
|
70
|
-
confirm =
|
|
71
|
-
setConfirm =
|
|
77
|
+
_useState8 = _slicedToArray(_useState7, 2),
|
|
78
|
+
confirm = _useState8[0],
|
|
79
|
+
setConfirm = _useState8[1];
|
|
72
80
|
var handleOpenCategory = function handleOpenCategory() {
|
|
73
81
|
var _businessState$busine;
|
|
74
82
|
events.emit('go_to_page', {
|
|
@@ -125,6 +133,9 @@ var BusinessSummary = function BusinessSummary(props) {
|
|
|
125
133
|
// value: t('PUBLISHING', 'Publishing')
|
|
126
134
|
// },
|
|
127
135
|
{
|
|
136
|
+
key: 'sales_channels',
|
|
137
|
+
value: t('SALES_CHANNELS', 'Sales channels')
|
|
138
|
+
}, {
|
|
128
139
|
key: 'layout',
|
|
129
140
|
value: t('LAYOUT', 'Layout')
|
|
130
141
|
}, {
|
|
@@ -143,6 +154,17 @@ var BusinessSummary = function BusinessSummary(props) {
|
|
|
143
154
|
}
|
|
144
155
|
});
|
|
145
156
|
};
|
|
157
|
+
var expandSideBar = function expandSideBar() {
|
|
158
|
+
var element = document.getElementById('business_details_bar');
|
|
159
|
+
if (!element) return;
|
|
160
|
+
if (isExpand) element.style.width = '500px';else element.style.width = '100vw';
|
|
161
|
+
setIsExpand(function (prev) {
|
|
162
|
+
return !prev;
|
|
163
|
+
});
|
|
164
|
+
};
|
|
165
|
+
(0, _react.useEffect)(function () {
|
|
166
|
+
if (extraOpen) setIsExpand(false);
|
|
167
|
+
}, [extraOpen]);
|
|
146
168
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_styles2.BusinessDetailsContainer, null, /*#__PURE__*/_react.default.createElement(_styles2.DetailsHeader, null, /*#__PURE__*/_react.default.createElement(_styles2.LeftHeader, null, businessState !== null && businessState !== void 0 && businessState.loading ? /*#__PURE__*/_react.default.createElement(_styles2.BusinessName, null, /*#__PURE__*/_react.default.createElement(_reactLoadingSkeleton.default, {
|
|
147
169
|
width: 100
|
|
148
170
|
})) : /*#__PURE__*/_react.default.createElement(_styles2.BusinessName, null, businessState === null || businessState === void 0 ? void 0 : (_businessState$busine3 = businessState.business) === null || _businessState$busine3 === void 0 ? void 0 : _businessState$busine3.name), businessState !== null && businessState !== void 0 && businessState.loading ? /*#__PURE__*/_react.default.createElement(_reactLoadingSkeleton.default, {
|
|
@@ -153,7 +175,12 @@ var BusinessSummary = function BusinessSummary(props) {
|
|
|
153
175
|
})), /*#__PURE__*/_react.default.createElement(_styles2.RightHeader, null, /*#__PURE__*/_react.default.createElement(_styles.IconButton, {
|
|
154
176
|
disabled: true
|
|
155
177
|
// onClick={() => handleSelectedItem('support')}
|
|
156
|
-
}, /*#__PURE__*/_react.default.createElement(_reactBootstrapIcons.LifePreserver, null)),
|
|
178
|
+
}, /*#__PURE__*/_react.default.createElement(_reactBootstrapIcons.LifePreserver, null)), width > 576 && !extraOpen && /*#__PURE__*/_react.default.createElement(_styles.IconButton, {
|
|
179
|
+
color: "black",
|
|
180
|
+
onClick: function onClick() {
|
|
181
|
+
return expandSideBar();
|
|
182
|
+
}
|
|
183
|
+
}, isExpand ? /*#__PURE__*/_react.default.createElement(_reactBootstrapIcons.ArrowsAngleContract, null) : /*#__PURE__*/_react.default.createElement(_reactBootstrapIcons.ArrowsAngleExpand, null)), /*#__PURE__*/_react.default.createElement(_styles2.ActionSelectorWrapper, null, /*#__PURE__*/_react.default.createElement(_reactBootstrap.DropdownButton, {
|
|
157
184
|
menuAlign: theme !== null && theme !== void 0 && theme.rtl ? 'left' : 'right',
|
|
158
185
|
title: /*#__PURE__*/_react.default.createElement(_reactBootstrapIcons.ThreeDots, null),
|
|
159
186
|
id: theme !== null && theme !== void 0 && theme.rtl ? 'dropdown-menu-align-left' : 'dropdown-menu-align-right'
|
|
@@ -245,7 +245,7 @@ var BusinessTypeDetailUI = function BusinessTypeDetailUI(props) {
|
|
|
245
245
|
padding: "30px",
|
|
246
246
|
title: t('IMAGE_CROP', 'Image crop'),
|
|
247
247
|
open: cropState === null || cropState === void 0 ? void 0 : cropState.open,
|
|
248
|
-
|
|
248
|
+
onRemove: function onRemove() {
|
|
249
249
|
return setCropState(_objectSpread(_objectSpread({}, cropState), {}, {
|
|
250
250
|
open: false
|
|
251
251
|
}));
|
|
@@ -32,7 +32,7 @@ var BusinessCardContainer = _styledComponents.default.div(_templateObject4 || (_
|
|
|
32
32
|
});
|
|
33
33
|
exports.BusinessCardContainer = BusinessCardContainer;
|
|
34
34
|
var AddNewButtonLink = _styledComponents.default.div(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n width: fit-content;\n cursor: pointer;\n color: ", ";\n font-size: 14px;\n"])), function (props) {
|
|
35
|
-
return props.theme.colors.
|
|
35
|
+
return props.theme.colors.primary;
|
|
36
36
|
});
|
|
37
37
|
exports.AddNewButtonLink = AddNewButtonLink;
|
|
38
38
|
var BusinessListBottomContainer = _styledComponents.default.div(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n display: flex;\n flex-wrap: wrap;\n justify-content: space-between;\n align-items: center;\n margin-top: 10px;\n"])));
|
|
@@ -61,7 +61,11 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
61
61
|
handleEnableAllBusiness = props.handleEnableAllBusiness,
|
|
62
62
|
handleDeleteMultiBusinesses = props.handleDeleteMultiBusinesses,
|
|
63
63
|
setBusinessIds = props.setBusinessIds,
|
|
64
|
-
countriesState = props.countriesState
|
|
64
|
+
countriesState = props.countriesState,
|
|
65
|
+
handleChangeFilterValues = props.handleChangeFilterValues,
|
|
66
|
+
filterValues = props.filterValues,
|
|
67
|
+
businessTypeSelected = props.businessTypeSelected,
|
|
68
|
+
inActiveBusinesses = props.inActiveBusinesses;
|
|
65
69
|
var query = new URLSearchParams((0, _reactRouterDom.useLocation)().search);
|
|
66
70
|
var theme = (0, _styledComponents.useTheme)();
|
|
67
71
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
@@ -116,8 +120,8 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
116
120
|
setIsAdd = _useState22[1];
|
|
117
121
|
var noBusinesses = (0, _react.useMemo)(function () {
|
|
118
122
|
var _businessList$busines;
|
|
119
|
-
return !(businessList !== null && businessList !== void 0 && businessList.loading) && (businessList === null || businessList === void 0 ? void 0 : (_businessList$busines = businessList.businesses) === null || _businessList$busines === void 0 ? void 0 : _businessList$busines.length) === 0 && (pagination === null || pagination === void 0 ? void 0 : pagination.currentPage) === 1 && !searchValue;
|
|
120
|
-
}, [businessList === null || businessList === void 0 ? void 0 : businessList.loading, businessList === null || businessList === void 0 ? void 0 : businessList.businesses, pagination, searchValue]);
|
|
123
|
+
return !(businessList !== null && businessList !== void 0 && businessList.loading) && (businessList === null || businessList === void 0 ? void 0 : (_businessList$busines = businessList.businesses) === null || _businessList$busines === void 0 ? void 0 : _businessList$busines.length) === 0 && (pagination === null || pagination === void 0 ? void 0 : pagination.currentPage) === 1 && !searchValue && Object.keys(filterValues).length === 0 && selectedBusinessActiveState && !businessTypeSelected && (inActiveBusinesses === null || inActiveBusinesses === void 0 ? void 0 : inActiveBusinesses.length) === 0;
|
|
124
|
+
}, [businessList === null || businessList === void 0 ? void 0 : businessList.loading, businessList === null || businessList === void 0 ? void 0 : businessList.businesses, pagination, searchValue, filterValues, selectedBusinessActiveState, businessTypeSelected, inActiveBusinesses]);
|
|
121
125
|
var handleGotToAdd = function handleGotToAdd() {
|
|
122
126
|
if (countriesState !== null && countriesState !== void 0 && countriesState.enabled) setIsAdd(true);else events.emit('go_to_page', {
|
|
123
127
|
page: 'business_add'
|
|
@@ -229,11 +233,13 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
229
233
|
handleRefreshBusinesses: loadBusinesses,
|
|
230
234
|
loading: businessList.loading,
|
|
231
235
|
noBusinesses: noBusinesses,
|
|
232
|
-
openAddBusiness: openAddBusiness
|
|
233
|
-
|
|
236
|
+
openAddBusiness: openAddBusiness,
|
|
237
|
+
handleChangeFilterValues: handleChangeFilterValues,
|
|
238
|
+
filterValues: filterValues
|
|
239
|
+
}), !noBusinesses && /*#__PURE__*/_react.default.createElement(_styles.ViewContainer, null, /*#__PURE__*/_react.default.createElement(_BusinessActiveStateFilter.BusinessActiveStateFilter, {
|
|
234
240
|
selectedBusinessActiveState: selectedBusinessActiveState,
|
|
235
241
|
handleChangeBusinessActiveState: handleChangeBusinessActiveState
|
|
236
|
-
}),
|
|
242
|
+
}), /*#__PURE__*/_react.default.createElement(_styles.WrapperView, null, /*#__PURE__*/_react.default.createElement(_styles.ViewMethodButton, {
|
|
237
243
|
active: viewMethod === 'card',
|
|
238
244
|
onClick: function onClick() {
|
|
239
245
|
return handleViewMethod('card');
|
|
@@ -1,19 +1,24 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
3
4
|
Object.defineProperty(exports, "__esModule", {
|
|
4
5
|
value: true
|
|
5
6
|
});
|
|
6
7
|
exports.BusinessesListingHeader = void 0;
|
|
7
|
-
var _react =
|
|
8
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
8
9
|
var _orderingComponentsAdminExternal = require("ordering-components-admin-external");
|
|
9
10
|
var _reactBootstrapIcons = require("react-bootstrap-icons");
|
|
11
|
+
var _MdcFilterOff = _interopRequireDefault(require("@meronex/icons/mdc/MdcFilterOff"));
|
|
10
12
|
var _styles = require("../../../styles");
|
|
11
13
|
var _Shared = require("../../Shared");
|
|
12
14
|
var _InfoShareContext = require("../../../contexts/InfoShareContext");
|
|
13
15
|
var _reactBootstrap = require("react-bootstrap");
|
|
14
16
|
var _ImportersButton = require("../ImportersButton");
|
|
15
17
|
var _styles2 = require("./styles");
|
|
18
|
+
var _BusinessFilterGroup = require("../BusinessFilterGroup");
|
|
16
19
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
20
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
21
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
17
22
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
18
23
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
19
24
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
@@ -28,7 +33,9 @@ var BusinessesListingHeader = function BusinessesListingHeader(props) {
|
|
|
28
33
|
handleRefreshBusinesses = props.handleRefreshBusinesses,
|
|
29
34
|
loading = props.loading,
|
|
30
35
|
noBusinesses = props.noBusinesses,
|
|
31
|
-
handleGotToAdd = props.handleGotToAdd
|
|
36
|
+
handleGotToAdd = props.handleGotToAdd,
|
|
37
|
+
handleChangeFilterValues = props.handleChangeFilterValues,
|
|
38
|
+
filterValues = props.filterValues;
|
|
32
39
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
33
40
|
_useLanguage2 = _slicedToArray(_useLanguage, 2),
|
|
34
41
|
t = _useLanguage2[1];
|
|
@@ -36,6 +43,17 @@ var BusinessesListingHeader = function BusinessesListingHeader(props) {
|
|
|
36
43
|
_useInfoShare2 = _slicedToArray(_useInfoShare, 2),
|
|
37
44
|
isCollapse = _useInfoShare2[0].isCollapse,
|
|
38
45
|
handleMenuCollapse = _useInfoShare2[1].handleMenuCollapse;
|
|
46
|
+
var _useState = (0, _react.useState)(false),
|
|
47
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
48
|
+
filterApplied = _useState2[0],
|
|
49
|
+
setFilterApplied = _useState2[1];
|
|
50
|
+
var _useState3 = (0, _react.useState)(false),
|
|
51
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
52
|
+
isFilterModal = _useState4[0],
|
|
53
|
+
setIsFilterModal = _useState4[1];
|
|
54
|
+
(0, _react.useEffect)(function () {
|
|
55
|
+
setFilterApplied(Object.keys(filterValues).length > 0);
|
|
56
|
+
}, [filterValues]);
|
|
39
57
|
return /*#__PURE__*/_react.default.createElement(_styles2.HeaderContainer, null, /*#__PURE__*/_react.default.createElement(_styles2.HeaderTitleContainer, null, isCollapse && /*#__PURE__*/_react.default.createElement(_styles.IconButton, {
|
|
40
58
|
color: "black",
|
|
41
59
|
onClick: function onClick() {
|
|
@@ -83,6 +101,18 @@ var BusinessesListingHeader = function BusinessesListingHeader(props) {
|
|
|
83
101
|
search: searchValue,
|
|
84
102
|
placeholder: t('SEARCH', 'Search'),
|
|
85
103
|
customClass: "searchBar"
|
|
86
|
-
})
|
|
104
|
+
}), /*#__PURE__*/_react.default.createElement(_styles.IconButton, {
|
|
105
|
+
color: "black",
|
|
106
|
+
onClick: function onClick() {
|
|
107
|
+
return setIsFilterModal(true);
|
|
108
|
+
},
|
|
109
|
+
name: "filter-btn"
|
|
110
|
+
}, filterApplied ? /*#__PURE__*/_react.default.createElement(_reactBootstrapIcons.Funnel, null) : /*#__PURE__*/_react.default.createElement(_MdcFilterOff.default, null))), /*#__PURE__*/_react.default.createElement(_BusinessFilterGroup.BusinessFilterGroup, {
|
|
111
|
+
handleChangeFilterValues: handleChangeFilterValues,
|
|
112
|
+
onClose: function onClose() {
|
|
113
|
+
return setIsFilterModal(false);
|
|
114
|
+
},
|
|
115
|
+
isFilterModal: isFilterModal
|
|
116
|
+
}));
|
|
87
117
|
};
|
|
88
118
|
exports.BusinessesListingHeader = BusinessesListingHeader;
|
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.HeaderTitleContainer = exports.HeaderContainer = exports.ActionsWrapper = void 0;
|
|
8
8
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
9
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11;
|
|
9
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13;
|
|
10
10
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
11
11
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
12
12
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
@@ -24,11 +24,14 @@ var HeaderTitleContainer = _styledComponents.default.div(_templateObject2 || (_t
|
|
|
24
24
|
return (_props$theme2 = props.theme) !== null && _props$theme2 !== void 0 && _props$theme2.rtl ? (0, _styledComponents.css)(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n margin-left: -8px;\n margin-right: 8px;\n "]))) : (0, _styledComponents.css)(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n margin-right: -8px;\n margin-left: 8px;\n "])));
|
|
25
25
|
});
|
|
26
26
|
exports.HeaderTitleContainer = HeaderTitleContainer;
|
|
27
|
-
var ActionsWrapper = _styledComponents.default.div(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n > button {\n height: 41px;\n width: 90px;\n white-space: nowrap;\n margin-top: 5px;\n ", "\n @media (min-width: 768px) {\n width: unset;\n }\n }\n > .searchBar {\n min-width: 100px;\n margin-top: 5px;\n }\n > .importerGroup {\n margin-top: 5px;\n ", "\n\n > button {\n width: 90px;\n > svg {\n display: none;\n @media (min-width: 768px) {\n display: inline;\n }\n }\n @media (min-width: 768px) {\n width: unset;\n }\n }\n }\n\n @keyframes spinner-content {\n 0% { transform: rotate(0) }\n 100% { transform: rotate(360deg) }\n }\n\n > .loading {\n > svg {\n animation: spinner-content 1.85s linear infinite;\n }\n }\n"])), function (props) {
|
|
27
|
+
var ActionsWrapper = _styledComponents.default.div(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n > button:not(:last-child) {\n height: 41px;\n width: 90px;\n white-space: nowrap;\n margin-top: 5px;\n ", "\n @media (min-width: 768px) {\n width: unset;\n }\n }\n > button:last-child {\n margin-top: 5px;\n height: 41px;\n }\n > div {\n margin-top: 5px;\n }\n > .searchBar {\n min-width: 100px;\n margin-top: 5px;\n ", "\n }\n > .importerGroup {\n margin-top: 5px;\n ", "\n\n > button {\n width: 90px;\n > svg {\n display: none;\n @media (min-width: 768px) {\n display: inline;\n }\n }\n @media (min-width: 768px) {\n width: unset;\n }\n }\n }\n\n @keyframes spinner-content {\n 0% { transform: rotate(0) }\n 100% { transform: rotate(360deg) }\n }\n\n > .loading {\n > svg {\n animation: spinner-content 1.85s linear infinite;\n }\n }\n"])), function (props) {
|
|
28
28
|
var _props$theme3;
|
|
29
29
|
return (_props$theme3 = props.theme) !== null && _props$theme3 !== void 0 && _props$theme3.rtl ? (0, _styledComponents.css)(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n margin-left: 15px;\n "]))) : (0, _styledComponents.css)(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["\n margin-right: 15px;\n "])));
|
|
30
30
|
}, function (props) {
|
|
31
31
|
var _props$theme4;
|
|
32
32
|
return (_props$theme4 = props.theme) !== null && _props$theme4 !== void 0 && _props$theme4.rtl ? (0, _styledComponents.css)(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["\n margin-left: 15px;\n "]))) : (0, _styledComponents.css)(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["\n margin-right: 15px;\n "])));
|
|
33
|
+
}, function (props) {
|
|
34
|
+
var _props$theme5;
|
|
35
|
+
return (_props$theme5 = props.theme) !== null && _props$theme5 !== void 0 && _props$theme5.rtl ? (0, _styledComponents.css)(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["\n margin-left: 15px;\n "]))) : (0, _styledComponents.css)(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["\n margin-right: 15px;\n "])));
|
|
33
36
|
});
|
|
34
37
|
exports.ActionsWrapper = ActionsWrapper;
|
|
@@ -44,7 +44,8 @@ var ImportersButton = function ImportersButton(props) {
|
|
|
44
44
|
open: openImporters,
|
|
45
45
|
onClose: function onClose() {
|
|
46
46
|
return setOpenImporters(false);
|
|
47
|
-
}
|
|
47
|
+
},
|
|
48
|
+
showExpandIcon: true
|
|
48
49
|
}, /*#__PURE__*/_react.default.createElement(_ImportersListing.ImportersListing, {
|
|
49
50
|
setExtraOpen: setExtraOpen
|
|
50
51
|
})));
|
|
@@ -151,16 +151,10 @@ var PaymentOption = function PaymentOption(props) {
|
|
|
151
151
|
});
|
|
152
152
|
}, [businessPaymethod === null || businessPaymethod === void 0 ? void 0 : businessPaymethod.id, businessPaymethod === null || businessPaymethod === void 0 ? void 0 : businessPaymethod.sandbox, businessPaymethod === null || businessPaymethod === void 0 ? void 0 : businessPaymethod.allowed_order_types]);
|
|
153
153
|
(0, _react.useEffect)(function () {
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
}
|
|
159
|
-
if (changesState !== null && changesState !== void 0 && changesState.sites) {
|
|
160
|
-
setLocalState({
|
|
161
|
-
sites: changesState === null || changesState === void 0 ? void 0 : changesState.sites
|
|
162
|
-
});
|
|
163
|
-
}
|
|
154
|
+
var changes = {};
|
|
155
|
+
if (changesState !== null && changesState !== void 0 && changesState.allowed_order_types) changes.allowed_order_types = changesState === null || changesState === void 0 ? void 0 : changesState.allowed_order_types;
|
|
156
|
+
if (changesState !== null && changesState !== void 0 && changesState.sites) changes.sites = changesState === null || changesState === void 0 ? void 0 : changesState.sites;
|
|
157
|
+
if (Object.keys(changes).length > 0) setLocalState(JSON.parse(JSON.stringify(changes)));
|
|
164
158
|
}, [changesState === null || changesState === void 0 ? void 0 : changesState.allowed_order_types, changesState === null || changesState === void 0 ? void 0 : changesState.sites]);
|
|
165
159
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_styles3.Container, {
|
|
166
160
|
id: "payment_method_option"
|
|
@@ -36,7 +36,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
36
36
|
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
37
37
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
38
38
|
var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
39
|
-
var
|
|
39
|
+
var _localState$sites, _businessPaymethod$si, _sitesState$sites2, _ref2, _changesState$sandbox, _changesState$data, _changesState$data2, _businessPaymethod$da, _changesState$data3, _changesState$data4, _businessPaymethod$da2, _changesState$data_sa, _changesState$data_sa2, _businessPaymethod$da3, _changesState$data_sa3, _changesState$data_sa4, _businessPaymethod$da4, _sitesState$sites3;
|
|
40
40
|
var open = props.open,
|
|
41
41
|
onClose = props.onClose,
|
|
42
42
|
orderTypes = props.orderTypes,
|
|
@@ -81,16 +81,35 @@ var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
|
81
81
|
_useState8 = _slicedToArray(_useState7, 2),
|
|
82
82
|
localState = _useState8[0],
|
|
83
83
|
setLocalState = _useState8[1];
|
|
84
|
+
var filteredOptions = (_localState$sites = localState === null || localState === void 0 ? void 0 : localState.sites) !== null && _localState$sites !== void 0 ? _localState$sites : businessPaymethod === null || businessPaymethod === void 0 ? void 0 : (_businessPaymethod$si = businessPaymethod.sites) === null || _businessPaymethod$si === void 0 ? void 0 : _businessPaymethod$si.filter(function (a) {
|
|
85
|
+
var _sitesState$sites;
|
|
86
|
+
return sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$sites = sitesState.sites) === null || _sitesState$sites === void 0 ? void 0 : _sitesState$sites.find(function (b) {
|
|
87
|
+
return a.id === b.id;
|
|
88
|
+
});
|
|
89
|
+
});
|
|
90
|
+
var _useState9 = (0, _react.useState)(!(filteredOptions !== null && filteredOptions !== void 0 && filteredOptions.length)),
|
|
91
|
+
_useState10 = _slicedToArray(_useState9, 2),
|
|
92
|
+
all = _useState10[0],
|
|
93
|
+
setAll = _useState10[1];
|
|
84
94
|
var setPaymethodInfo = function setPaymethodInfo(values) {
|
|
85
|
-
var _ref, _changesState$values$, _businessPaymethod$va;
|
|
86
95
|
var data = {};
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
96
|
+
if ((values === null || values === void 0 ? void 0 : values.value) === 'All') {
|
|
97
|
+
data[values.key] = [];
|
|
98
|
+
setAll(!all);
|
|
99
|
+
} else {
|
|
100
|
+
var _ref, _changesState$values$, _businessPaymethod$va;
|
|
101
|
+
var array = (_ref = (_changesState$values$ = changesState === null || changesState === void 0 ? void 0 : changesState[values.key]) !== null && _changesState$values$ !== void 0 ? _changesState$values$ : values.key === 'allowed_order_types' ? businessPaymethod === null || businessPaymethod === void 0 ? void 0 : businessPaymethod[values.key] : businessPaymethod === null || businessPaymethod === void 0 ? void 0 : (_businessPaymethod$va = businessPaymethod[values.key]) === null || _businessPaymethod$va === void 0 ? void 0 : _businessPaymethod$va.map(function (i) {
|
|
102
|
+
return i.id;
|
|
103
|
+
})) !== null && _ref !== void 0 ? _ref : [];
|
|
104
|
+
array = _toConsumableArray(new Set(array.includes(values.value) ? array.filter(function (item) {
|
|
105
|
+
return item !== values.value;
|
|
106
|
+
}) : [].concat(_toConsumableArray(array), [values.value])));
|
|
107
|
+
data[values.key] = array.length > 0 ? array : [];
|
|
108
|
+
if (values.key === 'sites') {
|
|
109
|
+
var _data$sites;
|
|
110
|
+
setAll(!(data !== null && data !== void 0 && (_data$sites = data.sites) !== null && _data$sites !== void 0 && _data$sites.length));
|
|
111
|
+
}
|
|
112
|
+
}
|
|
94
113
|
handleChangeBusinessPaymentState(data);
|
|
95
114
|
};
|
|
96
115
|
var actionSidebar = function actionSidebar(value) {
|
|
@@ -139,16 +158,10 @@ var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
|
139
158
|
cleanChangesState(initState);
|
|
140
159
|
}, []);
|
|
141
160
|
(0, _react.useEffect)(function () {
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
}
|
|
147
|
-
if (changesState !== null && changesState !== void 0 && changesState.sites) {
|
|
148
|
-
setLocalState({
|
|
149
|
-
sites: changesState === null || changesState === void 0 ? void 0 : changesState.sites
|
|
150
|
-
});
|
|
151
|
-
}
|
|
161
|
+
var changes = {};
|
|
162
|
+
if (changesState !== null && changesState !== void 0 && changesState.allowed_order_types) changes.allowed_order_types = changesState === null || changesState === void 0 ? void 0 : changesState.allowed_order_types;
|
|
163
|
+
if (changesState !== null && changesState !== void 0 && changesState.sites) changes.sites = changesState === null || changesState === void 0 ? void 0 : changesState.sites;
|
|
164
|
+
if (Object.keys(changes).length > 0) setLocalState(JSON.parse(JSON.stringify(changes)));
|
|
152
165
|
}, [changesState === null || changesState === void 0 ? void 0 : changesState.sites, changesState === null || changesState === void 0 ? void 0 : changesState.allowed_order_types]);
|
|
153
166
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_styles2.Container, {
|
|
154
167
|
id: id
|
|
@@ -170,7 +183,7 @@ var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
|
170
183
|
onClick: function onClick() {
|
|
171
184
|
return setPaymentTabs(0);
|
|
172
185
|
}
|
|
173
|
-
}, t('GENERAL', 'General')), (sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$
|
|
186
|
+
}, t('GENERAL', 'General')), (sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$sites2 = sitesState.sites) === null || _sitesState$sites2 === void 0 ? void 0 : _sitesState$sites2.length) > 0 && /*#__PURE__*/_react.default.createElement(_styles3.Tab, {
|
|
174
187
|
active: paymentTabs === 1,
|
|
175
188
|
onClick: function onClick() {
|
|
176
189
|
return setPaymentTabs(1);
|
|
@@ -213,8 +226,18 @@ var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
|
213
226
|
onChange: function onChange(e) {
|
|
214
227
|
return handleChangeInput(e, true);
|
|
215
228
|
}
|
|
216
|
-
})), paymentTabs === 1 && (sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$
|
|
217
|
-
|
|
229
|
+
})), paymentTabs === 1 && (sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$sites3 = sitesState.sites) === null || _sitesState$sites3 === void 0 ? void 0 : _sitesState$sites3.length) > 0 && /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_styles2.TabOption, {
|
|
230
|
+
key: "all",
|
|
231
|
+
onClick: function onClick() {
|
|
232
|
+
return setPaymethodInfo({
|
|
233
|
+
key: 'sites',
|
|
234
|
+
value: 'All'
|
|
235
|
+
});
|
|
236
|
+
}
|
|
237
|
+
}, all ? /*#__PURE__*/_react.default.createElement(_RiCheckboxFill.default, {
|
|
238
|
+
className: "fill"
|
|
239
|
+
}) : /*#__PURE__*/_react.default.createElement(_RiCheckboxBlankLine.default, null), /*#__PURE__*/_react.default.createElement(_styles2.TabOptionName, null, t('ALL', 'All'))), !all && (sitesState === null || sitesState === void 0 ? void 0 : sitesState.sites.map(function (site) {
|
|
240
|
+
var _ref3, _localState$sites2, _businessPaymethod$si2;
|
|
218
241
|
return /*#__PURE__*/_react.default.createElement(_styles2.TabOption, {
|
|
219
242
|
key: site.id,
|
|
220
243
|
onClick: function onClick() {
|
|
@@ -223,12 +246,12 @@ var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
|
223
246
|
value: site.id
|
|
224
247
|
});
|
|
225
248
|
}
|
|
226
|
-
}, (_ref3 = (_localState$
|
|
249
|
+
}, (_ref3 = (_localState$sites2 = localState === null || localState === void 0 ? void 0 : localState.sites) !== null && _localState$sites2 !== void 0 ? _localState$sites2 : businessPaymethod === null || businessPaymethod === void 0 ? void 0 : (_businessPaymethod$si2 = businessPaymethod.sites) === null || _businessPaymethod$si2 === void 0 ? void 0 : _businessPaymethod$si2.map(function (s) {
|
|
227
250
|
return s.id;
|
|
228
251
|
})) !== null && _ref3 !== void 0 && _ref3.includes(site.id) ? /*#__PURE__*/_react.default.createElement(_RiCheckboxFill.default, {
|
|
229
252
|
className: "fill"
|
|
230
253
|
}) : /*#__PURE__*/_react.default.createElement(_RiCheckboxBlankLine.default, null), /*#__PURE__*/_react.default.createElement(_styles2.TabOptionName, null, site.name));
|
|
231
|
-
})), paymentTabs === 2 && orderTypes.map(function (type) {
|
|
254
|
+
}))), paymentTabs === 2 && orderTypes.map(function (type) {
|
|
232
255
|
var _ref4, _localState$allowed_o;
|
|
233
256
|
return /*#__PURE__*/_react.default.createElement(_styles2.TabOption, {
|
|
234
257
|
key: type.value,
|
|
@@ -37,7 +37,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
37
37
|
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
38
38
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
39
39
|
var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
40
|
-
var
|
|
40
|
+
var _localState$sites, _businessPaymethod$si, _sitesState$sites2, _changesState$sandbox, _changesState$data, _changesState$data2, _businessPaymethod$da, _changesState$data3, _changesState$data4, _businessPaymethod$da2, _changesState$data_sa, _changesState$data_sa2, _businessPaymethod$da3, _changesState$data_sa3, _changesState$data_sa4, _businessPaymethod$da4, _sitesState$sites3;
|
|
41
41
|
var open = props.open,
|
|
42
42
|
onClose = props.onClose,
|
|
43
43
|
changesState = props.changesState,
|
|
@@ -80,6 +80,16 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
80
80
|
_useState8 = _slicedToArray(_useState7, 2),
|
|
81
81
|
localState = _useState8[0],
|
|
82
82
|
setLocalState = _useState8[1];
|
|
83
|
+
var filteredOptions = (_localState$sites = localState === null || localState === void 0 ? void 0 : localState.sites) !== null && _localState$sites !== void 0 ? _localState$sites : businessPaymethod === null || businessPaymethod === void 0 ? void 0 : (_businessPaymethod$si = businessPaymethod.sites) === null || _businessPaymethod$si === void 0 ? void 0 : _businessPaymethod$si.filter(function (a) {
|
|
84
|
+
var _sitesState$sites;
|
|
85
|
+
return sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$sites = sitesState.sites) === null || _sitesState$sites === void 0 ? void 0 : _sitesState$sites.find(function (b) {
|
|
86
|
+
return a.id === b.id;
|
|
87
|
+
});
|
|
88
|
+
});
|
|
89
|
+
var _useState9 = (0, _react.useState)(!(filteredOptions !== null && filteredOptions !== void 0 && filteredOptions.length)),
|
|
90
|
+
_useState10 = _slicedToArray(_useState9, 2),
|
|
91
|
+
all = _useState10[0],
|
|
92
|
+
setAll = _useState10[1];
|
|
83
93
|
var actionSidebar = function actionSidebar(value) {
|
|
84
94
|
if (!value) {
|
|
85
95
|
props.onClose();
|
|
@@ -87,15 +97,24 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
87
97
|
setIsMenuOpen(value);
|
|
88
98
|
};
|
|
89
99
|
var setPaymethodInfo = function setPaymethodInfo(values) {
|
|
90
|
-
var _ref, _changesState$values$, _businessPaymethod$va;
|
|
91
100
|
var data = {};
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
101
|
+
if ((values === null || values === void 0 ? void 0 : values.value) === 'All') {
|
|
102
|
+
data[values.key] = [];
|
|
103
|
+
setAll(!all);
|
|
104
|
+
} else {
|
|
105
|
+
var _ref, _changesState$values$, _businessPaymethod$va;
|
|
106
|
+
var array = (_ref = (_changesState$values$ = changesState === null || changesState === void 0 ? void 0 : changesState[values.key]) !== null && _changesState$values$ !== void 0 ? _changesState$values$ : values.key === 'allowed_order_types' ? businessPaymethod === null || businessPaymethod === void 0 ? void 0 : businessPaymethod[values.key] : businessPaymethod === null || businessPaymethod === void 0 ? void 0 : (_businessPaymethod$va = businessPaymethod[values.key]) === null || _businessPaymethod$va === void 0 ? void 0 : _businessPaymethod$va.map(function (i) {
|
|
107
|
+
return i.id;
|
|
108
|
+
})) !== null && _ref !== void 0 ? _ref : [];
|
|
109
|
+
array = _toConsumableArray(new Set(array.includes(values.value) ? array.filter(function (item) {
|
|
110
|
+
return item !== values.value;
|
|
111
|
+
}) : [].concat(_toConsumableArray(array), [values.value])));
|
|
112
|
+
data[values.key] = array.length > 0 ? array : [];
|
|
113
|
+
if (values.key === 'sites') {
|
|
114
|
+
var _data$sites;
|
|
115
|
+
setAll(!(data !== null && data !== void 0 && (_data$sites = data.sites) !== null && _data$sites !== void 0 && _data$sites.length));
|
|
116
|
+
}
|
|
117
|
+
}
|
|
99
118
|
handleChangeBusinessPaymentState(data);
|
|
100
119
|
};
|
|
101
120
|
var onClickDeletePaymethod = function onClickDeletePaymethod() {
|
|
@@ -138,16 +157,10 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
138
157
|
cleanChangesState(initState);
|
|
139
158
|
}, []);
|
|
140
159
|
(0, _react.useEffect)(function () {
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
}
|
|
146
|
-
if (changesState !== null && changesState !== void 0 && changesState.sites) {
|
|
147
|
-
setLocalState({
|
|
148
|
-
sites: changesState === null || changesState === void 0 ? void 0 : changesState.sites
|
|
149
|
-
});
|
|
150
|
-
}
|
|
160
|
+
var changes = {};
|
|
161
|
+
if (changesState !== null && changesState !== void 0 && changesState.allowed_order_types) changes.allowed_order_types = changesState === null || changesState === void 0 ? void 0 : changesState.allowed_order_types;
|
|
162
|
+
if (changesState !== null && changesState !== void 0 && changesState.sites) changes.sites = changesState === null || changesState === void 0 ? void 0 : changesState.sites;
|
|
163
|
+
if (Object.keys(changes).length > 0) setLocalState(JSON.parse(JSON.stringify(changes)));
|
|
151
164
|
}, [changesState === null || changesState === void 0 ? void 0 : changesState.sites, changesState === null || changesState === void 0 ? void 0 : changesState.allowed_order_types]);
|
|
152
165
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_styles2.Container, {
|
|
153
166
|
id: "paypal"
|
|
@@ -169,7 +182,7 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
169
182
|
onClick: function onClick() {
|
|
170
183
|
return setPaymentTabs(0);
|
|
171
184
|
}
|
|
172
|
-
}, t('GENERAL', 'General')), (sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$
|
|
185
|
+
}, t('GENERAL', 'General')), (sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$sites2 = sitesState.sites) === null || _sitesState$sites2 === void 0 ? void 0 : _sitesState$sites2.length) > 0 && /*#__PURE__*/_react.default.createElement(_styles3.Tab, {
|
|
173
186
|
active: paymentTabs === 1,
|
|
174
187
|
onClick: function onClick() {
|
|
175
188
|
return setPaymentTabs(1);
|
|
@@ -212,8 +225,18 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
212
225
|
onChange: function onChange(e) {
|
|
213
226
|
return handleChangeInput(e, true);
|
|
214
227
|
}
|
|
215
|
-
})), paymentTabs === 1 && (sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$
|
|
216
|
-
|
|
228
|
+
})), paymentTabs === 1 && (sitesState === null || sitesState === void 0 ? void 0 : (_sitesState$sites3 = sitesState.sites) === null || _sitesState$sites3 === void 0 ? void 0 : _sitesState$sites3.length) > 0 && /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
229
|
+
key: "all",
|
|
230
|
+
onClick: function onClick() {
|
|
231
|
+
return setPaymethodInfo({
|
|
232
|
+
key: 'sites',
|
|
233
|
+
value: 'All'
|
|
234
|
+
});
|
|
235
|
+
}
|
|
236
|
+
}, all ? /*#__PURE__*/_react.default.createElement(_RiCheckboxFill.default, {
|
|
237
|
+
className: "fill"
|
|
238
|
+
}) : /*#__PURE__*/_react.default.createElement(_RiCheckboxBlankLine.default, null), /*#__PURE__*/_react.default.createElement(_styles4.TabOptionName, null, t('ALL', 'All'))), !all && (sitesState === null || sitesState === void 0 ? void 0 : sitesState.sites.map(function (site) {
|
|
239
|
+
var _ref2, _localState$sites2, _businessPaymethod$si2;
|
|
217
240
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
218
241
|
key: site.id,
|
|
219
242
|
onClick: function onClick() {
|
|
@@ -222,12 +245,12 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
222
245
|
value: site.id
|
|
223
246
|
});
|
|
224
247
|
}
|
|
225
|
-
}, (_ref2 = (_localState$
|
|
248
|
+
}, (_ref2 = (_localState$sites2 = localState === null || localState === void 0 ? void 0 : localState.sites) !== null && _localState$sites2 !== void 0 ? _localState$sites2 : businessPaymethod === null || businessPaymethod === void 0 ? void 0 : (_businessPaymethod$si2 = businessPaymethod.sites) === null || _businessPaymethod$si2 === void 0 ? void 0 : _businessPaymethod$si2.map(function (s) {
|
|
226
249
|
return s.id;
|
|
227
250
|
})) !== null && _ref2 !== void 0 && _ref2.includes(site.id) ? /*#__PURE__*/_react.default.createElement(_RiCheckboxFill.default, {
|
|
228
251
|
className: "fill"
|
|
229
252
|
}) : /*#__PURE__*/_react.default.createElement(_RiCheckboxBlankLine.default, null), /*#__PURE__*/_react.default.createElement(_styles4.TabOptionName, null, site.name));
|
|
230
|
-
})), paymentTabs === 2 && orderTypes.map(function (type) {
|
|
253
|
+
}))), paymentTabs === 2 && orderTypes.map(function (type) {
|
|
231
254
|
var _ref3, _localState$allowed_o;
|
|
232
255
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
233
256
|
key: type.value,
|