date null is meaning value

This commit is contained in:
afc163 2015-10-29 19:37:39 +08:00
parent 0c96016708
commit bd61bad5ee

View File

@ -84,13 +84,13 @@ function createPicker(TheCalendar) {
return date;
}
}
return null;
return undefined;
},
// remove input readonly warning
handleInputChange() {},
handleChange(value) {
this.setState({ value });
const timeValue = value ? new Date(value.getTime()) : null;
const timeValue = value ? new Date(value.getTime()) : undefined;
// onSelect .
if (this.props.onSelect) {
require('util-deprecate')(this.props.onSelect, 'onSelect property of Datepicker is deprecated, use onChange instead')(timeValue);