ordering-ui-admin-external 1.14.3 → 1.15.1
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.e2a58dcc95d6a983dfc0.js → ordering-ui-admin.7c0f4e22698e5dbd9b25.js} +2 -2
- package/_modules/components/BusinessIntelligence/BusinessReviewDetails/index.js +5 -5
- package/_modules/components/BusinessIntelligence/BusinessReviewList/index.js +29 -4
- package/_modules/components/BusinessIntelligence/InvoiceBusinessManager/index.js +16 -1
- package/_modules/components/BusinessIntelligence/InvoiceDriverManager/index.js +16 -1
- package/_modules/components/BusinessIntelligence/InvoiceManager/index.js +14 -1
- package/_modules/components/BusinessIntelligence/InvoiceOrdertype/styles.js +1 -1
- package/_modules/components/BusinessIntelligence/ProductReviewDetails/index.js +4 -3
- package/_modules/components/BusinessIntelligence/Reports/index.js +14 -1
- package/_modules/components/BusinessIntelligence/ReviewProductsListing/index.js +52 -16
- package/_modules/components/BusinessIntelligence/ReviewsListing/index.js +32 -4
- package/_modules/components/BusinessIntelligence/UserReviewDetails/index.js +4 -3
- package/_modules/components/BusinessIntelligence/UsersReviewList/index.js +35 -10
- package/_modules/components/CartRecovery/RecoveryActionDetail/index.js +21 -2
- package/_modules/components/CartRecovery/RecoveryActionListing/index.js +22 -2
- package/_modules/components/Delivery/DeliveryUsersListing/index.js +2 -0
- package/_modules/components/Delivery/DriversCompaniesListing/index.js +36 -13
- package/_modules/components/Delivery/DriversCompanyDetailsForm/index.js +31 -6
- package/_modules/components/Delivery/DriversGroupDetails/index.js +29 -2
- package/_modules/components/Delivery/DriversGroupLogistics/index.js +16 -2
- package/_modules/components/Delivery/DriversGroupsListing/index.js +28 -11
- package/_modules/components/Delivery/UserDetails/index.js +24 -1
- package/_modules/components/Loyalty/GiftCardDetail/styles.js +68 -0
- package/_modules/components/Loyalty/GiftCards/index.js +23 -2
- package/_modules/components/Loyalty/PointsWalletBusinessList/index.js +26 -1
- package/_modules/components/Loyalty/PointsWalletLevels/index.js +22 -1
- package/_modules/components/Loyalty/RewardsPrograms/index.js +34 -4
- package/_modules/components/Loyalty/Wallet/index.js +20 -1
- package/_modules/components/Marketing/AdBannersListing/index.js +24 -5
- package/_modules/components/Marketing/BannerImageDetails/index.js +2 -1
- package/_modules/components/Marketing/CampaignDetail/index.js +19 -1
- package/_modules/components/Marketing/CampaignEmail/styles.js +5 -3
- package/_modules/components/Marketing/CampaignListing/index.js +19 -0
- package/_modules/components/Marketing/CampaignNotification/styles.js +5 -3
- package/_modules/components/Marketing/CampaignSMS/styles.js +5 -3
- package/_modules/components/Marketing/EnterprisePromotionGeneralDetails/index.js +2 -1
- package/_modules/components/Marketing/EnterprisePromotionListing/index.js +24 -4
- package/_modules/components/Marketing/PageBanner/index.js +27 -3
- package/_modules/components/Messages/MessagesListing/index.js +18 -1
- package/_modules/components/MyProducts/AdvancedSettings/FontStyleGroup.js +85 -0
- package/_modules/components/MyProducts/AdvancedSettings/OrderType.js +45 -0
- package/_modules/components/MyProducts/AdvancedSettings/SettingComponent.js +91 -0
- package/_modules/components/MyProducts/AdvancedSettings/index.js +626 -0
- package/_modules/components/MyProducts/AdvancedSettings/styles.js +146 -0
- package/_modules/components/MyProducts/AppLayout/index.js +9 -1
- package/_modules/components/MyProducts/AppLayout/styles.js +20 -3
- package/_modules/components/MyProducts/CallCenterApp/index.js +1 -1
- package/_modules/components/MyProducts/CustomerApp/index.js +2 -2
- package/_modules/components/MyProducts/DriverApp/index.js +2 -2
- package/_modules/components/MyProducts/KioskApp/index.js +1 -1
- package/_modules/components/MyProducts/OrderingWebsite/index.js +37 -6
- package/_modules/components/MyProducts/OrderingWebsite/styles.js +39 -5
- package/_modules/components/MyProducts/PosApp/index.js +1 -1
- package/_modules/components/MyProducts/StoreApp/index.js +2 -2
- package/_modules/components/OrderingProducts/OrderingProductDetails/index.js +21 -1
- package/_modules/components/OrderingProducts/OrderingProductsListing/index.js +18 -1
- package/_modules/components/Orders/DeliveriesManager/index.js +0 -1
- package/_modules/components/Orders/Messages/index.js +32 -29
- package/_modules/components/Orders/OrderDetails/index.js +38 -22
- package/_modules/components/Orders/OrderDetailsHeader/index.js +2 -3
- package/_modules/components/Orders/OrdersContentHeader/index.js +2 -2
- package/_modules/components/Orders/OrdersFilterGroup/index.js +112 -9
- package/_modules/components/Orders/OrdersFilterGroup/styles.js +11 -3
- package/_modules/components/Orders/OrdersManager/index.js +0 -1
- package/_modules/components/Settings/CountriesList/index.js +27 -4
- package/_modules/components/Settings/Deliverect/index.js +23 -2
- package/_modules/components/Settings/DoordashConnect/index.js +23 -2
- package/_modules/components/Settings/DropdownOptionList/index.js +27 -4
- package/_modules/components/Settings/IntegrationListing/index.js +3 -3
- package/_modules/components/Settings/ItsaCheckmate/index.js +23 -2
- package/_modules/components/Settings/LalamoveConnect/index.js +23 -2
- package/_modules/components/Settings/PickerExpress/index.js +23 -2
- package/_modules/components/Settings/PlaceListing/index.js +40 -4
- package/_modules/components/Settings/Settings/index.js +86 -45
- package/_modules/components/Settings/SettingsDetail/index.js +14 -1
- package/_modules/components/Settings/SitesAuthSettings/index.js +17 -1
- package/_modules/components/SidebarMenu/index.js +0 -1
- package/_modules/components/Stores/BusinessAdd/BusinessDetails/index.js +4 -9
- package/_modules/components/Stores/BusinessAdd/BusinessDetails/styles.js +3 -1
- package/_modules/components/Stores/BusinessAdd/DeliveryZone/index.js +13 -4
- package/_modules/components/Stores/BusinessAdd/DeliveryZone/styles.js +16 -10
- package/_modules/components/Stores/BusinessAdd/PaymentMethods/index.js +11 -3
- package/_modules/components/Stores/BusinessAdd/PaymentMethods/styles.js +3 -1
- package/_modules/components/Stores/BusinessAdd/ReceiveOrders/index.js +17 -6
- package/_modules/components/Stores/BusinessAdd/ReceiveOrders/styles.js +3 -1
- package/_modules/components/Stores/BusinessAdd/index.js +38 -8
- package/_modules/components/Stores/BusinessAdd/styles.js +8 -4
- package/_modules/components/Stores/BusinessAddStore/index.js +1 -1
- package/_modules/components/Stores/BusinessBrandListing/index.js +37 -4
- package/_modules/components/Stores/BusinessDeliveryPickupMore/index.js +20 -1
- package/_modules/components/Stores/BusinessDeliveryZoneDetails/index.js +22 -1
- package/_modules/components/Stores/BusinessDeliveryZoneList/index.js +32 -4
- package/_modules/components/Stores/BusinessDetail/index.js +18 -1
- package/_modules/components/Stores/BusinessDetails/index.js +17 -1
- package/_modules/components/Stores/BusinessFrontLayout/index.js +8 -1
- package/_modules/components/Stores/BusinessFrontLayout/styles.js +5 -3
- package/_modules/components/Stores/BusinessMenu/index.js +58 -7
- package/_modules/components/Stores/BusinessMenuOptions/index.js +24 -3
- package/_modules/components/Stores/BusinessOrderingChannels/index.js +18 -2
- package/_modules/components/Stores/BusinessPaymentMethods/index.js +26 -2
- package/_modules/components/Stores/BusinessPlaceGroupList/index.js +183 -0
- package/_modules/components/Stores/BusinessPlaceGroupList/styles.js +66 -0
- package/_modules/components/Stores/BusinessProductsCategoyDetails/index.js +21 -1
- package/_modules/components/Stores/BusinessProductsListing/index.js +74 -22
- package/_modules/components/Stores/BusinessPromotionGeneralForm/index.js +2 -2
- package/_modules/components/Stores/BusinessSharedMenuProducts/index.js +29 -2
- package/_modules/components/Stores/BusinessSync/index.js +16 -1
- package/_modules/components/Stores/BusinessTypes/index.js +27 -4
- package/_modules/components/Stores/BusinessWalletsList/index.js +24 -1
- package/_modules/components/Stores/BusinessesListing/index.js +9 -1
- package/_modules/components/Stores/ImportersButton/index.js +19 -6
- package/_modules/components/Stores/PaymentOption/index.js +29 -9
- package/_modules/components/Stores/PaymentOptionMethods/index.js +23 -3
- package/_modules/components/Stores/PaymentOptionPaypal/index.js +23 -3
- package/_modules/components/Stores/PaymentOptionSquare/index.js +23 -3
- package/_modules/components/Stores/PaymentOptionStripeDirect/index.js +23 -3
- package/_modules/components/Stores/PaymethodOptionPaypalExpress/index.js +23 -3
- package/_modules/components/Stores/PaymethodOptionStripeConnect/index.js +23 -3
- package/_modules/components/Stores/PaymethodOptionStripeRedirect/index.js +23 -3
- package/_modules/components/Stores/ProductDetails/index.js +18 -1
- package/_modules/components/Stores/ProductExtras/index.js +25 -2
- package/_modules/components/Stores/ProductIngredient/index.js +23 -1
- package/_modules/components/Stores/ProductMainDetails/index.js +18 -1
- package/_modules/components/Stores/ProductTagsList/index.js +28 -2
- package/_modules/components/Users/CustomerCashWallet/index.js +22 -2
- package/_modules/components/Users/CustomerDetails/index.js +19 -1
- package/_modules/components/Users/CustomerPointsWallet/index.js +22 -2
- package/_modules/components/Users/CustomersListing/index.js +8 -3
- package/_modules/components/Users/ProfessionalDetail/index.js +25 -1
- package/_modules/components/Users/ProfessionalListing/index.js +8 -3
- package/_modules/components/Users/UserActiveStateFilter/index.js +18 -4
- package/_modules/components/Users/UserDetails/index.js +27 -1
- package/_modules/components/Users/UsersListing/index.js +8 -3
- package/package.json +2 -2
- package/src/components/BusinessIntelligence/BusinessReviewDetails/index.js +4 -4
- package/src/components/BusinessIntelligence/BusinessReviewList/index.js +29 -6
- package/src/components/BusinessIntelligence/InvoiceBusinessManager/index.js +17 -1
- package/src/components/BusinessIntelligence/InvoiceDriverManager/index.js +17 -1
- package/src/components/BusinessIntelligence/InvoiceManager/index.js +16 -2
- package/src/components/BusinessIntelligence/InvoiceOrdertype/styles.js +1 -0
- package/src/components/BusinessIntelligence/ProductReviewDetails/index.js +4 -4
- package/src/components/BusinessIntelligence/Reports/index.js +16 -2
- package/src/components/BusinessIntelligence/ReviewProductsListing/index.js +34 -6
- package/src/components/BusinessIntelligence/ReviewsListing/index.js +31 -5
- package/src/components/BusinessIntelligence/UserReviewDetails/index.js +4 -4
- package/src/components/BusinessIntelligence/UsersReviewList/index.js +32 -11
- package/src/components/CartRecovery/RecoveryActionDetail/index.js +19 -1
- package/src/components/CartRecovery/RecoveryActionListing/index.js +21 -3
- package/src/components/Delivery/DeliveryUsersListing/index.js +3 -1
- package/src/components/Delivery/DriversCompaniesListing/index.js +27 -9
- package/src/components/Delivery/DriversCompanyDetailsForm/index.js +37 -8
- package/src/components/Delivery/DriversGroupDetails/index.js +36 -4
- package/src/components/Delivery/DriversGroupLogistics/index.js +18 -2
- package/src/components/Delivery/DriversGroupsListing/index.js +20 -6
- package/src/components/Delivery/UserDetails/index.js +26 -1
- package/src/components/Loyalty/GiftCardDetail/styles.js +192 -0
- package/src/components/Loyalty/GiftCards/index.js +22 -2
- package/src/components/Loyalty/PointsWalletBusinessList/index.js +24 -1
- package/src/components/Loyalty/PointsWalletLevels/index.js +21 -1
- package/src/components/Loyalty/RewardsPrograms/index.js +30 -3
- package/src/components/Loyalty/Wallet/index.js +22 -1
- package/src/components/Marketing/AdBannersListing/index.js +25 -8
- package/src/components/Marketing/BannerImageDetails/index.js +2 -1
- package/src/components/Marketing/CampaignDetail/index.js +22 -1
- package/src/components/Marketing/CampaignEmail/styles.js +3 -0
- package/src/components/Marketing/CampaignListing/index.js +18 -1
- package/src/components/Marketing/CampaignNotification/styles.js +3 -0
- package/src/components/Marketing/CampaignSMS/styles.js +3 -0
- package/src/components/Marketing/EnterprisePromotionGeneralDetails/index.js +2 -1
- package/src/components/Marketing/EnterprisePromotionListing/index.js +19 -1
- package/src/components/Marketing/PageBanner/index.js +26 -3
- package/src/components/Messages/MessagesListing/index.js +17 -0
- package/src/components/MyProducts/AdvancedSettings/FontStyleGroup.js +64 -0
- package/src/components/MyProducts/AdvancedSettings/OrderType.js +40 -0
- package/src/components/MyProducts/AdvancedSettings/SettingComponent.js +104 -0
- package/src/components/MyProducts/AdvancedSettings/index.js +541 -0
- package/src/components/MyProducts/AdvancedSettings/styles.js +388 -0
- package/src/components/MyProducts/AppLayout/index.js +19 -2
- package/src/components/MyProducts/AppLayout/styles.js +65 -0
- package/src/components/MyProducts/CallCenterApp/index.js +1 -1
- package/src/components/MyProducts/CustomerApp/index.js +2 -2
- package/src/components/MyProducts/DriverApp/index.js +2 -2
- package/src/components/MyProducts/KioskApp/index.js +1 -1
- package/src/components/MyProducts/OrderingWebsite/index.js +309 -255
- package/src/components/MyProducts/OrderingWebsite/styles.js +99 -2
- package/src/components/MyProducts/PosApp/index.js +1 -1
- package/src/components/MyProducts/StoreApp/index.js +2 -2
- package/src/components/OrderingProducts/OrderingProductDetails/index.js +24 -2
- package/src/components/OrderingProducts/OrderingProductsListing/index.js +17 -1
- package/src/components/Orders/DeliveriesManager/index.js +0 -1
- package/src/components/Orders/Messages/index.js +31 -11
- package/src/components/Orders/OrderDetails/index.js +34 -20
- package/src/components/Orders/OrderDetailsHeader/index.js +2 -3
- package/src/components/Orders/OrdersContentHeader/index.js +1 -1
- package/src/components/Orders/OrdersFilterGroup/index.js +111 -13
- package/src/components/Orders/OrdersFilterGroup/styles.js +26 -0
- package/src/components/Orders/OrdersManager/index.js +0 -1
- package/src/components/Settings/CountriesList/index.js +26 -6
- package/src/components/Settings/Deliverect/index.js +26 -2
- package/src/components/Settings/DoordashConnect/index.js +26 -2
- package/src/components/Settings/DropdownOptionList/index.js +27 -6
- package/src/components/Settings/IntegrationListing/index.js +3 -3
- package/src/components/Settings/ItsaCheckmate/index.js +26 -2
- package/src/components/Settings/LalamoveConnect/index.js +26 -2
- package/src/components/Settings/PickerExpress/index.js +26 -2
- package/src/components/Settings/PlaceListing/index.js +38 -6
- package/src/components/Settings/Settings/index.js +79 -37
- package/src/components/Settings/SettingsDetail/index.js +15 -1
- package/src/components/Settings/SitesAuthSettings/index.js +18 -1
- package/src/components/SidebarMenu/index.js +0 -2
- package/src/components/Stores/BusinessAdd/BusinessDetails/index.js +1 -10
- package/src/components/Stores/BusinessAdd/BusinessDetails/styles.js +4 -0
- package/src/components/Stores/BusinessAdd/DeliveryZone/index.js +120 -109
- package/src/components/Stores/BusinessAdd/DeliveryZone/styles.js +22 -1
- package/src/components/Stores/BusinessAdd/PaymentMethods/index.js +8 -2
- package/src/components/Stores/BusinessAdd/PaymentMethods/styles.js +4 -0
- package/src/components/Stores/BusinessAdd/ReceiveOrders/index.js +11 -6
- package/src/components/Stores/BusinessAdd/ReceiveOrders/styles.js +4 -0
- package/src/components/Stores/BusinessAdd/index.js +47 -16
- package/src/components/Stores/BusinessAdd/styles.js +27 -1
- package/src/components/Stores/BusinessAddStore/index.js +1 -1
- package/src/components/Stores/BusinessBrandListing/index.js +37 -4
- package/src/components/Stores/BusinessDeliveryPickupMore/index.js +22 -1
- package/src/components/Stores/BusinessDeliveryZoneDetails/index.js +25 -2
- package/src/components/Stores/BusinessDeliveryZoneList/index.js +30 -3
- package/src/components/Stores/BusinessDetail/index.js +20 -1
- package/src/components/Stores/BusinessDetails/index.js +18 -1
- package/src/components/Stores/BusinessFrontLayout/index.js +13 -1
- package/src/components/Stores/BusinessFrontLayout/styles.js +11 -0
- package/src/components/Stores/BusinessMenu/index.js +56 -11
- package/src/components/Stores/BusinessMenuOptions/index.js +28 -3
- package/src/components/Stores/BusinessOrderingChannels/index.js +19 -2
- package/src/components/Stores/BusinessPaymentMethods/index.js +24 -2
- package/src/components/Stores/BusinessPlaceGroupList/index.js +193 -0
- package/src/components/Stores/BusinessPlaceGroupList/styles.js +143 -0
- package/src/components/Stores/BusinessProductsCategoyDetails/index.js +21 -1
- package/src/components/Stores/BusinessProductsListing/index.js +49 -8
- package/src/components/Stores/BusinessPromotionGeneralForm/index.js +2 -2
- package/src/components/Stores/BusinessSharedMenuProducts/index.js +29 -3
- package/src/components/Stores/BusinessSync/index.js +18 -2
- package/src/components/Stores/BusinessTypes/index.js +26 -4
- package/src/components/Stores/BusinessWalletsList/index.js +23 -1
- package/src/components/Stores/BusinessesListing/index.js +11 -2
- package/src/components/Stores/ImportersButton/index.js +24 -3
- package/src/components/Stores/PaymentOption/index.js +29 -8
- package/src/components/Stores/PaymentOptionMethods/index.js +25 -3
- package/src/components/Stores/PaymentOptionPaypal/index.js +25 -3
- package/src/components/Stores/PaymentOptionSquare/index.js +25 -3
- package/src/components/Stores/PaymentOptionStripeDirect/index.js +25 -3
- package/src/components/Stores/PaymethodOptionPaypalExpress/index.js +25 -3
- package/src/components/Stores/PaymethodOptionStripeConnect/index.js +25 -3
- package/src/components/Stores/PaymethodOptionStripeRedirect/index.js +25 -3
- package/src/components/Stores/ProductDetails/index.js +19 -1
- package/src/components/Stores/ProductExtras/index.js +23 -2
- package/src/components/Stores/ProductIngredient/index.js +23 -2
- package/src/components/Stores/ProductMainDetails/index.js +20 -2
- package/src/components/Stores/ProductTagsList/index.js +28 -3
- package/src/components/Users/CustomerCashWallet/index.js +25 -3
- package/src/components/Users/CustomerDetails/index.js +20 -1
- package/src/components/Users/CustomerPointsWallet/index.js +25 -3
- package/src/components/Users/CustomersListing/index.js +9 -4
- package/src/components/Users/ProfessionalDetail/index.js +27 -1
- package/src/components/Users/ProfessionalListing/index.js +9 -4
- package/src/components/Users/UserActiveStateFilter/index.js +16 -3
- package/src/components/Users/UserDetails/index.js +27 -1
- package/src/components/Users/UsersListing/index.js +9 -4
- package/template/pages/BusinessProductsList/index.js +1 -1
- /package/_bundles/{ordering-ui-admin.e2a58dcc95d6a983dfc0.js.LICENSE.txt → ordering-ui-admin.7c0f4e22698e5dbd9b25.js.LICENSE.txt} +0 -0
|
@@ -1,22 +1,26 @@
|
|
|
1
|
-
import React from 'react'
|
|
1
|
+
import React, { useState, useEffect, useRef } from 'react'
|
|
2
|
+
import { PlusCircle, Trash3 } from 'react-bootstrap-icons'
|
|
2
3
|
import { useLanguage, OrdersFilter as OrdersFilterController } from 'ordering-components-admin-external'
|
|
3
4
|
import { BusinessesSelector } from '../BusinessesSelector'
|
|
4
5
|
import { DriversGroupTypeSelector } from '../DriversGroupTypeSelector'
|
|
5
6
|
import { DateTypeSelector } from '../DateTypeSelector'
|
|
6
7
|
import { DriverSelector } from '../DriverSelector'
|
|
7
8
|
import { CitySelector, Modal } from '../../Shared'
|
|
8
|
-
import { OrderStatusTypeSelector } from '../OrderStatusTypeSelector'
|
|
9
|
+
// import { OrderStatusTypeSelector } from '../OrderStatusTypeSelector'
|
|
9
10
|
import { DeliveryTypeSelector } from '../DeliveryTypeSelector'
|
|
10
11
|
import { PaymethodTypeSelector } from '../PaymethodTypeSelector'
|
|
11
12
|
import { CountryFilter } from '../CountryFilter'
|
|
12
|
-
import { Button, Input } from '../../../styles'
|
|
13
|
+
import { Button, IconButton, Input } from '../../../styles'
|
|
13
14
|
import { CurrencyFilter } from '../CurrencyFilter'
|
|
15
|
+
import { getUniqueId } from '../../../utils'
|
|
14
16
|
|
|
15
17
|
import {
|
|
16
18
|
FilterGroupListContainer,
|
|
17
19
|
WrapperRow,
|
|
18
|
-
MultiSelectContainer,
|
|
19
|
-
ButtonGroup
|
|
20
|
+
// MultiSelectContainer,
|
|
21
|
+
ButtonGroup,
|
|
22
|
+
AddInputWrapper,
|
|
23
|
+
AddMetaFiled
|
|
20
24
|
} from './styles'
|
|
21
25
|
|
|
22
26
|
const OrdersFilterGroupUI = (props) => {
|
|
@@ -36,17 +40,23 @@ const OrdersFilterGroupUI = (props) => {
|
|
|
36
40
|
handleChangeBusinesses,
|
|
37
41
|
handleChangeDriver,
|
|
38
42
|
handleChangeCity,
|
|
39
|
-
handleChangeOrderStatus,
|
|
43
|
+
// handleChangeOrderStatus,
|
|
40
44
|
handleChangeDeliveryType,
|
|
41
45
|
handleChangePaymethodType,
|
|
42
46
|
handleResetFilterValues,
|
|
43
47
|
handleChangeFilterValues,
|
|
44
48
|
handleChangeOrderId,
|
|
45
49
|
handleChangeCountryCode,
|
|
46
|
-
handleChangeCurrency
|
|
50
|
+
handleChangeCurrency,
|
|
51
|
+
handleChangeMetaFieldValue,
|
|
52
|
+
handleAddMetaField,
|
|
53
|
+
handleDeleteMetafield
|
|
47
54
|
} = props
|
|
48
55
|
|
|
49
56
|
const [, t] = useLanguage()
|
|
57
|
+
const [metafield, setMetaField] = useState({ key: '', value: '' })
|
|
58
|
+
const [isShow, setIsShow] = useState(false)
|
|
59
|
+
const metafieldRef = useRef()
|
|
50
60
|
|
|
51
61
|
const handleAcceptFilter = () => {
|
|
52
62
|
handleChangeFilterValues(filterValues)
|
|
@@ -58,6 +68,33 @@ const OrdersFilterGroupUI = (props) => {
|
|
|
58
68
|
// handleChangeFilterValues({})
|
|
59
69
|
}
|
|
60
70
|
|
|
71
|
+
const handleAddMetafieldValue = () => {
|
|
72
|
+
handleAddMetaField({
|
|
73
|
+
id: getUniqueId(),
|
|
74
|
+
key: metafield?.key,
|
|
75
|
+
value: metafield?.value
|
|
76
|
+
})
|
|
77
|
+
setMetaField({ key: '', value: '' })
|
|
78
|
+
setIsShow(false)
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
const handleDeleteMetafieldValue = (id) => {
|
|
82
|
+
handleDeleteMetafield(id)
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
const handleClickOutside = (e) => {
|
|
86
|
+
if (!isShow) return
|
|
87
|
+
const outsideCalendar = !metafieldRef.current?.contains(e.target)
|
|
88
|
+
if (outsideCalendar) {
|
|
89
|
+
setIsShow(false)
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
useEffect(() => {
|
|
94
|
+
window.addEventListener('mouseup', handleClickOutside)
|
|
95
|
+
return () => window.removeEventListener('mouseup', handleClickOutside)
|
|
96
|
+
}, [isShow])
|
|
97
|
+
|
|
61
98
|
return (
|
|
62
99
|
<Modal
|
|
63
100
|
width='80%'
|
|
@@ -75,6 +112,10 @@ const OrdersFilterGroupUI = (props) => {
|
|
|
75
112
|
value={filterValues?.orderId || ''}
|
|
76
113
|
onChange={(e) => handleChangeOrderId(e)}
|
|
77
114
|
/>
|
|
115
|
+
<CurrencyFilter
|
|
116
|
+
filterValues={filterValues}
|
|
117
|
+
handleChangeCurrency={handleChangeCurrency}
|
|
118
|
+
/>
|
|
78
119
|
</WrapperRow>
|
|
79
120
|
<WrapperRow>
|
|
80
121
|
<DriversGroupTypeSelector
|
|
@@ -131,12 +172,69 @@ const OrdersFilterGroupUI = (props) => {
|
|
|
131
172
|
handleChangePaymethodType={handleChangePaymethodType}
|
|
132
173
|
/>
|
|
133
174
|
</WrapperRow>
|
|
134
|
-
|
|
135
|
-
<
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
175
|
+
{filterValues?.metafield.map(item => (
|
|
176
|
+
<WrapperRow key={item.id}>
|
|
177
|
+
<Input
|
|
178
|
+
type='text'
|
|
179
|
+
name='key'
|
|
180
|
+
placeholder={t('METAFIELD_NAME', 'Metafield name')}
|
|
181
|
+
autoComplete='off'
|
|
182
|
+
value={item.key || ''}
|
|
183
|
+
onChange={(e) => handleChangeMetaFieldValue(e, item.id)}
|
|
184
|
+
/>
|
|
185
|
+
{item?.key && (
|
|
186
|
+
<AddInputWrapper>
|
|
187
|
+
<Input
|
|
188
|
+
type='text'
|
|
189
|
+
name='value'
|
|
190
|
+
placeholder={t('METAFIELD_VALUE', 'Metafield value')}
|
|
191
|
+
autoComplete='off'
|
|
192
|
+
value={item?.value || ''}
|
|
193
|
+
onChange={(e) => handleChangeMetaFieldValue(e, item.id)}
|
|
194
|
+
/>
|
|
195
|
+
<IconButton
|
|
196
|
+
color='black'
|
|
197
|
+
onClick={() => handleDeleteMetafieldValue(item.id)}
|
|
198
|
+
>
|
|
199
|
+
<Trash3 />
|
|
200
|
+
</IconButton>
|
|
201
|
+
</AddInputWrapper>
|
|
202
|
+
)}
|
|
203
|
+
</WrapperRow>
|
|
204
|
+
))}
|
|
205
|
+
{!isShow && (
|
|
206
|
+
<AddMetaFiled onClick={() => setIsShow(true)}>{t('ADD_METAFIELD', 'Add a metafield')}</AddMetaFiled>
|
|
207
|
+
)}
|
|
208
|
+
{isShow && (
|
|
209
|
+
<WrapperRow ref={metafieldRef}>
|
|
210
|
+
<Input
|
|
211
|
+
type='text'
|
|
212
|
+
name='key'
|
|
213
|
+
placeholder={t('METAFIELD_NAME', 'Metafield name')}
|
|
214
|
+
autoComplete='off'
|
|
215
|
+
value={metafield.key || ''}
|
|
216
|
+
onChange={(e) => setMetaField({ ...metafield, key: e.target.value })}
|
|
217
|
+
/>
|
|
218
|
+
{metafield?.key && (
|
|
219
|
+
<AddInputWrapper>
|
|
220
|
+
<Input
|
|
221
|
+
type='text'
|
|
222
|
+
name='value'
|
|
223
|
+
placeholder={t('METAFIELD_VALUE', 'Metafield value')}
|
|
224
|
+
autoComplete='off'
|
|
225
|
+
value={metafield.value || ''}
|
|
226
|
+
onChange={(e) => setMetaField({ ...metafield, value: e.target.value })}
|
|
227
|
+
/>
|
|
228
|
+
<IconButton
|
|
229
|
+
color='primary'
|
|
230
|
+
onClick={handleAddMetafieldValue}
|
|
231
|
+
>
|
|
232
|
+
<PlusCircle />
|
|
233
|
+
</IconButton>
|
|
234
|
+
</AddInputWrapper>
|
|
235
|
+
)}
|
|
236
|
+
</WrapperRow>
|
|
237
|
+
)}
|
|
140
238
|
<ButtonGroup>
|
|
141
239
|
<Button
|
|
142
240
|
color='primary'
|
|
@@ -123,3 +123,29 @@ export const ButtonGroup = styled.div`
|
|
|
123
123
|
}
|
|
124
124
|
}
|
|
125
125
|
`
|
|
126
|
+
|
|
127
|
+
export const AddInputWrapper = styled.div`
|
|
128
|
+
display: flex;
|
|
129
|
+
align-items: center;
|
|
130
|
+
background-color: transparent !important;
|
|
131
|
+
input {
|
|
132
|
+
flex: 1;
|
|
133
|
+
height: 57px;
|
|
134
|
+
}
|
|
135
|
+
button {
|
|
136
|
+
width: 30px;
|
|
137
|
+
height: 30px;
|
|
138
|
+
margin-left: 10px;
|
|
139
|
+
${props => props.theme.rtl && css`
|
|
140
|
+
margin-right: 10px;
|
|
141
|
+
margin-left: 0;
|
|
142
|
+
`}
|
|
143
|
+
}
|
|
144
|
+
`
|
|
145
|
+
|
|
146
|
+
export const AddMetaFiled = styled.span`
|
|
147
|
+
font-size: 14px;
|
|
148
|
+
color: ${props => props.theme.colors.primary};
|
|
149
|
+
cursor: pointer;
|
|
150
|
+
width: 100%;
|
|
151
|
+
`
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React, { useState, useEffect } from 'react'
|
|
2
|
+
import { useHistory, useLocation } from 'react-router-dom'
|
|
2
3
|
import { useLanguage } from 'ordering-components-admin-external'
|
|
3
4
|
import Skeleton from 'react-loading-skeleton'
|
|
4
5
|
import { Pagination, SideBar, Confirm } from '../../Shared'
|
|
@@ -34,6 +35,8 @@ export const CountriesList = (props) => {
|
|
|
34
35
|
handleDeleteCountry
|
|
35
36
|
} = props
|
|
36
37
|
|
|
38
|
+
const history = useHistory()
|
|
39
|
+
const query = new URLSearchParams(useLocation().search)
|
|
37
40
|
const [, t] = useLanguage()
|
|
38
41
|
const theme = useTheme()
|
|
39
42
|
const [currentPage, setCurrentPage] = useState(1)
|
|
@@ -70,11 +73,14 @@ export const CountriesList = (props) => {
|
|
|
70
73
|
setCurrentCountries(_currentDropdownOptions)
|
|
71
74
|
}, [countriesState, currentPage, countriesPerPage, searchValue])
|
|
72
75
|
|
|
73
|
-
const handleClickCountry = (e, country) => {
|
|
74
|
-
const isInvalid = e
|
|
76
|
+
const handleClickCountry = (e, country, isInitialRender) => {
|
|
77
|
+
const isInvalid = e?.target?.closest('.country-checkbox') || e?.target?.closest('.country-enabled') || e?.target?.closest('.country-actions')
|
|
75
78
|
if (isInvalid) return
|
|
76
79
|
setSelectedCountry(country)
|
|
77
80
|
setOpenDetails(true)
|
|
81
|
+
if (!isInitialRender) {
|
|
82
|
+
history.replace(`${location.pathname}?country=${country.id}`)
|
|
83
|
+
}
|
|
78
84
|
}
|
|
79
85
|
|
|
80
86
|
const onDeleteCountry = (countryId) => {
|
|
@@ -106,12 +112,29 @@ export const CountriesList = (props) => {
|
|
|
106
112
|
}
|
|
107
113
|
}
|
|
108
114
|
|
|
115
|
+
const handleCloseDetail = () => {
|
|
116
|
+
setOpenDetails(false)
|
|
117
|
+
setSelectedCountry(null)
|
|
118
|
+
history.replace(`${location.pathname}`)
|
|
119
|
+
}
|
|
120
|
+
|
|
109
121
|
useEffect(() => {
|
|
110
122
|
if (actionState.loading || actionState.error || selectedCountry) return
|
|
111
123
|
setOpenDetails(false)
|
|
112
124
|
setSelectedCountry(null)
|
|
113
125
|
}, [actionState])
|
|
114
126
|
|
|
127
|
+
useEffect(() => {
|
|
128
|
+
if (countriesState.loading) return
|
|
129
|
+
const countryId = query.get('country')
|
|
130
|
+
if (countryId) {
|
|
131
|
+
const initCountry = countriesState.countries.find(country => country.id === Number(countryId))
|
|
132
|
+
if (initCountry) {
|
|
133
|
+
handleClickCountry(null, initCountry, true)
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
}, [countriesState.loading])
|
|
137
|
+
|
|
115
138
|
return (
|
|
116
139
|
<CountriesContainer>
|
|
117
140
|
<CountryWrapper isHeader>
|
|
@@ -222,10 +245,7 @@ export const CountriesList = (props) => {
|
|
|
222
245
|
{openDetails && (
|
|
223
246
|
<SideBar
|
|
224
247
|
open={openDetails}
|
|
225
|
-
onClose={() =>
|
|
226
|
-
setOpenDetails(false)
|
|
227
|
-
setSelectedCountry(null)
|
|
228
|
-
}}
|
|
248
|
+
onClose={() => handleCloseDetail()}
|
|
229
249
|
showExpandIcon
|
|
230
250
|
>
|
|
231
251
|
<CountryDetails
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React, { useState, useEffect } from 'react'
|
|
2
|
+
import { useHistory, useLocation } from 'react-router-dom'
|
|
2
3
|
import { useLanguage } from 'ordering-components-admin-external'
|
|
3
4
|
import { Button, IconButton } from '../../../styles'
|
|
4
5
|
import { DragScroll, Modal } from '../../Shared'
|
|
@@ -26,6 +27,8 @@ export const Deliverect = (props) => {
|
|
|
26
27
|
onClose
|
|
27
28
|
} = props
|
|
28
29
|
|
|
30
|
+
const history = useHistory()
|
|
31
|
+
const query = new URLSearchParams(useLocation().search)
|
|
29
32
|
const [, t] = useLanguage()
|
|
30
33
|
const { width } = useWindowSize()
|
|
31
34
|
|
|
@@ -64,12 +67,33 @@ export const Deliverect = (props) => {
|
|
|
64
67
|
toggleMainContent()
|
|
65
68
|
}, [width])
|
|
66
69
|
|
|
70
|
+
const handleOpenMore = (isInitialRender) => {
|
|
71
|
+
setSettingsOpen(true)
|
|
72
|
+
if (!isInitialRender) {
|
|
73
|
+
const id = query.get('id')
|
|
74
|
+
history.replace(`${location.pathname}?id=${id}&more=settings`)
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
const handleCloseDescription = () => {
|
|
79
|
+
setSettingsOpen(false)
|
|
80
|
+
const id = query.get('id')
|
|
81
|
+
history.replace(`${location.pathname}?id=${id}`)
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
useEffect(() => {
|
|
85
|
+
const more = query.get('more')
|
|
86
|
+
if (more === 'settings') {
|
|
87
|
+
handleOpenMore(true)
|
|
88
|
+
}
|
|
89
|
+
}, [])
|
|
90
|
+
|
|
67
91
|
const LalaMoveConnectDescription = () => {
|
|
68
92
|
return (
|
|
69
93
|
<CategoryExtraContent>
|
|
70
94
|
<IconButton
|
|
71
95
|
color='black'
|
|
72
|
-
onClick={() =>
|
|
96
|
+
onClick={() => handleCloseDescription()}
|
|
73
97
|
>
|
|
74
98
|
<XLg />
|
|
75
99
|
</IconButton>
|
|
@@ -134,7 +158,7 @@ export const Deliverect = (props) => {
|
|
|
134
158
|
<Button color='lightPrimary'>{t('NEW', 'New')}</Button>
|
|
135
159
|
</Header>
|
|
136
160
|
<Description dangerouslySetInnerHTML={{ __html: t('SYNC_DEC_SECOND', 'Deliverect integrates all your <span>online orders</span> to your <span>existing POS</span> or our <span>Delivery Manger app.</span> Restaurants large and small rely on Deliverect to reduce failures and order mistakes while speeding up order preparation.') }} />
|
|
137
|
-
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() =>
|
|
161
|
+
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() => handleOpenMore()}>
|
|
138
162
|
<span>{t('SETTINGS', 'All settings')}</span>
|
|
139
163
|
<BsArrowRight />
|
|
140
164
|
</Button>
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React, { useState, useEffect } from 'react'
|
|
2
|
+
import { useHistory, useLocation } from 'react-router-dom'
|
|
2
3
|
import { useLanguage, ApiKeysList as ApiKeysListController } from 'ordering-components-admin-external'
|
|
3
4
|
import { Button, IconButton } from '../../../styles'
|
|
4
5
|
import { Alert, Confirm, DragScroll, Modal } from '../../Shared'
|
|
@@ -26,6 +27,8 @@ const DoordashConnectUI = (props) => {
|
|
|
26
27
|
onClose
|
|
27
28
|
} = props
|
|
28
29
|
|
|
30
|
+
const history = useHistory()
|
|
31
|
+
const query = new URLSearchParams(useLocation().search)
|
|
29
32
|
const [, t] = useLanguage()
|
|
30
33
|
const { width } = useWindowSize()
|
|
31
34
|
|
|
@@ -78,12 +81,33 @@ const DoordashConnectUI = (props) => {
|
|
|
78
81
|
toggleMainContent()
|
|
79
82
|
}, [width])
|
|
80
83
|
|
|
84
|
+
const handleOpenMore = (isInitialRender) => {
|
|
85
|
+
setSettingsOpen(true)
|
|
86
|
+
if (!isInitialRender) {
|
|
87
|
+
const id = query.get('id')
|
|
88
|
+
history.replace(`${location.pathname}?id=${id}&more=settings`)
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
const handleCloseDescription = () => {
|
|
93
|
+
setSettingsOpen(false)
|
|
94
|
+
const id = query.get('id')
|
|
95
|
+
history.replace(`${location.pathname}?id=${id}`)
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
useEffect(() => {
|
|
99
|
+
const more = query.get('more')
|
|
100
|
+
if (more === 'settings') {
|
|
101
|
+
handleOpenMore(true)
|
|
102
|
+
}
|
|
103
|
+
}, [])
|
|
104
|
+
|
|
81
105
|
const DoordashConnectDescription = () => {
|
|
82
106
|
return (
|
|
83
107
|
<CategoryExtraContent>
|
|
84
108
|
<IconButton
|
|
85
109
|
color='black'
|
|
86
|
-
onClick={() =>
|
|
110
|
+
onClick={() => handleCloseDescription()}
|
|
87
111
|
>
|
|
88
112
|
<XLg />
|
|
89
113
|
</IconButton>
|
|
@@ -179,7 +203,7 @@ const DoordashConnectUI = (props) => {
|
|
|
179
203
|
<Description>
|
|
180
204
|
{t('CONNECT_WITH_DOORDASH_DESCRIPTION', 'If you have already worked with Doordash or are running your business with Doordash and Ordering simultaneously, this integration will help you connect both platforms and assign orders through them, making your job easy and automated.')}
|
|
181
205
|
</Description>
|
|
182
|
-
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() =>
|
|
206
|
+
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() => handleOpenMore()}>
|
|
183
207
|
<span>{t('SETTINGS', 'All settings')}</span>
|
|
184
208
|
<BsArrowRight />
|
|
185
209
|
</Button>
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React, { useState, useEffect } from 'react'
|
|
2
|
+
import { useHistory, useLocation } from 'react-router-dom'
|
|
2
3
|
import { useLanguage } from 'ordering-components-admin-external'
|
|
3
4
|
import Skeleton from 'react-loading-skeleton'
|
|
4
5
|
import { Dropdown, DropdownButton } from 'react-bootstrap'
|
|
@@ -46,6 +47,8 @@ export const DropdownOptionList = (props) => {
|
|
|
46
47
|
handleAllCheckboxZoneClick
|
|
47
48
|
} = props
|
|
48
49
|
|
|
50
|
+
const history = useHistory()
|
|
51
|
+
const query = new URLSearchParams(useLocation().search)
|
|
49
52
|
const [, t] = useLanguage()
|
|
50
53
|
const theme = useTheme()
|
|
51
54
|
const [cities, setCities] = useState([])
|
|
@@ -93,10 +96,20 @@ export const DropdownOptionList = (props) => {
|
|
|
93
96
|
setCities(_cities)
|
|
94
97
|
}, [countriesState])
|
|
95
98
|
|
|
96
|
-
const handleClickZoneDropdown = (e, zone) => {
|
|
97
|
-
const isInvalid = e
|
|
99
|
+
const handleClickZoneDropdown = (e, zone, isInitialRender) => {
|
|
100
|
+
const isInvalid = e?.target?.closest('.zone-checkbox') || e?.target?.closest('.zone-enabled') || e?.target?.closest('.zone-actions')
|
|
98
101
|
if (isInvalid) return
|
|
99
102
|
handleOpenZoneDropdownDetails(zone)
|
|
103
|
+
|
|
104
|
+
if (!isInitialRender) {
|
|
105
|
+
history.replace(`${location.pathname}?zone=${zone.id}`)
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
const handleCloseZoneDetail = () => {
|
|
110
|
+
setSelectedZoneDropdown(null)
|
|
111
|
+
setOpenZonedropdown(false)
|
|
112
|
+
history.replace(`${location.pathname}`)
|
|
100
113
|
}
|
|
101
114
|
|
|
102
115
|
const onDeleteZone = (zoneId) => {
|
|
@@ -110,6 +123,17 @@ export const DropdownOptionList = (props) => {
|
|
|
110
123
|
})
|
|
111
124
|
}
|
|
112
125
|
|
|
126
|
+
useEffect(() => {
|
|
127
|
+
if (dropdownOptionsState.loading) return
|
|
128
|
+
const zoneId = query.get('zone')
|
|
129
|
+
if (zoneId) {
|
|
130
|
+
const initZone = dropdownOptionsState.options.find(item => item.id === Number(zoneId))
|
|
131
|
+
if (initZone) {
|
|
132
|
+
handleClickZoneDropdown(null, initZone, true)
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
}, [dropdownOptionsState.loading])
|
|
136
|
+
|
|
113
137
|
return (
|
|
114
138
|
<>
|
|
115
139
|
<DropdownOptionsContainer>
|
|
@@ -236,10 +260,7 @@ export const DropdownOptionList = (props) => {
|
|
|
236
260
|
sidebarId='city-details'
|
|
237
261
|
defaultSideBarWidth={550}
|
|
238
262
|
open={openZoneDropdown}
|
|
239
|
-
onClose={() =>
|
|
240
|
-
setSelectedZoneDropdown(null)
|
|
241
|
-
setOpenZonedropdown(false)
|
|
242
|
-
}}
|
|
263
|
+
onClose={() => handleCloseZoneDetail()}
|
|
243
264
|
showExpandIcon
|
|
244
265
|
>
|
|
245
266
|
<ZoneDropdownDetails
|
|
@@ -41,11 +41,11 @@ export const IntegrationListing = (props) => {
|
|
|
41
41
|
|
|
42
42
|
const settingId = settingParams && settingParams.split('=')[1]
|
|
43
43
|
|
|
44
|
-
const onBasicSettingsRedirect = ({ id }) => {
|
|
44
|
+
const onBasicSettingsRedirect = ({ id }, isInitialRender) => {
|
|
45
45
|
if (!id) {
|
|
46
46
|
return events.emit('go_to_page', { page: 'integrations', replace: true })
|
|
47
47
|
}
|
|
48
|
-
if (id) {
|
|
48
|
+
if (id && !isInitialRender) {
|
|
49
49
|
events.emit('go_to_page', {
|
|
50
50
|
page: 'integrations',
|
|
51
51
|
search: `?id=${id}`,
|
|
@@ -66,7 +66,7 @@ export const IntegrationListing = (props) => {
|
|
|
66
66
|
|
|
67
67
|
useEffect(() => {
|
|
68
68
|
if (settingId) {
|
|
69
|
-
onBasicSettingsRedirect({ id: settingId })
|
|
69
|
+
onBasicSettingsRedirect({ id: settingId }, true)
|
|
70
70
|
setShowOption(settingId)
|
|
71
71
|
}
|
|
72
72
|
}, [])
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React, { useState, useEffect } from 'react'
|
|
2
|
+
import { useHistory, useLocation } from 'react-router-dom'
|
|
2
3
|
import { useLanguage } from 'ordering-components-admin-external'
|
|
3
4
|
import { Button, IconButton } from '../../../styles'
|
|
4
5
|
import { DragScroll, Modal } from '../../Shared'
|
|
@@ -26,6 +27,8 @@ export const ItsaCheckmate = (props) => {
|
|
|
26
27
|
onClose
|
|
27
28
|
} = props
|
|
28
29
|
|
|
30
|
+
const history = useHistory()
|
|
31
|
+
const query = new URLSearchParams(useLocation().search)
|
|
29
32
|
const [, t] = useLanguage()
|
|
30
33
|
const { width } = useWindowSize()
|
|
31
34
|
|
|
@@ -64,12 +67,33 @@ export const ItsaCheckmate = (props) => {
|
|
|
64
67
|
toggleMainContent()
|
|
65
68
|
}, [width])
|
|
66
69
|
|
|
70
|
+
const handleOpenMore = (isInitialRender) => {
|
|
71
|
+
setSettingsOpen(true)
|
|
72
|
+
if (!isInitialRender) {
|
|
73
|
+
const id = query.get('id')
|
|
74
|
+
history.replace(`${location.pathname}?id=${id}&more=settings`)
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
const handleCloseDescription = () => {
|
|
79
|
+
setSettingsOpen(false)
|
|
80
|
+
const id = query.get('id')
|
|
81
|
+
history.replace(`${location.pathname}?id=${id}`)
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
useEffect(() => {
|
|
85
|
+
const more = query.get('more')
|
|
86
|
+
if (more === 'settings') {
|
|
87
|
+
handleOpenMore(true)
|
|
88
|
+
}
|
|
89
|
+
}, [])
|
|
90
|
+
|
|
67
91
|
const LalaMoveConnectDescription = () => {
|
|
68
92
|
return (
|
|
69
93
|
<CategoryExtraContent>
|
|
70
94
|
<IconButton
|
|
71
95
|
color='black'
|
|
72
|
-
onClick={() =>
|
|
96
|
+
onClick={() => handleCloseDescription()}
|
|
73
97
|
>
|
|
74
98
|
<XLg />
|
|
75
99
|
</IconButton>
|
|
@@ -155,7 +179,7 @@ export const ItsaCheckmate = (props) => {
|
|
|
155
179
|
<p>{t('ITSACHECKMATE_MENU_4', 'Add, edit, or delete items ')}</p>
|
|
156
180
|
</div>
|
|
157
181
|
</Description>
|
|
158
|
-
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() =>
|
|
182
|
+
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() => handleOpenMore()}>
|
|
159
183
|
<span>{t('SETTINGS', 'All settings')}</span>
|
|
160
184
|
<BsArrowRight />
|
|
161
185
|
</Button>
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React, { useState, useEffect } from 'react'
|
|
2
|
+
import { useHistory, useLocation } from 'react-router-dom'
|
|
2
3
|
import { useLanguage, ApiKeysList as ApiKeysListController } from 'ordering-components-admin-external'
|
|
3
4
|
import { Button, IconButton } from '../../../styles'
|
|
4
5
|
import { Alert, Confirm, DragScroll, Modal } from '../../Shared'
|
|
@@ -26,6 +27,8 @@ const LalaMoveConnectUI = (props) => {
|
|
|
26
27
|
onClose
|
|
27
28
|
} = props
|
|
28
29
|
|
|
30
|
+
const history = useHistory()
|
|
31
|
+
const query = new URLSearchParams(useLocation().search)
|
|
29
32
|
const [, t] = useLanguage()
|
|
30
33
|
const { width } = useWindowSize()
|
|
31
34
|
|
|
@@ -78,12 +81,33 @@ const LalaMoveConnectUI = (props) => {
|
|
|
78
81
|
toggleMainContent()
|
|
79
82
|
}, [width])
|
|
80
83
|
|
|
84
|
+
const handleOpenMore = (isInitialRender) => {
|
|
85
|
+
setSettingsOpen(true)
|
|
86
|
+
if (!isInitialRender) {
|
|
87
|
+
const id = query.get('id')
|
|
88
|
+
history.replace(`${location.pathname}?id=${id}&more=settings`)
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
const handleCloseDescription = () => {
|
|
93
|
+
setSettingsOpen(false)
|
|
94
|
+
const id = query.get('id')
|
|
95
|
+
history.replace(`${location.pathname}?id=${id}`)
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
useEffect(() => {
|
|
99
|
+
const more = query.get('more')
|
|
100
|
+
if (more === 'settings') {
|
|
101
|
+
handleOpenMore(true)
|
|
102
|
+
}
|
|
103
|
+
}, [])
|
|
104
|
+
|
|
81
105
|
const LalaMoveConnectDescription = () => {
|
|
82
106
|
return (
|
|
83
107
|
<CategoryExtraContent>
|
|
84
108
|
<IconButton
|
|
85
109
|
color='black'
|
|
86
|
-
onClick={() =>
|
|
110
|
+
onClick={() => handleCloseDescription()}
|
|
87
111
|
>
|
|
88
112
|
<XLg />
|
|
89
113
|
</IconButton>
|
|
@@ -179,7 +203,7 @@ const LalaMoveConnectUI = (props) => {
|
|
|
179
203
|
<Description>
|
|
180
204
|
{t('CONNECT_WITH_LALAMOVE_DESCRIPTION', 'If you have already worked with LalaMove or are running your business with LalaMove and Ordering simultaneously, this integration will help you connect both platforms and assign orders through them, making your job easy and automated.')}
|
|
181
205
|
</Description>
|
|
182
|
-
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() =>
|
|
206
|
+
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() => handleOpenMore()}>
|
|
183
207
|
<span>{t('SETTINGS', 'All settings')}</span>
|
|
184
208
|
<BsArrowRight />
|
|
185
209
|
</Button>
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React, { useState, useEffect } from 'react'
|
|
2
|
+
import { useHistory, useLocation } from 'react-router-dom'
|
|
2
3
|
import { useLanguage, ApiKeysList as ApiKeysListController } from 'ordering-components-admin-external'
|
|
3
4
|
import { Button, IconButton } from '../../../styles'
|
|
4
5
|
import { Alert, Confirm, DragScroll, Modal } from '../../Shared'
|
|
@@ -26,6 +27,8 @@ const PickerExpressUI = (props) => {
|
|
|
26
27
|
onClose
|
|
27
28
|
} = props
|
|
28
29
|
|
|
30
|
+
const history = useHistory()
|
|
31
|
+
const query = new URLSearchParams(useLocation().search)
|
|
29
32
|
const [, t] = useLanguage()
|
|
30
33
|
const { width } = useWindowSize()
|
|
31
34
|
|
|
@@ -78,12 +81,33 @@ const PickerExpressUI = (props) => {
|
|
|
78
81
|
toggleMainContent()
|
|
79
82
|
}, [width])
|
|
80
83
|
|
|
84
|
+
const handleOpenMore = (isInitialRender) => {
|
|
85
|
+
setSettingsOpen(true)
|
|
86
|
+
if (!isInitialRender) {
|
|
87
|
+
const id = query.get('id')
|
|
88
|
+
history.replace(`${location.pathname}?id=${id}&more=settings`)
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
const handleCloseDescription = () => {
|
|
93
|
+
setSettingsOpen(false)
|
|
94
|
+
const id = query.get('id')
|
|
95
|
+
history.replace(`${location.pathname}?id=${id}`)
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
useEffect(() => {
|
|
99
|
+
const more = query.get('more')
|
|
100
|
+
if (more === 'settings') {
|
|
101
|
+
handleOpenMore(true)
|
|
102
|
+
}
|
|
103
|
+
}, [])
|
|
104
|
+
|
|
81
105
|
const LalaMoveConnectDescription = () => {
|
|
82
106
|
return (
|
|
83
107
|
<CategoryExtraContent>
|
|
84
108
|
<IconButton
|
|
85
109
|
color='black'
|
|
86
|
-
onClick={() =>
|
|
110
|
+
onClick={() => handleCloseDescription()}
|
|
87
111
|
>
|
|
88
112
|
<XLg />
|
|
89
113
|
</IconButton>
|
|
@@ -179,7 +203,7 @@ const PickerExpressUI = (props) => {
|
|
|
179
203
|
<Description>
|
|
180
204
|
{t('CONNECT_WITH_PICKER_EXPRESS_DESCRIPTION', 'If you have already worked with Pickerexpress or are running your business with Pickerexpress and Ordering simultaneously, this integration will help you connect both platforms and assign orders through them, making your job easy and automated.')}
|
|
181
205
|
</Description>
|
|
182
|
-
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() =>
|
|
206
|
+
<Button color='primary' borderRadius='8px' className='all-setting' onClick={() => handleOpenMore()}>
|
|
183
207
|
<span>{t('SETTINGS', 'All settings')}</span>
|
|
184
208
|
<BsArrowRight />
|
|
185
209
|
</Button>
|