fix: MonthPicker value can not change when open #1510
parent
1b78a10ee6
commit
197cad6c5f
|
@ -22,6 +22,7 @@ function showIf(condition, el) {
|
||||||
}
|
}
|
||||||
|
|
||||||
const CalendarHeader = {
|
const CalendarHeader = {
|
||||||
|
name: 'CalendarHeader',
|
||||||
mixins: [BaseMixin],
|
mixins: [BaseMixin],
|
||||||
props: {
|
props: {
|
||||||
prefixCls: PropTypes.string,
|
prefixCls: PropTypes.string,
|
||||||
|
@ -149,7 +150,7 @@ const CalendarHeader = {
|
||||||
panel = (
|
panel = (
|
||||||
<MonthPanel
|
<MonthPanel
|
||||||
locale={locale}
|
locale={locale}
|
||||||
defaultValue={value}
|
value={value}
|
||||||
rootPrefixCls={prefixCls}
|
rootPrefixCls={prefixCls}
|
||||||
onSelect={this.onMonthSelect}
|
onSelect={this.onMonthSelect}
|
||||||
onYearPanelShow={() => this.showYearPanel('month')}
|
onYearPanelShow={() => this.showYearPanel('month')}
|
||||||
|
|
|
@ -12,6 +12,7 @@ function goYear(direction) {
|
||||||
function noop() {}
|
function noop() {}
|
||||||
|
|
||||||
const MonthPanel = {
|
const MonthPanel = {
|
||||||
|
name: 'MonthPanel',
|
||||||
mixins: [BaseMixin],
|
mixins: [BaseMixin],
|
||||||
props: {
|
props: {
|
||||||
value: PropTypes.any,
|
value: PropTypes.any,
|
||||||
|
|
Loading…
Reference in New Issue