Use week year

Fix #9463
This commit is contained in:
Wei Zhu 2018-03-01 17:24:06 +08:00
parent 9634bea391
commit 1b3118e1dc
2 changed files with 2 additions and 2 deletions

View File

@ -11,7 +11,7 @@ function formatValue(value: moment.Moment | null, format: string): string {
export default class WeekPicker extends React.Component<any, any> {
static defaultProps = {
format: 'YYYY-wo',
format: 'gggg-wo',
allowClear: true,
};

View File

@ -14,7 +14,7 @@ const MonthPicker = wrapPicker(createPicker(MonthCalendar), 'YYYY-MM');
Object.assign(DatePicker, {
RangePicker: wrapPicker(RangePicker),
MonthPicker,
WeekPicker: wrapPicker(WeekPicker, 'YYYY-wo'),
WeekPicker: wrapPicker(WeekPicker, 'gggg-wo'),
});
export default DatePicker as DatePickerDecorator;