Skip to content
Snippets Groups Projects
Commit dc90f0a4 authored by Natthawat Singkala's avatar Natthawat Singkala
Browse files

picker

parent 23e8614d
No related branches found
No related tags found
No related merge requests found
...@@ -15,7 +15,7 @@ const generateConfig: GenerateConfig<Moment> = { ...@@ -15,7 +15,7 @@ const generateConfig: GenerateConfig<Moment> = {
const clone = date.clone().locale('en_US'); const clone = date.clone().locale('en_US');
return clone.weekday() + clone.localeData().firstDayOfWeek(); return clone.weekday() + clone.localeData().firstDayOfWeek();
}, },
getYear: date => date.year(), getYear: date => parseInt(date.format('BBBB')),
getMonth: date => date.month(), getMonth: date => date.month(),
getDate: date => date.date(), getDate: date => date.date(),
getHour: date => date.hour(), getHour: date => date.hour(),
...@@ -37,7 +37,7 @@ const generateConfig: GenerateConfig<Moment> = { ...@@ -37,7 +37,7 @@ const generateConfig: GenerateConfig<Moment> = {
}, },
setYear: (date, year) => { setYear: (date, year) => {
const clone = date.clone(); const clone = date.clone();
return clone.year(year); return clone.year(year + 543);
}, },
setMonth: (date, month) => { setMonth: (date, month) => {
const clone = date.clone(); const clone = date.clone();
......
...@@ -14,10 +14,10 @@ const locale: Locale = { ...@@ -14,10 +14,10 @@ const locale: Locale = {
monthSelect: 'เลือกเดือน', monthSelect: 'เลือกเดือน',
yearSelect: 'เลือกปี', yearSelect: 'เลือกปี',
decadeSelect: 'เลือกทศวรรษ', decadeSelect: 'เลือกทศวรรษ',
yearFormat: 'YYYY', yearFormat: 'BBBB',
dateFormat: 'D/M/YYYY', dateFormat: 'D/M/BBBB',
dayFormat: 'D', dayFormat: 'D',
dateTimeFormat: 'D/M/YYYY HH:mm:ss', dateTimeFormat: 'D/M/BBBB HH:mm:ss',
monthBeforeYear: true, monthBeforeYear: true,
previousMonth: 'เดือนก่อนหน้า (PageUp)', previousMonth: 'เดือนก่อนหน้า (PageUp)',
nextMonth: 'เดือนถัดไป (PageDown)', nextMonth: 'เดือนถัดไป (PageDown)',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment