apaajabolehd / react-native-range-datepicker

react native range datepicker inspired by Airbnb
84 stars 53 forks source link

Old Dates #15

Open Marciomacdev opened 6 years ago

Marciomacdev commented 6 years ago

How can I select old dates ?

shahbazmancho commented 6 years ago

Hi , is it working ?

shahbazmancho commented 6 years ago

can you please tell me how can i get start and until dates?

Marciomacdev commented 6 years ago

Hi! @ShaBax I You can do it ! It works fine for DatepickerRange. onConfirm={ (start, until) => { // this.setState({startDate: start, untilDate:until}); }}

shahbazmancho commented 6 years ago

Thanks for reply yeah i check that but it giving me wrong date

shahbazmancho commented 6 years ago

screen shot 2018-07-02 at 8 07 11 pm screen shot 2018-07-02 at 8 07 22 pm
HusseinElGanzory commented 5 years ago

I use code below

 onConfirm= {(startDate, untilDate) => //alert( new Date(startDate).toLocaleDateString("en-US"))
          this.setState({ startDate:new Date(startDate).toLocaleDateString("en-US"), untilDate:new Date(untilDate).toLocaleDateString("en-US"), openDatepicker: false })

It return correctly date