View Full Version : Using Umm-Al-Qura calendar with DateField

6 Sep 2015, 10:28 PM

I posted a similar question on how use a differrent (Umm-Al-Qura) calendar as datepicker in Ext 4:


I answerer recommended to override the createPicker method of
Ext.form.field.Picker (http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.form.field.Picker-method-createPicker)

Is it somehow possible to achieve this in ext 3.x (specifically 3.4)? Since Ext.form.field.Picker was introduced in Ext 4, to extend datefield somehow and 'make' it use a different calendar for datepicker?
Any help or recommendation where to start is more than welcome.

8 Sep 2015, 12:55 PM
You may look into the onRender method of Ext.DatePicker: http://docs.sencha.com/extjs/3.4.0/source/DatePicker.html#Ext-DatePicker-method-onRender

8 Sep 2015, 10:51 PM

I looked into it, but the only thing I was able to do is to change day and month names. In this calendar months have different number of days, for example, first day has 30 days, not 31 like in Gregorian etc. Is there any way I can change this?

10 Sep 2015, 1:54 PM
You may want to check out this library: https://github.com/talomaireeni/Umm-Al-Qura-CalendarThat should at least get you started on being able to manipulate the dates properly. Then you could re-write the calendar template to conform to those dates.

10 Sep 2015, 10:22 PM
Hi Tristan,

can you be a bit more specific please? As someone very new to EXTjs, I'm not sure what to override to create a new calendar template. Can you provide maybe links to documentation of the methods / controls I should override and take a look at?