ordering-ui-react-native 0.21.49-test → 0.21.49-test-v2
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 +2 -3
- package/themes/business/index.tsx +0 -5
- package/themes/business/src/components/AcceptOrRejectOrder/index.tsx +9 -2
- package/themes/business/src/components/FloatingButton/index.tsx +34 -31
- package/themes/business/src/components/MapView/index.tsx +6 -2
- package/themes/business/src/components/MessagesOption/index.tsx +2 -1
- package/themes/business/src/components/OrderDetails/Delivery.tsx +11 -6
- package/themes/business/src/components/OrderDetails/OrderHeaderComponent.tsx +12 -0
- package/themes/business/src/components/OrderDetailsLogistic/index.tsx +6 -1
- package/themes/business/src/components/OrderSummary/index.tsx +3 -10
- package/themes/business/src/components/OrdersListManager/index.tsx +7 -2
- package/themes/business/src/components/OrdersOption/index.tsx +4 -0
- package/themes/business/src/components/PreviousOrders/OrderList.tsx +17 -12
- package/themes/business/src/components/PreviousOrders/index.tsx +77 -65
- package/themes/business/src/components/WebsocketStatus/index.tsx +171 -0
- package/themes/business/src/components/WebsocketStatus/styles.tsx +28 -0
- package/themes/kiosk/src/components/LoginForm/index.tsx +7 -4
- package/themes/original/index.tsx +6 -2
- package/themes/original/src/components/AddressForm/index.tsx +2 -2
- package/themes/original/src/components/AddressForm/styles.tsx +1 -1
- package/themes/original/src/components/AddressList/styles.tsx +4 -4
- package/themes/original/src/components/BusinessBasicInformation/index.tsx +2 -2
- package/themes/original/src/components/BusinessBasicInformation/styles.tsx +1 -1
- package/themes/original/src/components/BusinessInformation/index.tsx +0 -1
- package/themes/original/src/components/BusinessInformation/styles.tsx +2 -2
- package/themes/original/src/components/BusinessItemAccordion/index.tsx +11 -7
- package/themes/original/src/components/BusinessListingSearch/index.tsx +2 -3
- package/themes/original/src/components/BusinessListingSearch/styles.tsx +1 -1
- package/themes/original/src/components/BusinessPreorder/index.tsx +2 -2
- package/themes/original/src/components/BusinessProductsCategories/index.tsx +1 -1
- package/themes/original/src/components/BusinessProductsList/index.tsx +2 -2
- package/themes/original/src/components/BusinessProductsListing/index.tsx +12 -8
- package/themes/original/src/components/BusinessProductsListing/styles.tsx +2 -2
- package/themes/original/src/components/BusinessReviews/index.tsx +1 -1
- package/themes/original/src/components/BusinessesListing/Layout/Appointment/index.tsx +1 -1
- package/themes/original/src/components/BusinessesListing/Layout/Appointment/styles.tsx +5 -5
- package/themes/original/src/components/BusinessesListing/Layout/Original/FlatListBusinessListFooter.tsx +69 -0
- package/themes/original/src/components/BusinessesListing/Layout/Original/FlatListBusinessListHeader.tsx +406 -0
- package/themes/original/src/components/BusinessesListing/Layout/Original/FlatListBusinessListing.tsx +76 -0
- package/themes/original/src/components/BusinessesListing/Layout/Original/index.tsx +23 -403
- package/themes/original/src/components/BusinessesListing/Layout/Original/styles.tsx +1 -1
- package/themes/original/src/components/Cart/index.tsx +15 -4
- package/themes/original/src/components/CartContent/index.tsx +59 -38
- package/themes/original/src/components/CartStoresListing/styles.tsx +2 -2
- package/themes/original/src/components/Checkout/index.tsx +47 -9
- package/themes/original/src/components/Checkout/styles.tsx +17 -0
- package/themes/original/src/components/CitiesControl/styles.tsx +1 -1
- package/themes/original/src/components/DatePicker/index.tsx +17 -0
- package/themes/original/src/components/DatePicker/styles.tsx +20 -0
- package/themes/original/src/components/Favorite/index.tsx +1 -3
- package/themes/original/src/components/Favorite/styles.tsx +0 -2
- package/themes/original/src/components/FloatingButton/styles.tsx +1 -1
- package/themes/original/src/components/GPSButton/index.tsx +1 -1
- package/themes/original/src/components/GiftCard/GiftCardUI/index.tsx +8 -3
- package/themes/original/src/components/GiftCard/PurchaseGiftCard/index.tsx +36 -3
- package/themes/original/src/components/GiftCard/PurchaseGiftCard/styles.tsx +1 -1
- package/themes/original/src/components/GiftCard/RedeemGiftCard/index.tsx +67 -4
- package/themes/original/src/components/GiftCard/RedeemGiftCard/styles.tsx +1 -1
- package/themes/original/src/components/GiftCard/SendGiftCard/styles.tsx +1 -1
- package/themes/original/src/components/HighestRatedBusinesses/index.tsx +1 -1
- package/themes/original/src/components/HighestRatedBusinesses/styles.tsx +1 -1
- package/themes/original/src/components/Home/index.tsx +1 -1
- package/themes/original/src/components/LastOrder/index.tsx +2 -1
- package/themes/original/src/components/LastOrders/index.tsx +2 -1
- package/themes/original/src/components/Messages/styles.tsx +1 -1
- package/themes/original/src/components/MomentOption/index.tsx +3 -3
- package/themes/original/src/components/MultiCart/index.tsx +1 -1
- package/themes/original/src/components/MultiCheckout/index.tsx +140 -18
- package/themes/original/src/components/MultiOrdersDetails/index.tsx +1 -1
- package/themes/original/src/components/MyOrders/index.tsx +5 -5
- package/themes/original/src/components/NavBar/index.tsx +0 -1
- package/themes/original/src/components/NetworkError/styles.tsx +2 -2
- package/themes/original/src/components/Notifications/index.tsx +2 -4
- package/themes/original/src/components/Notifications/styles.tsx +0 -1
- package/themes/original/src/components/OrderDetails/OrderHistory.tsx +1 -1
- package/themes/original/src/components/OrderDetails/index.tsx +709 -664
- package/themes/original/src/components/OrderDetails/styles.tsx +24 -7
- package/themes/original/src/components/OrderProgress/index.tsx +2 -1
- package/themes/original/src/components/OrderProgress/styles.tsx +1 -1
- package/themes/original/src/components/OrderSummary/index.tsx +3 -1
- package/themes/original/src/components/OrdersOption/PreviousBusinessOrdered/styles.tsx +1 -1
- package/themes/original/src/components/OrdersOption/PreviousProductsOrdered/styles.tsx +1 -1
- package/themes/original/src/components/OrdersOption/index.tsx +1 -1
- package/themes/original/src/components/OrdersOption/styles.tsx +1 -1
- package/themes/original/src/components/PaymentOptions/index.tsx +3 -1
- package/themes/original/src/components/ProductForm/ActionButton.tsx +117 -0
- package/themes/original/src/components/ProductForm/ExtraOptions.tsx +56 -0
- package/themes/original/src/components/ProductForm/index.tsx +52 -146
- package/themes/original/src/components/ProductItemAccordion/index.tsx +5 -0
- package/themes/original/src/components/ProductOptionSubOption/index.tsx +1 -1
- package/themes/original/src/components/ProfessionalProfile/styles.tsx +3 -3
- package/themes/original/src/components/Promotions/index.tsx +2 -3
- package/themes/original/src/components/Promotions/styles.tsx +0 -2
- package/themes/original/src/components/ReviewDriver/styles.tsx +1 -1
- package/themes/original/src/components/ReviewOrder/styles.tsx +1 -1
- package/themes/original/src/components/ReviewProducts/styles.tsx +1 -1
- package/themes/original/src/components/ServiceForm/index.tsx +1 -1
- package/themes/original/src/components/ServiceForm/styles.tsx +4 -4
- package/themes/original/src/components/StripeElementsForm/index.tsx +1 -1
- package/themes/original/src/components/UpsellingProducts/UpsellingContent.tsx +170 -0
- package/themes/original/src/components/UpsellingProducts/UpsellingLayout.tsx +86 -0
- package/themes/original/src/components/UpsellingProducts/index.tsx +15 -199
- package/themes/original/src/components/UpsellingProducts/styles.tsx +19 -0
- package/themes/original/src/components/UserFormDetails/index.tsx +51 -4
- package/themes/original/src/components/UserProfile/index.tsx +1 -1
- package/themes/original/src/components/WalletTransactions/styles.tsx +1 -0
- package/themes/original/src/components/Wallets/index.tsx +1 -0
- package/themes/original/src/components/Wallets/styles.tsx +0 -1
- package/themes/original/src/components/shared/OModal.tsx +12 -14
- package/themes/original/src/layouts/Container.tsx +1 -1
- package/themes/business/src/components/StarPrinter/SearchPrinter.tsx +0 -106
- package/themes/business/src/components/StarPrinter/index.tsx +0 -235
|
@@ -10,7 +10,7 @@ export const Header = styled.View`
|
|
|
10
10
|
background-color: ${(props: any) => props.theme.colors.white};
|
|
11
11
|
box-shadow: 0 2px 2px #0000001A;
|
|
12
12
|
padding-bottom: 10px;
|
|
13
|
-
padding-horizontal:
|
|
13
|
+
padding-horizontal: 10px;
|
|
14
14
|
`
|
|
15
15
|
|
|
16
16
|
export const TitleHeader = styled.View``
|
|
@@ -327,8 +327,8 @@ const MomentOptionUI = (props: MomentOptionParams) => {
|
|
|
327
327
|
<>
|
|
328
328
|
<Container
|
|
329
329
|
style={{
|
|
330
|
-
paddingLeft: !cateringPreorder || isPage ?
|
|
331
|
-
paddingRight: !cateringPreorder || isPage ?
|
|
330
|
+
paddingLeft: !cateringPreorder || isPage ? 20 : 0,
|
|
331
|
+
paddingRight: !cateringPreorder || isPage ? 20 : 0
|
|
332
332
|
}}
|
|
333
333
|
nestedScrollEnabled
|
|
334
334
|
>
|
|
@@ -467,7 +467,7 @@ const MomentOptionUI = (props: MomentOptionParams) => {
|
|
|
467
467
|
<Spinner visible={momentState.isLoading === 1} />
|
|
468
468
|
</Container>
|
|
469
469
|
{!isCart && !cateringPreorder && (
|
|
470
|
-
<View style={{ position: 'absolute', bottom: bottom, paddingBottom: 20, paddingHorizontal:
|
|
470
|
+
<View style={{ position: 'absolute', bottom: bottom, paddingBottom: 20, paddingHorizontal: 20, backgroundColor: 'white', width: '100%' }}>
|
|
471
471
|
<OButton onClick={() => handleChangeMoment()} isDisabled={!selectedTime} text={t('CONTINUE', 'Continue')} style={{ borderRadius: 7.6, height: 44, shadowOpacity: 0 }} textStyle={{ color: 'white', fontSize: 14 }} showNextIcon />
|
|
472
472
|
</View>
|
|
473
473
|
)}
|
|
@@ -11,7 +11,7 @@ export const MultiCartUI = () => {
|
|
|
11
11
|
const theme = useTheme();
|
|
12
12
|
return (
|
|
13
13
|
<Container noPadding>
|
|
14
|
-
<ChContainer style={{ paddingHorizontal:
|
|
14
|
+
<ChContainer style={{ paddingHorizontal: 20 }}>
|
|
15
15
|
<ChSection>
|
|
16
16
|
<ChUserDetails>
|
|
17
17
|
<Placeholder Animation={Fade}>
|
|
@@ -10,11 +10,11 @@ import {
|
|
|
10
10
|
ToastType,
|
|
11
11
|
MultiCheckout as MultiCheckoutController
|
|
12
12
|
} from 'ordering-components/native'
|
|
13
|
-
import { View, StyleSheet, Platform } from 'react-native'
|
|
13
|
+
import { View, StyleSheet, Platform, ScrollView } from 'react-native'
|
|
14
14
|
import { useTheme } from 'styled-components/native';
|
|
15
15
|
import { Container } from '../../layouts/Container';
|
|
16
16
|
import NavBar from '../NavBar';
|
|
17
|
-
import { OText, OIcon, OModal } from '../shared';
|
|
17
|
+
import { OText, OIcon, OModal, OButton } from '../shared';
|
|
18
18
|
import { getTypesText } from '../../utils';
|
|
19
19
|
import { UserDetails } from '../UserDetails'
|
|
20
20
|
import { AddressDetails } from '../AddressDetails'
|
|
@@ -26,6 +26,8 @@ import { DriverTips } from '../DriverTips'
|
|
|
26
26
|
import { CouponControl } from '../CouponControl';
|
|
27
27
|
import { DriverTipsContainer } from '../Cart/styles'
|
|
28
28
|
import { OSTable, OSCoupon } from '../OrderSummary/styles';
|
|
29
|
+
import { SignupForm } from '../SignupForm'
|
|
30
|
+
import { LoginForm } from '../LoginForm'
|
|
29
31
|
|
|
30
32
|
import {
|
|
31
33
|
ChContainer,
|
|
@@ -71,10 +73,14 @@ const MultiCheckoutUI = (props: any) => {
|
|
|
71
73
|
const theme = useTheme();
|
|
72
74
|
const styles = StyleSheet.create({
|
|
73
75
|
pagePadding: {
|
|
74
|
-
paddingLeft:
|
|
75
|
-
paddingRight:
|
|
76
|
+
paddingLeft: 20,
|
|
77
|
+
paddingRight: 20
|
|
76
78
|
},
|
|
77
|
-
wrapperNavbar: { paddingHorizontal:
|
|
79
|
+
wrapperNavbar: { paddingHorizontal: 20 },
|
|
80
|
+
detailWrapper: {
|
|
81
|
+
paddingHorizontal: 20,
|
|
82
|
+
width: '100%'
|
|
83
|
+
},
|
|
78
84
|
})
|
|
79
85
|
|
|
80
86
|
const [, { showToast }] = useToast();
|
|
@@ -83,7 +89,7 @@ const MultiCheckoutUI = (props: any) => {
|
|
|
83
89
|
const [{ parsePrice, parseDate }] = useUtils();
|
|
84
90
|
const [{ options, carts, loading }, { confirmCart }] = useOrder();
|
|
85
91
|
const [validationFields] = useValidationFields();
|
|
86
|
-
const [{ user }] = useSession()
|
|
92
|
+
const [{ user }, { login }] = useSession()
|
|
87
93
|
|
|
88
94
|
const configTypes = configs?.order_types_allowed?.value.split('|').map((value: any) => Number(value)) || []
|
|
89
95
|
const isPreOrder = configs?.preorder_status_enabled?.value === '1'
|
|
@@ -134,6 +140,11 @@ const MultiCheckoutUI = (props: any) => {
|
|
|
134
140
|
const [phoneUpdate, setPhoneUpdate] = useState(false);
|
|
135
141
|
const [userErrors, setUserErrors] = useState<any>([]);
|
|
136
142
|
const [placeByMethodPay, setPlaceByMethodPay] = useState(false)
|
|
143
|
+
const [allowedGuest, setAllowedGuest] = useState(false)
|
|
144
|
+
const [isOpen, setIsOpen] = useState(false)
|
|
145
|
+
const [requiredFields, setRequiredFields] = useState<any>([])
|
|
146
|
+
const stripePaymethods: any = ['stripe', 'stripe_direct', 'stripe_connect', 'stripe_redirect']
|
|
147
|
+
const [openModal, setOpenModal] = useState({ login: false, signup: false, isGuest: false })
|
|
137
148
|
const [methodPaySupported, setMethodPaySupported] = useState({ enabled: false, message: null, loading: true })
|
|
138
149
|
const methodsPay = ['global_google_pay', 'global_apple_pay']
|
|
139
150
|
const isDisablePlaceOrderButton = cartGroup?.loading || (!(paymethodSelected?.paymethod_id || paymethodSelected?.wallet_id) && cartGroup?.result?.balance > 0) ||
|
|
@@ -151,11 +162,12 @@ const MultiCheckoutUI = (props: any) => {
|
|
|
151
162
|
setUserErrors([])
|
|
152
163
|
const errors = []
|
|
153
164
|
const notFields = ['coupon', 'driver_tip', 'mobile_phone', 'address', 'zipcode', 'address_notes']
|
|
165
|
+
const _requiredFields: any = []
|
|
154
166
|
|
|
155
167
|
Object.values(validationFields?.fields?.checkout).map((field: any) => {
|
|
156
168
|
if (field?.required && !notFields.includes(field.code)) {
|
|
157
169
|
if (!user[field?.code]) {
|
|
158
|
-
|
|
170
|
+
_requiredFields.push(field?.code)
|
|
159
171
|
}
|
|
160
172
|
}
|
|
161
173
|
})
|
|
@@ -166,8 +178,9 @@ const MultiCheckoutUI = (props: any) => {
|
|
|
166
178
|
validationFields?.fields?.checkout?.cellphone?.required) ||
|
|
167
179
|
configs?.verification_phone_required?.value === '1')
|
|
168
180
|
) {
|
|
169
|
-
|
|
181
|
+
_requiredFields.push('cellphone')
|
|
170
182
|
}
|
|
183
|
+
setRequiredFields(_requiredFields)
|
|
171
184
|
|
|
172
185
|
if (phoneUpdate) {
|
|
173
186
|
errors.push(t('NECESSARY_UPDATE_COUNTRY_PHONE_CODE', 'It is necessary to update your phone number'))
|
|
@@ -181,10 +194,19 @@ const MultiCheckoutUI = (props: any) => {
|
|
|
181
194
|
}
|
|
182
195
|
|
|
183
196
|
const handlePlaceOrder = (confirmPayment?: any) => {
|
|
184
|
-
if (
|
|
197
|
+
if (stripePaymethods.includes(paymethodSelected?.gateway) && user?.guest_id) {
|
|
198
|
+
setOpenModal({ ...openModal, signup: true, isGuest: true })
|
|
199
|
+
return
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
if (!userErrors.length && (!requiredFields?.length || allowedGuest)) {
|
|
185
203
|
handleGroupPlaceOrder && handleGroupPlaceOrder(confirmPayment)
|
|
186
204
|
return
|
|
187
205
|
}
|
|
206
|
+
if (requiredFields?.length) {
|
|
207
|
+
setIsOpen(true)
|
|
208
|
+
return
|
|
209
|
+
}
|
|
188
210
|
let stringError = ''
|
|
189
211
|
Object.values(userErrors).map((item: any, i: number) => {
|
|
190
212
|
stringError += (i + 1) === userErrors.length ? `- ${item?.message || item}` : `- ${item?.message || item}\n`
|
|
@@ -193,6 +215,24 @@ const MultiCheckoutUI = (props: any) => {
|
|
|
193
215
|
setIsUserDetailsEdit(true)
|
|
194
216
|
}
|
|
195
217
|
|
|
218
|
+
const handlePlaceOrderAsGuest = () => {
|
|
219
|
+
setIsOpen(false)
|
|
220
|
+
handleGroupPlaceOrder && handleGroupPlaceOrder()
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
const handleSuccessSignup = (user: any) => {
|
|
224
|
+
login({
|
|
225
|
+
user,
|
|
226
|
+
token: user?.session?.access_token
|
|
227
|
+
})
|
|
228
|
+
openModal?.isGuest && handlePlaceOrderAsGuest()
|
|
229
|
+
setOpenModal({ ...openModal, signup: false, isGuest: false })
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
const handleSuccessLogin = (user: any) => {
|
|
233
|
+
if (user) setOpenModal({ ...openModal, login: false })
|
|
234
|
+
}
|
|
235
|
+
|
|
196
236
|
useEffect(() => {
|
|
197
237
|
if (validationFields && validationFields?.fields?.checkout) {
|
|
198
238
|
checkValidationFields()
|
|
@@ -285,15 +325,45 @@ const MultiCheckoutUI = (props: any) => {
|
|
|
285
325
|
|
|
286
326
|
<ChSection>
|
|
287
327
|
<ChUserDetails>
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
328
|
+
{(user?.guest_id && !allowedGuest) ? (
|
|
329
|
+
<View>
|
|
330
|
+
<OText size={14} numberOfLines={1} ellipsizeMode='tail' color={theme.colors.textNormal}>
|
|
331
|
+
{t('CUSTOMER_DETAILS', 'Customer details')}
|
|
332
|
+
</OText>
|
|
333
|
+
<OButton
|
|
334
|
+
text={t('SIGN_UP', 'Sign up')}
|
|
335
|
+
textStyle={{ color: theme.colors.white }}
|
|
336
|
+
style={{ borderRadius: 7.6, marginTop: 20 }}
|
|
337
|
+
onClick={() => setOpenModal({ ...openModal, signup: true })}
|
|
338
|
+
/>
|
|
339
|
+
<OButton
|
|
340
|
+
text={t('LOGIN', 'Login')}
|
|
341
|
+
textStyle={{ color: theme.colors.primary }}
|
|
342
|
+
bgColor={theme.colors.white}
|
|
343
|
+
borderColor={theme.colors.primary}
|
|
344
|
+
style={{ borderRadius: 7.6, marginTop: 20 }}
|
|
345
|
+
onClick={() => setOpenModal({ ...openModal, login: true })}
|
|
346
|
+
/>
|
|
347
|
+
<OButton
|
|
348
|
+
text={t('CONTINUE_AS_GUEST', 'Continue as guest')}
|
|
349
|
+
textStyle={{ color: theme.colors.black }}
|
|
350
|
+
bgColor={theme.colors.white}
|
|
351
|
+
borderColor={theme.colors.black}
|
|
352
|
+
style={{ borderRadius: 7.6, marginTop: 20 }}
|
|
353
|
+
onClick={() => setAllowedGuest(true)}
|
|
354
|
+
/>
|
|
355
|
+
</View>
|
|
356
|
+
) : (
|
|
357
|
+
<UserDetails
|
|
358
|
+
isUserDetailsEdit={isUserDetailsEdit}
|
|
359
|
+
useValidationFields
|
|
360
|
+
useDefualtSessionManager
|
|
361
|
+
useSessionUser
|
|
362
|
+
isCheckout
|
|
363
|
+
phoneUpdate={phoneUpdate}
|
|
364
|
+
togglePhoneUpdate={togglePhoneUpdate}
|
|
365
|
+
/>
|
|
366
|
+
)}
|
|
297
367
|
</ChUserDetails>
|
|
298
368
|
<View style={{ height: 8, backgroundColor: theme.colors.backgroundGray100, marginHorizontal: -40 }} />
|
|
299
369
|
</ChSection>
|
|
@@ -484,6 +554,58 @@ const MultiCheckoutUI = (props: any) => {
|
|
|
484
554
|
</OText>
|
|
485
555
|
)}
|
|
486
556
|
</ChContainer>
|
|
557
|
+
<OModal
|
|
558
|
+
open={openModal.signup}
|
|
559
|
+
onClose={() => setOpenModal({ ...openModal, signup: false, isGuest: false })}
|
|
560
|
+
>
|
|
561
|
+
<ScrollView style={{ paddingHorizontal: 20, width: '100%' }}>
|
|
562
|
+
<SignupForm
|
|
563
|
+
handleSuccessSignup={handleSuccessSignup}
|
|
564
|
+
isGuest
|
|
565
|
+
signupButtonText={t('SIGNUP', 'Signup')}
|
|
566
|
+
useSignupByEmail
|
|
567
|
+
useChekoutFileds
|
|
568
|
+
/>
|
|
569
|
+
</ScrollView>
|
|
570
|
+
</OModal>
|
|
571
|
+
<OModal
|
|
572
|
+
open={openModal.login}
|
|
573
|
+
onClose={() => setOpenModal({ ...openModal, login: false })}
|
|
574
|
+
>
|
|
575
|
+
<ScrollView style={{ paddingHorizontal: 20, width: '100%' }}>
|
|
576
|
+
<LoginForm
|
|
577
|
+
handleSuccessLogin={handleSuccessLogin}
|
|
578
|
+
isGuest
|
|
579
|
+
loginButtonText={t('LOGIN', 'Login')}
|
|
580
|
+
loginButtonBackground={theme.colors.primary}
|
|
581
|
+
/>
|
|
582
|
+
</ScrollView>
|
|
583
|
+
</OModal>
|
|
584
|
+
<OModal
|
|
585
|
+
open={isOpen}
|
|
586
|
+
onClose={() => setIsOpen(false)}
|
|
587
|
+
>
|
|
588
|
+
<View style={styles.detailWrapper}>
|
|
589
|
+
<UserDetails
|
|
590
|
+
isUserDetailsEdit
|
|
591
|
+
useValidationFields
|
|
592
|
+
useDefualtSessionManager
|
|
593
|
+
useSessionUser
|
|
594
|
+
isCheckout
|
|
595
|
+
isEdit
|
|
596
|
+
phoneUpdate={phoneUpdate}
|
|
597
|
+
togglePhoneUpdate={togglePhoneUpdate}
|
|
598
|
+
requiredFields={requiredFields}
|
|
599
|
+
hideUpdateButton
|
|
600
|
+
handlePlaceOrderAsGuest={handlePlaceOrderAsGuest}
|
|
601
|
+
onClose={() => {
|
|
602
|
+
setIsOpen(false)
|
|
603
|
+
handlePlaceOrder()
|
|
604
|
+
}}
|
|
605
|
+
setIsOpen={setIsOpen}
|
|
606
|
+
/>
|
|
607
|
+
</View>
|
|
608
|
+
</OModal>
|
|
487
609
|
</Container>
|
|
488
610
|
|
|
489
611
|
<FloatingButton
|
|
@@ -93,7 +93,7 @@ export const MultiOrdersDetailsUI = (props: any) => {
|
|
|
93
93
|
}, [])
|
|
94
94
|
|
|
95
95
|
return (
|
|
96
|
-
<OrdersDetailsContainer keyboardShouldPersistTaps="handled" contentContainerStyle={{ paddingHorizontal:
|
|
96
|
+
<OrdersDetailsContainer keyboardShouldPersistTaps="handled" contentContainerStyle={{ paddingHorizontal: 20 }}>
|
|
97
97
|
<View style={{ flexDirection: 'row' }}>
|
|
98
98
|
<OButton
|
|
99
99
|
imgRightSrc={null}
|
|
@@ -87,7 +87,7 @@ export const MyOrders = (props: any) => {
|
|
|
87
87
|
display: 'flex',
|
|
88
88
|
flexDirection: 'row',
|
|
89
89
|
alignItems: 'center',
|
|
90
|
-
paddingHorizontal:
|
|
90
|
+
paddingHorizontal: 20,
|
|
91
91
|
},
|
|
92
92
|
...props.titleStyle
|
|
93
93
|
}}>
|
|
@@ -124,7 +124,7 @@ export const MyOrders = (props: any) => {
|
|
|
124
124
|
<ScrollView
|
|
125
125
|
horizontal
|
|
126
126
|
style={{ ...styles.container, borderBottomWidth: 1 }}
|
|
127
|
-
contentContainerStyle={{ paddingHorizontal: !!businessesSearchList ? 0 :
|
|
127
|
+
contentContainerStyle={{ paddingHorizontal: !!businessesSearchList ? 0 : 20 }}
|
|
128
128
|
showsHorizontalScrollIndicator={false}
|
|
129
129
|
scrollEventThrottle={16}
|
|
130
130
|
>
|
|
@@ -148,7 +148,7 @@ export const MyOrders = (props: any) => {
|
|
|
148
148
|
)}
|
|
149
149
|
{selectedOption === 'orders' && (
|
|
150
150
|
<>
|
|
151
|
-
<View style={{ paddingHorizontal:
|
|
151
|
+
<View style={{ paddingHorizontal: 20 }}>
|
|
152
152
|
<OrdersOption
|
|
153
153
|
{...props}
|
|
154
154
|
preOrders
|
|
@@ -158,7 +158,7 @@ export const MyOrders = (props: any) => {
|
|
|
158
158
|
refreshOrders={refreshOrders}
|
|
159
159
|
/>
|
|
160
160
|
</View>
|
|
161
|
-
<View style={{ paddingHorizontal:
|
|
161
|
+
<View style={{ paddingHorizontal: 20 }}>
|
|
162
162
|
<OrdersOption
|
|
163
163
|
{...props}
|
|
164
164
|
activeOrders
|
|
@@ -168,7 +168,7 @@ export const MyOrders = (props: any) => {
|
|
|
168
168
|
refreshOrders={refreshOrders}
|
|
169
169
|
/>
|
|
170
170
|
</View>
|
|
171
|
-
<View style={{ paddingHorizontal:
|
|
171
|
+
<View style={{ paddingHorizontal: 20 }}>
|
|
172
172
|
<OrdersOption
|
|
173
173
|
{...props}
|
|
174
174
|
ordersLength={ordersLength}
|
|
@@ -2,10 +2,10 @@ import styled from 'styled-components/native'
|
|
|
2
2
|
|
|
3
3
|
export const Container = styled.View`
|
|
4
4
|
flex: 1;
|
|
5
|
-
padding: 20px
|
|
5
|
+
padding: 20px;
|
|
6
6
|
`
|
|
7
7
|
export const ImageContainer = styled.View`
|
|
8
8
|
flex: 1;
|
|
9
9
|
align-items: center;
|
|
10
10
|
justify-content: center;
|
|
11
|
-
`
|
|
11
|
+
`
|
|
@@ -75,10 +75,8 @@ const NotificationsUI = (props: any) => {
|
|
|
75
75
|
titleAlign={'center'}
|
|
76
76
|
onActionLeft={goToBack}
|
|
77
77
|
showCall={false}
|
|
78
|
-
style={{
|
|
79
|
-
|
|
80
|
-
paddingVertical: 0,
|
|
81
|
-
}}
|
|
78
|
+
style={{ paddingVertical: 0 }}
|
|
79
|
+
btnStyle={{ paddingLeft: 0 }}
|
|
82
80
|
/>
|
|
83
81
|
{showCustomerPromotions && showNotifications && (
|
|
84
82
|
<>
|