diff --git a/components/date_picker/index.jsx b/components/date_picker/index.jsx index 6a940bb7..6d2f07cc 100644 --- a/components/date_picker/index.jsx +++ b/components/date_picker/index.jsx @@ -42,10 +42,6 @@ export default React.createClass({ return `${date.getDate()} ${time.getFullMonth(date)} ${date.getFullYear()}`; }, - getValue () { - return this.state.value; - }, - render () { return (
@@ -65,5 +61,13 @@ export default React.createClass({ />
); + }, + + getValue () { + return this.state.value; + }, + + setValue (value) { + this.setState({value: value}); } }); diff --git a/components/time_picker/index.jsx b/components/time_picker/index.jsx index 26a9158a..ee0ae2f6 100644 --- a/components/time_picker/index.jsx +++ b/components/time_picker/index.jsx @@ -44,10 +44,6 @@ export default React.createClass({ } }, - getValue () { - return this.state.value; - }, - render () { return (
@@ -68,5 +64,13 @@ export default React.createClass({ />
); + }, + + getValue () { + return this.state.value; + }, + + setValue (value) { + this.setState({value: value}); } });