aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/module/Combobox.jsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/module/Combobox.jsx')
-rw-r--r--src/module/Combobox.jsx6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/module/Combobox.jsx b/src/module/Combobox.jsx
index 7374b39..f1e7c5b 100644
--- a/src/module/Combobox.jsx
+++ b/src/module/Combobox.jsx
@@ -79,7 +79,8 @@ const Combobox = React.createClass({
79 }, 79 },
80 80
81 getMinuteSelect(minute) { 81 getMinuteSelect(minute) {
82 const { prefixCls, minuteOptions, disabledMinutes, value } = this.props; 82 const { prefixCls, minuteOptions, disabledMinutes } = this.props;
83 const value = this.props.value || this.getNow();
83 const disabledOptions = disabledMinutes(value.getHourOfDay()); 84 const disabledOptions = disabledMinutes(value.getHourOfDay());
84 85
85 return ( 86 return (
@@ -95,10 +96,11 @@ const Combobox = React.createClass({
95 }, 96 },
96 97
97 getSecondSelect(second) { 98 getSecondSelect(second) {
98 const { prefixCls, secondOptions, disabledSeconds, showSecond, value } = this.props; 99 const { prefixCls, secondOptions, disabledSeconds, showSecond } = this.props;
99 if (!showSecond) { 100 if (!showSecond) {
100 return null; 101 return null;
101 } 102 }
103 const value = this.props.value || this.getNow();
102 const disabledOptions = disabledSeconds(value.getHourOfDay(), value.getMinutes()); 104 const disabledOptions = disabledSeconds(value.getHourOfDay(), value.getMinutes());
103 105
104 return ( 106 return (