miguelalarcos:react-datetime-picker

v0.1.9Published 10 years ago

This package has not had recent updates. Please investigate it's current state before committing to using it in your project.

react-datetime-pcicker

A date-time picker for React.

Example of use:

A = ReactMeteor.createClass
    mixins: [DTP.changeDataMx]
    getInitialState: ->
        date: new Date()
        date2: 
            date: new Date()
    templateName: 'A'
    render: ->
        <div>
            <DTP.DateTimePicker changeData=this.changeDate('date') value=this.state.date time=true format='DD-MM-YYYY HH:mm'/>
            <DTP.DateTimePicker changeData=this.changeDate('date2.date') value=this.state.date2.date time=false format='DD-MM-YYYY'/>
        </div>

ChangeData is a callback to modify the date from a child.