-
Notifications
You must be signed in to change notification settings - Fork 395
Open
Description
I have seen the FAQ on iOS, onConfirm does NOT return the picked date. However, I am having this issue no matter when the "Confirm" button is clicked.
Current Versions:
"react-native": "0.77.0",
"@react-native-community/datetimepicker": "^8.3.0",
"react-native-modal-datetime-picker": "^18.0.0",
An older version of my code is working fine. It uses the following versions:
"react-native": "0.73.6",
"@react-native-community/datetimepicker": "^7.6.3",
"react-native-modal-datetime-picker": "^17.1.0",
<DateTimePickerModal
isVisible={state.isFromDatePickerVisible}
mode={"date"}
display="default"
isDarkModeEnabled={theme.colors.themeMode === "dark"}
pickerComponentStyleIOS={{height: customTheme.sizes.defaultFontSize * 3}}
date={props.oJob.jobDayBasedFromDate}
onConfirm={(value) => {
// console.log("from date - onConfirm - ", "value:", value, value.toISOString()); // this does NOT provide the picked date!
dispatch({ type: "hide_from_date_picker", });
// code to store the picked date to props.oJob.jobDayBasedFromDate comes here
}}
onCancel={() => { dispatch({ type: "hide_from_date_picker", }); }}
/>
jesuscc1993, bobzurad, tuannguyenhoangit-droid, tarajima, lecramfriedrich and 1 more
Metadata
Metadata
Assignees
Labels
No labels