ordering-ui-react-native 0.16.59 → 0.16.60-release
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/package.json +6 -5
- package/src/DeliveryApp.tsx +43 -1
- package/src/components/ActiveOrders/index.tsx +61 -63
- package/src/components/ActiveOrders/styles.tsx +8 -14
- package/src/components/BusinessInformation/index.tsx +19 -4
- package/src/components/BusinessInformation/styles.tsx +2 -2
- package/src/components/BusinessProductsList/index.tsx +10 -10
- package/src/components/BusinessesListing/index.tsx +1 -1
- package/src/components/Checkout/index.tsx +2 -1
- package/src/components/LanguageSelector/index.tsx +21 -16
- package/src/components/Messages/index.tsx +2 -2
- package/src/components/NotificationSetting/index.tsx +85 -0
- package/src/components/OrdersOption/index.tsx +54 -56
- package/src/components/PaymentOptions/index.tsx +298 -345
- package/src/components/PaymentOptionsWebView/index.tsx +119 -120
- package/src/components/SingleProductReview/index.tsx +7 -4
- package/src/components/StripeElementsForm/index.tsx +25 -16
- package/src/components/VerifyPhone/styles.tsx +1 -2
- package/src/components/shared/OBottomPopup.tsx +6 -2
- package/src/components/shared/OToast.tsx +4 -4
- package/src/index.tsx +2 -0
- package/src/types/@fatnlazycat/react-native-recaptcha-v3/index.d.ts +1 -0
- package/src/utils/index.tsx +2 -1
- package/themes/business/src/components/AcceptOrRejectOrder/index.tsx +260 -238
- package/themes/business/src/components/AcceptOrRejectOrder/styles.tsx +6 -4
- package/themes/business/src/components/BusinessController/index.tsx +2 -2
- package/themes/business/src/components/Chat/index.tsx +40 -32
- package/themes/business/src/components/DriverMap/index.tsx +7 -5
- package/themes/business/src/components/LoginForm/index.tsx +111 -74
- package/themes/business/src/components/MapView/index.tsx +12 -1
- package/themes/business/src/components/MessagesOption/index.tsx +11 -1
- package/themes/business/src/components/NewOrderNotification/index.tsx +31 -41
- package/themes/business/src/components/OrderDetails/OrderContentComponent.tsx +70 -43
- package/themes/business/src/components/OrderDetails/OrderHeaderComponent.tsx +3 -3
- package/themes/business/src/components/OrdersListManager/index.tsx +10 -3
- package/themes/business/src/components/OrdersOption/index.tsx +76 -77
- package/themes/business/src/components/OrdersOption/styles.tsx +5 -1
- package/themes/business/src/components/OrdersOptionBusiness/index.tsx +15 -1
- package/themes/business/src/components/OrdersOptionCity/index.tsx +15 -1
- package/themes/business/src/components/OrdersOptionDate/index.tsx +19 -6
- package/themes/business/src/components/OrdersOptionDelivery/index.tsx +15 -1
- package/themes/business/src/components/OrdersOptionDriver/index.tsx +15 -1
- package/themes/business/src/components/OrdersOptionPaymethod/index.tsx +15 -1
- package/themes/business/src/components/OrdersOptionStatus/index.tsx +10 -1
- package/themes/business/src/components/PreviousMessages/index.tsx +17 -18
- package/themes/business/src/components/PreviousOrders/OrderItem.tsx +250 -0
- package/themes/business/src/components/PreviousOrders/OrdersGroupedItem.tsx +115 -0
- package/themes/business/src/components/PreviousOrders/index.tsx +440 -245
- package/themes/business/src/components/PreviousOrders/styles.tsx +31 -3
- package/themes/business/src/components/ProductItemAccordion/index.tsx +3 -2
- package/themes/business/src/components/ReviewCustomer/index.tsx +39 -15
- package/themes/business/src/components/UserFormDetails/index.tsx +5 -2
- package/themes/business/src/components/UserProfileForm/index.tsx +2 -0
- package/themes/business/src/components/shared/ODropDown.tsx +42 -8
- package/themes/business/src/components/shared/ODropDownCalendar.tsx +36 -7
- package/themes/business/src/components/shared/OLink.tsx +33 -13
- package/themes/business/src/components/shared/OText.tsx +8 -2
- package/themes/business/src/types/index.tsx +25 -11
- package/themes/business/src/utils/index.tsx +10 -0
- package/themes/doordash/src/components/BusinessesListing/index.tsx +1 -1
- package/themes/doordash/src/components/LoginForm/index.tsx +1 -2
- package/themes/instacart/src/components/BusinessesListing/index.tsx +1 -1
- package/themes/kiosk/src/components/BusinessesListing/index.tsx +2 -1
- package/themes/kiosk/src/components/Checkout/index.tsx +6 -0
- package/themes/kiosk/src/components/LoginForm/index.tsx +121 -10
- package/themes/kiosk/src/components/LoginForm/styles.tsx +5 -0
- package/themes/kiosk/src/components/NavBar/index.tsx +14 -14
- package/themes/kiosk/src/components/OptionCard/index.tsx +1 -1
- package/themes/kiosk/src/components/OrderTypeCardSelector/index.tsx +8 -10
- package/themes/kiosk/src/components/ProductForm/index.tsx +1 -14
- package/themes/kiosk/src/components/shared/OButton.tsx +5 -18
- package/themes/kiosk/src/types/index.d.ts +2 -0
- package/themes/original/index.tsx +8 -0
- package/themes/original/src/components/AddressDetails/index.tsx +10 -8
- package/themes/original/src/components/AddressForm/index.tsx +153 -137
- package/themes/original/src/components/AddressList/index.tsx +1 -1
- package/themes/original/src/components/AppleLogin/index.tsx +4 -4
- package/themes/original/src/components/BusinessBasicInformation/index.tsx +53 -37
- package/themes/original/src/components/BusinessController/index.tsx +112 -48
- package/themes/original/src/components/BusinessController/styles.tsx +14 -9
- package/themes/original/src/components/BusinessInformation/index.tsx +10 -31
- package/themes/original/src/components/BusinessItemAccordion/index.tsx +12 -6
- package/themes/original/src/components/BusinessListingSearch/BusinessControllerSkeletons/index.tsx +57 -0
- package/themes/original/src/components/BusinessListingSearch/MaxSectionItem/index.tsx +59 -0
- package/themes/original/src/components/BusinessListingSearch/MaxSectionItem/styles.tsx +13 -0
- package/themes/original/src/components/BusinessListingSearch/index.tsx +87 -142
- package/themes/original/src/components/BusinessListingSearch/styles.tsx +10 -12
- package/themes/original/src/components/BusinessProductsList/SubcategoriesComponent/index.tsx +87 -0
- package/themes/original/src/components/BusinessProductsList/SubcategoriesComponent/styles.tsx +12 -0
- package/themes/original/src/components/BusinessProductsList/index.tsx +59 -61
- package/themes/original/src/components/BusinessProductsList/styles.tsx +0 -3
- package/themes/original/src/components/BusinessProductsListing/index.tsx +177 -93
- package/themes/original/src/components/BusinessProductsListing/styles.tsx +14 -12
- package/themes/original/src/components/BusinessTypeFilter/index.tsx +3 -2
- package/themes/original/src/components/BusinessesListing/Layout/Appointment/index.tsx +2 -1
- package/themes/original/src/components/BusinessesListing/Layout/Original/index.tsx +112 -107
- package/themes/original/src/components/BusinessesListing/Layout/Original/styles.tsx +1 -9
- package/themes/original/src/components/BusinessesListing/index.tsx +16 -9
- package/themes/original/src/components/Cart/index.tsx +77 -24
- package/themes/original/src/components/Cart/styles.tsx +4 -0
- package/themes/original/src/components/CartContent/index.tsx +77 -18
- package/themes/original/src/components/CartContent/styles.tsx +11 -1
- package/themes/original/src/components/Checkout/index.tsx +115 -118
- package/themes/original/src/components/Checkout/styles.tsx +4 -3
- package/themes/original/src/components/CitiesControl/index.tsx +89 -0
- package/themes/original/src/components/CitiesControl/styles.tsx +17 -0
- package/themes/original/src/components/DriverTips/index.tsx +4 -4
- package/themes/original/src/components/DriverTips/styles.tsx +2 -1
- package/themes/original/src/components/FavoriteList/index.tsx +69 -45
- package/themes/original/src/components/FloatingButton/index.tsx +0 -1
- package/themes/original/src/components/FloatingButton/styles.tsx +1 -1
- package/themes/original/src/components/GPSButton/index.tsx +20 -19
- package/themes/original/src/components/GPSButton/styles.ts +3 -3
- package/themes/original/src/components/GoogleMap/index.tsx +10 -1
- package/themes/original/src/components/HelpAccountAndPayment/index.tsx +25 -10
- package/themes/original/src/components/HelpAccountAndPayment/styles.tsx +4 -0
- package/themes/original/src/components/HelpGuide/index.tsx +9 -8
- package/themes/original/src/components/HelpOrder/index.tsx +9 -8
- package/themes/original/src/components/LanguageSelector/index.tsx +19 -14
- package/themes/original/src/components/LoginForm/Otp/index.tsx +89 -73
- package/themes/original/src/components/LoginForm/Otp/styles.tsx +0 -1
- package/themes/original/src/components/LoginForm/index.tsx +98 -41
- package/themes/original/src/components/LottieAnimation/index.tsx +69 -0
- package/themes/original/src/components/Messages/index.tsx +35 -20
- package/themes/original/src/components/MomentOption/index.tsx +8 -6
- package/themes/original/src/components/MultiCart/index.tsx +50 -0
- package/themes/original/src/components/MultiCartsPaymethodsAndWallets/index.tsx +92 -93
- package/themes/original/src/components/MultiCheckout/index.tsx +96 -65
- package/themes/original/src/components/MultiOrdersDetails/index.tsx +34 -16
- package/themes/original/src/components/MyOrders/index.tsx +89 -25
- package/themes/original/src/components/NavBar/index.tsx +11 -5
- package/themes/original/src/components/NetworkError/index.tsx +5 -3
- package/themes/original/src/components/NotFoundSource/index.tsx +2 -1
- package/themes/original/src/components/Notifications/index.tsx +148 -0
- package/themes/original/src/components/Notifications/styles.tsx +20 -0
- package/themes/original/src/components/OrderDetails/index.tsx +114 -15
- package/themes/original/src/components/OrderDetails/styles.tsx +15 -2
- package/themes/original/src/components/OrderItAgain/index.tsx +75 -0
- package/themes/original/src/components/OrderItAgain/styles.tsx +10 -0
- package/themes/original/src/components/OrderProgress/index.tsx +77 -66
- package/themes/original/src/components/OrderProgress/styles.tsx +5 -0
- package/themes/original/src/components/OrderSummary/index.tsx +2 -35
- package/themes/original/src/components/OrderTypeSelector/index.tsx +85 -36
- package/themes/original/src/components/OrderTypeSelector/styles.tsx +19 -1
- package/themes/original/src/components/OrdersOption/PreviousBusinessOrdered/index.tsx +94 -98
- package/themes/original/src/components/OrdersOption/PreviousProductsOrdered/index.tsx +3 -0
- package/themes/original/src/components/OrdersOption/index.tsx +95 -55
- package/themes/original/src/components/PaymentOptionStripe/styles.tsx +1 -1
- package/themes/original/src/components/PaymentOptionWallet/index.tsx +56 -56
- package/themes/original/src/components/PaymentOptions/index.tsx +1 -2
- package/themes/original/src/components/PhoneInputNumber/index.tsx +1 -1
- package/themes/original/src/components/PlaceSpot/index.tsx +249 -47
- package/themes/original/src/components/PlaceSpot/styles.tsx +0 -2
- package/themes/original/src/components/PreviousOrders/index.tsx +3 -2
- package/themes/original/src/components/ProductForm/index.tsx +379 -396
- package/themes/original/src/components/ProductForm/styles.tsx +7 -12
- package/themes/original/src/components/ProductItemAccordion/index.tsx +199 -128
- package/themes/original/src/components/ProductOption/index.tsx +1 -1
- package/themes/original/src/components/ProductOptionSubOption/index.tsx +16 -8
- package/themes/original/src/components/ProductOptionSubOption/styles.tsx +0 -1
- package/themes/original/src/components/ProfessionalFilter/index.tsx +2 -1
- package/themes/original/src/components/ProfessionalProfile/index.tsx +19 -8
- package/themes/original/src/components/Promotions/index.tsx +232 -219
- package/themes/original/src/components/Promotions/styles.tsx +7 -2
- package/themes/original/src/components/ReviewDriver/index.tsx +3 -3
- package/themes/original/src/components/ReviewOrder/index.tsx +43 -11
- package/themes/original/src/components/ReviewOrder/styles.tsx +7 -0
- package/themes/original/src/components/ReviewProducts/index.tsx +8 -5
- package/themes/original/src/components/ReviewTrigger/index.tsx +27 -9
- package/themes/original/src/components/ReviewTrigger/styles.tsx +8 -1
- package/themes/original/src/components/ScheduleAccordion/index.tsx +68 -0
- package/themes/original/src/components/ScheduleAccordion/styles.tsx +14 -0
- package/themes/original/src/components/ServiceForm/index.tsx +328 -264
- package/themes/original/src/components/SignupForm/index.tsx +134 -89
- package/themes/original/src/components/SingleOrderCard/index.tsx +240 -130
- package/themes/original/src/components/SingleOrderCard/styles.tsx +10 -8
- package/themes/original/src/components/SingleProductCard/index.tsx +116 -72
- package/themes/original/src/components/SingleProductCard/styles.tsx +2 -9
- package/themes/original/src/components/SingleProductReview/index.tsx +38 -5
- package/themes/original/src/components/SingleProductReview/styles.tsx +12 -0
- package/themes/original/src/components/StripeCardsList/index.tsx +1 -1
- package/themes/original/src/components/StripeElementsForm/index.tsx +13 -2
- package/themes/original/src/components/UpsellingProducts/index.tsx +244 -215
- package/themes/original/src/components/UpsellingProducts/styles.tsx +12 -1
- package/themes/original/src/components/UserDetails/index.tsx +5 -3
- package/themes/original/src/components/UserFormDetails/index.tsx +6 -48
- package/themes/original/src/components/UserProfile/index.tsx +58 -35
- package/themes/original/src/components/UserProfile/styles.ts +17 -0
- package/themes/original/src/components/WalletTransactions/index.tsx +76 -0
- package/themes/original/src/components/WalletTransactions/styles.tsx +13 -0
- package/themes/original/src/components/Wallets/index.tsx +176 -164
- package/themes/original/src/components/Wallets/styles.tsx +12 -8
- package/themes/original/src/components/shared/CardAnimation.tsx +47 -0
- package/themes/original/src/components/shared/HeaderTitle.tsx +8 -3
- package/themes/original/src/components/shared/OBottomPopup.tsx +11 -7
- package/themes/original/src/components/shared/OButton.tsx +8 -3
- package/themes/original/src/components/shared/OIcon.tsx +8 -1
- package/themes/original/src/components/shared/OInput.tsx +10 -1
- package/themes/original/src/layouts/Container.tsx +13 -9
- package/themes/original/src/types/index.tsx +65 -8
- package/themes/original/src/utils/index.tsx +103 -58
- package/themes/uber-eats/src/components/BusinessesListing/index.tsx +1 -1
|
@@ -33,8 +33,7 @@ export const NotificationIcon = styled.View`
|
|
|
33
33
|
export const AcceptOrRejectOrder = styled.View`
|
|
34
34
|
flex-direction: row;
|
|
35
35
|
justify-content: space-between;
|
|
36
|
-
|
|
37
|
-
margin: 10px;
|
|
36
|
+
margin: ${(props: any) => props.m ?? 10}px;
|
|
38
37
|
`
|
|
39
38
|
export const Timestatus = styled.View`
|
|
40
39
|
position: relative;;
|
|
@@ -42,4 +41,33 @@ export const Timestatus = styled.View`
|
|
|
42
41
|
height: 55px;
|
|
43
42
|
border-radius: 20px;
|
|
44
43
|
top: 5px;
|
|
45
|
-
`
|
|
44
|
+
`
|
|
45
|
+
|
|
46
|
+
export const AccordionSection = styled.View`
|
|
47
|
+
background: #FFF;
|
|
48
|
+
padding-vertical: 10px;
|
|
49
|
+
`
|
|
50
|
+
|
|
51
|
+
export const Accordion = styled.TouchableOpacity`
|
|
52
|
+
flex-direction: column;
|
|
53
|
+
justify-content: space-between;
|
|
54
|
+
align-items: center;
|
|
55
|
+
paddingVertical: 0;
|
|
56
|
+
marginLeft: 3px;
|
|
57
|
+
`
|
|
58
|
+
|
|
59
|
+
export const ContentInfo = styled.View`
|
|
60
|
+
flex-direction: row;
|
|
61
|
+
justify-content: space-between;
|
|
62
|
+
align-items: flex-start;
|
|
63
|
+
overflow: hidden;
|
|
64
|
+
`
|
|
65
|
+
|
|
66
|
+
export const AccordionContent = styled.View`
|
|
67
|
+
overflow: hidden;
|
|
68
|
+
`
|
|
69
|
+
|
|
70
|
+
export const ProductOptionsList = styled.View`
|
|
71
|
+
margin-top: 20px;
|
|
72
|
+
margin-left: 20px;
|
|
73
|
+
`
|
|
@@ -28,6 +28,7 @@ export const ProductItemAccordion = (props: ProductItemAccordionParams) => {
|
|
|
28
28
|
getProductMax,
|
|
29
29
|
onDeleteProduct,
|
|
30
30
|
onEditProduct,
|
|
31
|
+
currency
|
|
31
32
|
} = props;
|
|
32
33
|
|
|
33
34
|
const [, t] = useLanguage();
|
|
@@ -147,7 +148,7 @@ export const ProductItemAccordion = (props: ProductItemAccordionParams) => {
|
|
|
147
148
|
}}>
|
|
148
149
|
<View style={{ flexDirection: 'row' }}>
|
|
149
150
|
<OText size={12} color={theme.colors.textGray}>
|
|
150
|
-
{parsePrice(getProductPrice(product))}
|
|
151
|
+
{parsePrice(getProductPrice(product), { currency })}
|
|
151
152
|
</OText>
|
|
152
153
|
|
|
153
154
|
{(
|
|
@@ -268,7 +269,7 @@ export const ProductItemAccordion = (props: ProductItemAccordionParams) => {
|
|
|
268
269
|
suboption.position,
|
|
269
270
|
)
|
|
270
271
|
: '',
|
|
271
|
-
price: parsePrice(suboption.price),
|
|
272
|
+
price: parsePrice(suboption.price, { currency }),
|
|
272
273
|
})}
|
|
273
274
|
</OText>
|
|
274
275
|
</ProductSubOption>
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
|
+
|
|
3
|
+
import React, { useState, useEffect, useRef } from 'react'
|
|
2
4
|
import {
|
|
3
5
|
useLanguage,
|
|
4
6
|
useUtils,
|
|
@@ -10,7 +12,8 @@ import {
|
|
|
10
12
|
View,
|
|
11
13
|
StyleSheet,
|
|
12
14
|
I18nManager,
|
|
13
|
-
TouchableOpacity
|
|
15
|
+
TouchableOpacity,
|
|
16
|
+
Keyboard
|
|
14
17
|
} from 'react-native'
|
|
15
18
|
import { useTheme } from 'styled-components/native'
|
|
16
19
|
import { ReviewCustomerParams } from '../../types'
|
|
@@ -38,7 +41,8 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
|
|
|
38
41
|
reviewState,
|
|
39
42
|
setReviewState,
|
|
40
43
|
actionState,
|
|
41
|
-
handleSendCustomerReview
|
|
44
|
+
handleSendCustomerReview,
|
|
45
|
+
handleCustomCustomerReview
|
|
42
46
|
} = props
|
|
43
47
|
|
|
44
48
|
const theme = useTheme()
|
|
@@ -52,12 +56,12 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
|
|
|
52
56
|
const { top, bottom } = useSafeAreaInsets()
|
|
53
57
|
const [comments, setComments] = useState<Array<any>>([])
|
|
54
58
|
const [extraComment, setExtraComment] = useState('')
|
|
55
|
-
|
|
59
|
+
const scrollref = useRef<any>()
|
|
56
60
|
const styles = StyleSheet.create({
|
|
57
61
|
photoWrapper: {
|
|
58
62
|
shadowColor: theme.colors.black,
|
|
59
63
|
shadowRadius: 3,
|
|
60
|
-
shadowOffset: {width: 1, height: 4},
|
|
64
|
+
shadowOffset: { width: 1, height: 4 },
|
|
61
65
|
elevation: 3,
|
|
62
66
|
borderRadius: 8,
|
|
63
67
|
shadowOpacity: 0.1,
|
|
@@ -95,11 +99,11 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
|
|
|
95
99
|
})
|
|
96
100
|
|
|
97
101
|
const qualificationList = [
|
|
98
|
-
{ key: 1, text: t('TERRIBLE', 'Terrible'), percent: 0,
|
|
102
|
+
{ key: 1, text: t('TERRIBLE', 'Terrible'), percent: 0, parentStyle: { left: '0%' }, isInnerStyle: false, pointerColor: false },
|
|
99
103
|
{ key: 2, text: t('BAD', 'Bad'), percent: 0.25, parentStyle: { left: '25%' }, isInnerStyle: true, pointerColor: true },
|
|
100
104
|
{ key: 3, text: t('OKAY', 'Okay'), percent: 0.5, parentStyle: { left: '50%' }, isInnerStyle: true, pointerColor: true },
|
|
101
105
|
{ key: 4, text: t('GOOD', 'Good'), percent: 0.75, parentStyle: { left: '75%' }, isInnerStyle: true, pointerColor: true },
|
|
102
|
-
{ key: 5, text: t('GREAT', 'Great'), percent: 1, parentStyle: { right: '0%' }, isInnerStyle: false,
|
|
106
|
+
{ key: 5, text: t('GREAT', 'Great'), percent: 1, parentStyle: { right: '0%' }, isInnerStyle: false, pointerColor: false }
|
|
103
107
|
]
|
|
104
108
|
|
|
105
109
|
const commentsList = reviewCommentList('customer')
|
|
@@ -142,6 +146,25 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
|
|
|
142
146
|
|
|
143
147
|
}, [actionState.error])
|
|
144
148
|
|
|
149
|
+
useEffect(() => {
|
|
150
|
+
if (scrollref?.current) {
|
|
151
|
+
Keyboard.addListener('keyboardDidShow', () => {
|
|
152
|
+
scrollref.current.scrollToEnd()
|
|
153
|
+
})
|
|
154
|
+
}
|
|
155
|
+
}, [scrollref?.current])
|
|
156
|
+
|
|
157
|
+
const customerName = `${order?.customer?.name ?? ''} ${order?.customer?.middle_name ?? ''} ${order?.customer?.lastname ?? ''} ${order?.customer?.second_lastname ?? ''}`?.replace(' ', ' ')?.trim() ?? ''
|
|
158
|
+
|
|
159
|
+
const handleReviewClick = () => {
|
|
160
|
+
handleCustomCustomerReview
|
|
161
|
+
? handleCustomCustomerReview({
|
|
162
|
+
qualification: reviewState?.qualification,
|
|
163
|
+
comment: reviewState?.comment
|
|
164
|
+
})
|
|
165
|
+
: handleSendCustomerReview()
|
|
166
|
+
}
|
|
167
|
+
|
|
145
168
|
return (
|
|
146
169
|
<KeyboardAvoidingView
|
|
147
170
|
enabled
|
|
@@ -179,6 +202,7 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
|
|
|
179
202
|
<Content
|
|
180
203
|
showsVerticalScrollIndicator={false}
|
|
181
204
|
contentContainerStyle={{ paddingBottom: 30 }}
|
|
205
|
+
ref={scrollref}
|
|
182
206
|
>
|
|
183
207
|
<CustomerInfoContainer>
|
|
184
208
|
<View
|
|
@@ -196,20 +220,20 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
|
|
|
196
220
|
style={{ borderRadius: 7.6 }}
|
|
197
221
|
/>
|
|
198
222
|
</View>
|
|
199
|
-
<OText
|
|
223
|
+
{!!customerName && <OText
|
|
200
224
|
size={14}
|
|
201
225
|
weight="500"
|
|
202
226
|
style={{
|
|
203
227
|
marginTop: 16
|
|
204
228
|
}}
|
|
205
229
|
>
|
|
206
|
-
{
|
|
207
|
-
</OText>
|
|
230
|
+
{customerName}
|
|
231
|
+
</OText>}
|
|
208
232
|
</CustomerInfoContainer>
|
|
209
233
|
<OText
|
|
210
234
|
size={12}
|
|
211
235
|
>
|
|
212
|
-
{t('HOW_WAS_YOUR_CUSTOMER', 'How was your experience with _name_?').replace('_name_',
|
|
236
|
+
{customerName ? t('HOW_WAS_YOUR_CUSTOMER', 'How was your experience with _name_?').replace('_name_', customerName) : t('HOW_WAS_YOUR_NO_CUSTOMER', 'How was your experience?')}
|
|
213
237
|
</OText>
|
|
214
238
|
<RatingBarContainer>
|
|
215
239
|
<LinearGradient
|
|
@@ -270,8 +294,8 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
|
|
|
270
294
|
}}
|
|
271
295
|
style={{ height: 35, paddingLeft: 5, paddingRight: 5, marginHorizontal: 3, marginVertical: 10 }}
|
|
272
296
|
imgRightSrc={isSelectedComment(commentItem.key) ? theme.images.general.close : null}
|
|
273
|
-
imgRightStyle={{
|
|
274
|
-
onClick={() => handleChangeComment(commentItem)
|
|
297
|
+
imgRightStyle={{ right: 5, margin: 5 }}
|
|
298
|
+
onClick={() => handleChangeComment(commentItem)}
|
|
275
299
|
/>
|
|
276
300
|
))}
|
|
277
301
|
</CommentsButtonGroup>
|
|
@@ -291,7 +315,7 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
|
|
|
291
315
|
|
|
292
316
|
<ActionButtonWrapper>
|
|
293
317
|
<FloatingButton
|
|
294
|
-
firstButtonClick={() =>
|
|
318
|
+
firstButtonClick={() => handleReviewClick()}
|
|
295
319
|
btnText={actionState.loading ? t('LOADING', 'Loading') : t('SEND_REVIEW', 'Send Review')}
|
|
296
320
|
color={theme.colors.primary}
|
|
297
321
|
widthButton={'100%'}
|
|
@@ -299,7 +323,7 @@ const ReviewCustomerUI = (props: ReviewCustomerParams) => {
|
|
|
299
323
|
</ActionButtonWrapper>
|
|
300
324
|
<Alert
|
|
301
325
|
open={alertState.open}
|
|
302
|
-
onAccept={() => setAlertState({
|
|
326
|
+
onAccept={() => setAlertState({ open: false, content: [] })}
|
|
303
327
|
onClose={() => setAlertState({ open: false, content: [] })}
|
|
304
328
|
content={alertState.content}
|
|
305
329
|
title={t('ERROR', 'Error')}
|
|
@@ -36,6 +36,7 @@ export const UserFormDetailsUI = (props: any) => {
|
|
|
36
36
|
handleCancelEdit,
|
|
37
37
|
toggleIsEdit,
|
|
38
38
|
isCheckout,
|
|
39
|
+
isAlsea
|
|
39
40
|
} = props;
|
|
40
41
|
|
|
41
42
|
const theme = useTheme();
|
|
@@ -265,7 +266,9 @@ export const UserFormDetailsUI = (props: any) => {
|
|
|
265
266
|
}).map(
|
|
266
267
|
(field: any) =>
|
|
267
268
|
showField &&
|
|
268
|
-
showField(field.code) &&
|
|
269
|
+
showField(field.code) &&
|
|
270
|
+
!isAlsea
|
|
271
|
+
&& (
|
|
269
272
|
<React.Fragment key={field.id}>
|
|
270
273
|
<OText style={styles.label}>
|
|
271
274
|
{t(field?.code.toUpperCase(), field?.name)}
|
|
@@ -442,7 +445,7 @@ export const UserFormDetailsUI = (props: any) => {
|
|
|
442
445
|
</OText>
|
|
443
446
|
)}
|
|
444
447
|
|
|
445
|
-
{!!showInputPhoneNumber && (
|
|
448
|
+
{!!showInputPhoneNumber && !isAlsea && (
|
|
446
449
|
<WrapperPhone>
|
|
447
450
|
<PhoneInputNumber
|
|
448
451
|
data={phoneInputData}
|
|
@@ -49,6 +49,7 @@ const ProfileUI = (props: ProfileParams) => {
|
|
|
49
49
|
handleToggleAvalaibleStatusDriver,
|
|
50
50
|
userState,
|
|
51
51
|
isAvailableLoading,
|
|
52
|
+
isAlsea
|
|
52
53
|
} = props;
|
|
53
54
|
|
|
54
55
|
const [{ user }] = useSession();
|
|
@@ -459,6 +460,7 @@ const ProfileUI = (props: ProfileParams) => {
|
|
|
459
460
|
hideUpdateButton
|
|
460
461
|
handleCancelEdit={handleCancelEdit}
|
|
461
462
|
toggleIsEdit={toggleIsEdit}
|
|
463
|
+
isAlsea={isAlsea}
|
|
462
464
|
/>
|
|
463
465
|
</View>
|
|
464
466
|
)}
|
|
@@ -4,6 +4,7 @@ import { ScrollView, TouchableOpacity } from 'react-native-gesture-handler'
|
|
|
4
4
|
import { ScrollView as CustomScrollView, TouchableOpacity as CustomTouchableOpacity, View } from 'react-native'
|
|
5
5
|
import FeatherIcon from 'react-native-vector-icons/Feather';
|
|
6
6
|
import MaterialCommunityIcons from 'react-native-vector-icons/MaterialCommunityIcons';
|
|
7
|
+
import AntDesign from 'react-native-vector-icons/AntDesign';
|
|
7
8
|
import { Text } from 'react-native-paper';
|
|
8
9
|
|
|
9
10
|
interface Props {
|
|
@@ -16,7 +17,11 @@ interface Props {
|
|
|
16
17
|
dropViewMaxHeight?: any,
|
|
17
18
|
isModal?: any,
|
|
18
19
|
bgcolor?: string,
|
|
19
|
-
textcolor?: string
|
|
20
|
+
textcolor?: string,
|
|
21
|
+
handleClear?: any,
|
|
22
|
+
handleOpenSelect?: any,
|
|
23
|
+
openedSelect?: string,
|
|
24
|
+
selectType?: string
|
|
20
25
|
}
|
|
21
26
|
|
|
22
27
|
const Wrapper = styled.View`
|
|
@@ -70,7 +75,11 @@ const ODropDown = (props: Props) => {
|
|
|
70
75
|
placeholder,
|
|
71
76
|
onSelect,
|
|
72
77
|
dropViewMaxHeight,
|
|
73
|
-
isModal
|
|
78
|
+
isModal,
|
|
79
|
+
handleClear,
|
|
80
|
+
handleOpenSelect,
|
|
81
|
+
openedSelect,
|
|
82
|
+
selectType
|
|
74
83
|
} = props
|
|
75
84
|
|
|
76
85
|
const theme = useTheme();
|
|
@@ -82,6 +91,7 @@ const ODropDown = (props: Props) => {
|
|
|
82
91
|
|
|
83
92
|
const onToggle = () => {
|
|
84
93
|
setIsOpen(!isOpen)
|
|
94
|
+
if (!isOpen) handleOpenSelect?.()
|
|
85
95
|
}
|
|
86
96
|
|
|
87
97
|
const onSelectOption = (option: any) => {
|
|
@@ -91,12 +101,25 @@ const ODropDown = (props: Props) => {
|
|
|
91
101
|
setIsOpen(false)
|
|
92
102
|
}
|
|
93
103
|
|
|
104
|
+
const handleClearSearch = () => {
|
|
105
|
+
handleClear()
|
|
106
|
+
if (isOpen) {
|
|
107
|
+
onToggle()
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
|
|
94
111
|
useEffect(() => {
|
|
95
112
|
const _defaultOption = options?.find((option: any) => option.value === defaultValue)
|
|
96
113
|
setSelectedOption(_defaultOption)
|
|
97
114
|
setValue(defaultValue)
|
|
98
115
|
}, [defaultValue, options])
|
|
99
116
|
|
|
117
|
+
useEffect(() => {
|
|
118
|
+
if (openedSelect !== selectType && typeof openedSelect === 'string') {
|
|
119
|
+
setIsOpen(false)
|
|
120
|
+
}
|
|
121
|
+
}, [openedSelect])
|
|
122
|
+
|
|
100
123
|
return (
|
|
101
124
|
<Wrapper style={props.style}>
|
|
102
125
|
<Selected
|
|
@@ -110,11 +133,22 @@ const ODropDown = (props: Props) => {
|
|
|
110
133
|
>
|
|
111
134
|
{selectedOption?.content || selectedOption?.name || placeholder}
|
|
112
135
|
</SelectedLabel>
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
136
|
+
{selectedOption && handleClear ? (
|
|
137
|
+
<AntDesign
|
|
138
|
+
name={'close'}
|
|
139
|
+
size={20}
|
|
140
|
+
onPress={() => handleClearSearch()}
|
|
141
|
+
style={{ position: 'absolute', right: 12, top: 13 }}
|
|
142
|
+
/>
|
|
143
|
+
) : (
|
|
144
|
+
<FeatherIcon
|
|
145
|
+
name='chevron-down'
|
|
146
|
+
color={props.textcolor}
|
|
147
|
+
size={24}
|
|
148
|
+
style={{ position: 'absolute', right: 12, top: 13 }}
|
|
149
|
+
|
|
150
|
+
/>
|
|
151
|
+
)}
|
|
118
152
|
</Selected>
|
|
119
153
|
{isOpen && options && (
|
|
120
154
|
<DropView
|
|
@@ -154,7 +188,7 @@ const ODropDown = (props: Props) => {
|
|
|
154
188
|
maxHeight: dropViewMaxHeight || null,
|
|
155
189
|
paddingBottom: 15
|
|
156
190
|
}}
|
|
157
|
-
|
|
191
|
+
nestedScrollEnabled={true}
|
|
158
192
|
>
|
|
159
193
|
{options.map((option: any, index: number) => (
|
|
160
194
|
<CustomTouchableOpacity
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React, { useState, useEffect } from 'react'
|
|
1
|
+
import React, { useState, useEffect, useRef } from 'react'
|
|
2
2
|
import styled, { css, useTheme } from 'styled-components/native'
|
|
3
3
|
import { useLanguage } from 'ordering-components/native';
|
|
4
4
|
import { ScrollView, TouchableOpacity } from 'react-native-gesture-handler'
|
|
@@ -24,6 +24,10 @@ interface Props {
|
|
|
24
24
|
handleChangeDate?: any,
|
|
25
25
|
rangeDate?: any,
|
|
26
26
|
isCalendarAlwaysVisible?: boolean
|
|
27
|
+
handleClear?: any;
|
|
28
|
+
handleOpenSelect?: any,
|
|
29
|
+
openedSelect?: string,
|
|
30
|
+
selectType?: string
|
|
27
31
|
}
|
|
28
32
|
|
|
29
33
|
const Wrapper = styled.View`
|
|
@@ -96,7 +100,11 @@ const ODropDownCalendar = (props: Props) => {
|
|
|
96
100
|
isCalendar,
|
|
97
101
|
handleChangeDate,
|
|
98
102
|
rangeDate,
|
|
99
|
-
isCalendarAlwaysVisible
|
|
103
|
+
isCalendarAlwaysVisible,
|
|
104
|
+
handleClear,
|
|
105
|
+
handleOpenSelect,
|
|
106
|
+
openedSelect,
|
|
107
|
+
selectType
|
|
100
108
|
} = props
|
|
101
109
|
|
|
102
110
|
const theme = useTheme();
|
|
@@ -110,6 +118,7 @@ const ODropDownCalendar = (props: Props) => {
|
|
|
110
118
|
|
|
111
119
|
const onToggle = () => {
|
|
112
120
|
setIsOpen(!isOpen)
|
|
121
|
+
if (!isOpen) handleOpenSelect?.()
|
|
113
122
|
}
|
|
114
123
|
|
|
115
124
|
const onSelectOption = (option: any) => {
|
|
@@ -122,7 +131,7 @@ const ODropDownCalendar = (props: Props) => {
|
|
|
122
131
|
const onDateChange = (date: any, type: any) => {
|
|
123
132
|
if (!date) return
|
|
124
133
|
if (type === 'END_DATE') {
|
|
125
|
-
handleChangeDate(rangeDate.from, date.format('MM/DD/YY'))
|
|
134
|
+
handleChangeDate(rangeDate.from, new Date(date.format('MM/DD/YY')) === rangeDate.from ? '' : date.format('MM/DD/YY'))
|
|
126
135
|
} else {
|
|
127
136
|
handleChangeDate(date.format('MM/DD/YY'), '')
|
|
128
137
|
}
|
|
@@ -142,12 +151,31 @@ const ODropDownCalendar = (props: Props) => {
|
|
|
142
151
|
return (from || to) ? (from + (to ? end : '')) : placeholder
|
|
143
152
|
}
|
|
144
153
|
|
|
154
|
+
const handleClearCalendar = () => {
|
|
155
|
+
handleClear && handleClear()
|
|
156
|
+
if (isOpen) {
|
|
157
|
+
onToggle()
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
|
|
145
161
|
useEffect(() => {
|
|
146
162
|
const _defaultOption = options?.find((option: any) => option.value === defaultValue)
|
|
147
163
|
setSelectedOption(_defaultOption)
|
|
148
164
|
setValue(defaultValue)
|
|
149
165
|
}, [defaultValue, options])
|
|
150
166
|
|
|
167
|
+
useEffect(() => {
|
|
168
|
+
if (openedSelect !== selectType && typeof openedSelect === 'string') {
|
|
169
|
+
setIsOpen(false)
|
|
170
|
+
}
|
|
171
|
+
}, [openedSelect])
|
|
172
|
+
|
|
173
|
+
useEffect(() => {
|
|
174
|
+
if (rangeDate.to && rangeDate.from) {
|
|
175
|
+
onSelect('calendar')
|
|
176
|
+
}
|
|
177
|
+
}, [rangeDate.to, rangeDate.from])
|
|
178
|
+
|
|
151
179
|
return (
|
|
152
180
|
<Wrapper style={props.style}>
|
|
153
181
|
<Selected
|
|
@@ -165,10 +193,11 @@ const ODropDownCalendar = (props: Props) => {
|
|
|
165
193
|
: `${selectedOption?.content || selectedOption?.name || placeholder}`
|
|
166
194
|
}
|
|
167
195
|
</SelectedLabel>
|
|
168
|
-
<
|
|
169
|
-
name='calendar'
|
|
170
|
-
|
|
171
|
-
|
|
196
|
+
<AntDesign
|
|
197
|
+
name={selectedOption && handleClear ? 'close' : 'calendar'}
|
|
198
|
+
size={20}
|
|
199
|
+
onPress={() => handleClearCalendar()}
|
|
200
|
+
style={{ position: 'absolute', right: 12, top: 13 }}
|
|
172
201
|
/>
|
|
173
202
|
</Selected>
|
|
174
203
|
{isOpen && options && (
|
|
@@ -12,10 +12,12 @@ interface Props {
|
|
|
12
12
|
TextStyle?: TextStyle;
|
|
13
13
|
type?: string;
|
|
14
14
|
hasButton?: boolean;
|
|
15
|
+
numberOfLines?: number;
|
|
16
|
+
onTextLayout?: (e : any) => void;
|
|
15
17
|
}
|
|
16
18
|
|
|
17
19
|
const OLink = (props: Props): React.ReactElement => {
|
|
18
|
-
const { url, shorcut, color, PressStyle, TextStyle, type, hasButton } = props;
|
|
20
|
+
const { url, shorcut, color, PressStyle, TextStyle, type, hasButton, numberOfLines, onTextLayout } = props;
|
|
19
21
|
const [, t] = useLanguage();
|
|
20
22
|
|
|
21
23
|
const handleAlert = () =>
|
|
@@ -29,8 +31,19 @@ const OLink = (props: Props): React.ReactElement => {
|
|
|
29
31
|
],
|
|
30
32
|
);
|
|
31
33
|
|
|
34
|
+
const handleInvalidNumberAlert = () =>
|
|
35
|
+
Alert.alert(
|
|
36
|
+
t('ERROR_OPENING_THE_LINK', 'Error opening the link'),
|
|
37
|
+
t('INVALID_NUMBER', 'Invalid number'),
|
|
38
|
+
[
|
|
39
|
+
{
|
|
40
|
+
text: t('OK', 'Ok'),
|
|
41
|
+
},
|
|
42
|
+
],
|
|
43
|
+
);
|
|
44
|
+
|
|
32
45
|
const handleOpenUrl = async (breakFunction = false) => {
|
|
33
|
-
if(breakFunction) {
|
|
46
|
+
if (breakFunction) {
|
|
34
47
|
return
|
|
35
48
|
}
|
|
36
49
|
if (!url) {
|
|
@@ -40,8 +53,9 @@ const OLink = (props: Props): React.ReactElement => {
|
|
|
40
53
|
|
|
41
54
|
try {
|
|
42
55
|
const supported = await Linking.canOpenURL(url);
|
|
43
|
-
|
|
44
|
-
|
|
56
|
+
if (url && url?.includes('tel:')) {
|
|
57
|
+
url?.includes('invalid') ? handleInvalidNumberAlert() : await Linking.openURL(url)
|
|
58
|
+
} else if (supported) {
|
|
45
59
|
await Linking.openURL(url);
|
|
46
60
|
} else {
|
|
47
61
|
handleAlert();
|
|
@@ -57,20 +71,26 @@ const OLink = (props: Props): React.ReactElement => {
|
|
|
57
71
|
<OButton
|
|
58
72
|
onClick={() => handleOpenUrl()}
|
|
59
73
|
text={shorcut} imgRightSrc=''
|
|
60
|
-
textStyle={{color: 'white'}}
|
|
61
|
-
style={{width: '100%', alignSelf: 'center', borderRadius: 10}}
|
|
74
|
+
textStyle={{ color: 'white' }}
|
|
75
|
+
style={{ width: '100%', alignSelf: 'center', borderRadius: 10 }}
|
|
62
76
|
/>
|
|
63
77
|
) : (
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
78
|
+
<OText
|
|
79
|
+
style={TextStyle}
|
|
80
|
+
numberOfLines={numberOfLines ?? 1}
|
|
81
|
+
ellipsizeMode="tail"
|
|
82
|
+
color={color}
|
|
83
|
+
onTextLayout={onTextLayout}
|
|
84
|
+
>
|
|
85
|
+
{shorcut}
|
|
86
|
+
</OText>
|
|
71
87
|
)}
|
|
72
88
|
</Pressable>
|
|
73
89
|
);
|
|
74
90
|
};
|
|
75
91
|
|
|
92
|
+
OLink.defaultProps = {
|
|
93
|
+
onTextLayout: (e: any) => {}
|
|
94
|
+
};
|
|
95
|
+
|
|
76
96
|
export default OLink;
|
|
@@ -40,16 +40,22 @@ interface Props {
|
|
|
40
40
|
numberOfLines?: number;
|
|
41
41
|
ellipsizeMode?: string;
|
|
42
42
|
adjustsFontSizeToFit?: boolean;
|
|
43
|
-
textDecorationLine?: string
|
|
43
|
+
textDecorationLine?: string;
|
|
44
|
+
lineHeight?: number;
|
|
45
|
+
onTextLayout?: (e : any) => void;
|
|
44
46
|
}
|
|
45
47
|
|
|
46
48
|
const OText = (props: Props): React.ReactElement => {
|
|
47
49
|
return (
|
|
48
|
-
<SText {...props} style={props.style}>
|
|
50
|
+
<SText {...props} style={[props.style, { lineHeight: props.lineHeight }]} onTextLayout={props.onTextLayout}>
|
|
49
51
|
{props.children}
|
|
50
52
|
{props.space && ' '}
|
|
51
53
|
</SText>
|
|
52
54
|
);
|
|
53
55
|
};
|
|
54
56
|
|
|
57
|
+
OText.defaultProps = {
|
|
58
|
+
onTextLayout: (e: any) => {}
|
|
59
|
+
};
|
|
60
|
+
|
|
55
61
|
export default OText;
|
|
@@ -21,8 +21,8 @@ export interface LoginParams {
|
|
|
21
21
|
allowedLevels?: any;
|
|
22
22
|
useRootPoint?: any;
|
|
23
23
|
notificationState?: any;
|
|
24
|
-
|
|
25
|
-
|
|
24
|
+
handleReCaptcha?: any;
|
|
25
|
+
enableReCaptcha?: any;
|
|
26
26
|
}
|
|
27
27
|
export interface ProfileParams {
|
|
28
28
|
navigation?: any;
|
|
@@ -41,6 +41,7 @@ export interface ProfileParams {
|
|
|
41
41
|
validationFields?: any;
|
|
42
42
|
showField?: any;
|
|
43
43
|
isRequiredField?: any;
|
|
44
|
+
isAlsea?: boolean;
|
|
44
45
|
}
|
|
45
46
|
|
|
46
47
|
export interface AddressListParams {
|
|
@@ -255,6 +256,7 @@ export interface MessagesOptionParams {
|
|
|
255
256
|
messagesReadList?: any;
|
|
256
257
|
onNavigationRedirect?: any;
|
|
257
258
|
setSortBy?: any;
|
|
259
|
+
getOrders: any
|
|
258
260
|
}
|
|
259
261
|
export interface OrdersOptionParams {
|
|
260
262
|
orderList?: any;
|
|
@@ -265,7 +267,7 @@ export interface OrdersOptionParams {
|
|
|
265
267
|
titleContent?: string;
|
|
266
268
|
customArray?: Array<any>;
|
|
267
269
|
loadMoreOrders?: () => {};
|
|
268
|
-
loadOrders?: ({}: any) => {};
|
|
270
|
+
loadOrders?: ({ }: any) => {};
|
|
269
271
|
messages?: any;
|
|
270
272
|
setMessages?: () => {};
|
|
271
273
|
loadMessages?: () => {};
|
|
@@ -279,7 +281,7 @@ export interface OrdersOptionParams {
|
|
|
279
281
|
ordersGroup?: any;
|
|
280
282
|
setOrdersGroup?: any;
|
|
281
283
|
setCurrentFilters?: any;
|
|
282
|
-
onFiltered?: ({}: any) => {};
|
|
284
|
+
onFiltered?: ({ }: any) => {};
|
|
283
285
|
filtered?: any;
|
|
284
286
|
handleClickOrder?: any;
|
|
285
287
|
orderGroupStatusCustom?: {
|
|
@@ -290,9 +292,15 @@ export interface OrdersOptionParams {
|
|
|
290
292
|
};
|
|
291
293
|
isBusinessApp?: boolean;
|
|
292
294
|
handleClickLogisticOrder: (status: number, orderId: number) => void,
|
|
293
|
-
logisticOrders: {orders: Array<any>, loading: boolean, error: Array<string> | string},
|
|
295
|
+
logisticOrders: { orders: Array<any>, loading: boolean, error: Array<string> | string },
|
|
294
296
|
loadLogisticOrders: () => void;
|
|
295
|
-
isLogisticActivated?: boolean
|
|
297
|
+
isLogisticActivated?: boolean;
|
|
298
|
+
isAlsea?: boolean;
|
|
299
|
+
checkNotification?: boolean;
|
|
300
|
+
ordersFormatted?: any;
|
|
301
|
+
handleChangeOrderStatus?: () => void;
|
|
302
|
+
handleSendCustomerReview?: () => void;
|
|
303
|
+
orderDetailsProps?: any;
|
|
296
304
|
}
|
|
297
305
|
export interface ActiveOrdersParams {
|
|
298
306
|
orders?: any;
|
|
@@ -390,6 +398,7 @@ export interface ProductItemAccordionParams {
|
|
|
390
398
|
offsetDisabled?: any;
|
|
391
399
|
isFromCheckout?: any;
|
|
392
400
|
isClickableEvent?: any;
|
|
401
|
+
currency?: any;
|
|
393
402
|
}
|
|
394
403
|
export interface ReviewOrderParams {
|
|
395
404
|
order?: { orderId: number; businessId: number; logo: string };
|
|
@@ -405,7 +414,7 @@ export interface MessagesParams {
|
|
|
405
414
|
order?: any;
|
|
406
415
|
orderId?: number;
|
|
407
416
|
messages?: any;
|
|
408
|
-
message
|
|
417
|
+
message: string;
|
|
409
418
|
image?: string;
|
|
410
419
|
messagesToShow?: any;
|
|
411
420
|
sendMessage?: any;
|
|
@@ -550,24 +559,28 @@ export interface AcceptOrRejectOrderParams {
|
|
|
550
559
|
loading?: boolean;
|
|
551
560
|
action: string;
|
|
552
561
|
orderId?: number;
|
|
553
|
-
handleUpdateOrder?: (
|
|
562
|
+
handleUpdateOrder?: (p1: any, p2: any) => {};
|
|
554
563
|
notShowCustomerPhone?: boolean | undefined;
|
|
555
|
-
actions?:
|
|
564
|
+
actions?: any;
|
|
556
565
|
titleAccept?: textTranslate;
|
|
557
566
|
titleReject?: textTranslate;
|
|
558
567
|
titleNotReady?: textTranslate;
|
|
559
568
|
appTitle?: textTranslate;
|
|
560
569
|
orderTitle?: any
|
|
570
|
+
isPage?: boolean
|
|
571
|
+
navigation?: any
|
|
572
|
+
route?: any
|
|
561
573
|
}
|
|
562
574
|
|
|
563
575
|
export interface MapViewParams {
|
|
564
|
-
onNavigationRedirect: (page
|
|
576
|
+
onNavigationRedirect: (page: string, params?: any) => void,
|
|
565
577
|
getBusinessLocations: () => void,
|
|
578
|
+
setDriverLocation: (location: any) => void,
|
|
566
579
|
isLoadingBusinessMarkers?: boolean,
|
|
567
580
|
markerGroups: Array<any>,
|
|
568
581
|
customerMarkerGroups: Array<any>,
|
|
569
582
|
alertState: { open: boolean, content: Array<string>, key?: string | null },
|
|
570
|
-
setAlertState: ({open, content, key}
|
|
583
|
+
setAlertState: ({ open, content, key }: { open: boolean, content: Array<string>, key?: string | null }) => void
|
|
571
584
|
}
|
|
572
585
|
|
|
573
586
|
export interface ReviewCustomerParams {
|
|
@@ -578,6 +591,7 @@ export interface ReviewCustomerParams {
|
|
|
578
591
|
actionState?: any,
|
|
579
592
|
handleChangeQualification?: any,
|
|
580
593
|
handleSendCustomerReview?: any,
|
|
594
|
+
handleCustomCustomerReview?: any,
|
|
581
595
|
}
|
|
582
596
|
|
|
583
597
|
export interface NoNetworkParams {
|