This Blog tells us about the Persian Datepicker in Oracle APEX.
We have some issues when we want to have native Persian datepicker:
- Default Datepicker is Gregorian
- Old jQuery Versions Desupported(1.7.1) APEX 18+
- Gregorian Datepicker to Persian Datepicker
- Persian Datepicker with Interactive Grid(IG)
A major issue is when we want to use the datepicker item with Interactive Grid at a same page, because conflict occurs.
Finally, These issues were solved and you should follow below instruction if you would like to use the Persian Datepicker in Oracle APEX. In addition, I have tested on APEX 5.1,18
Adding JS Files
To upload js files via APEXPersianDatepicker
Set NLS DATE
You need to change NLS_CALENDAR , NLS_DATE_FORMAT [Application / Edit Security Attributes(Database Session)]
Call Persian DatepickerBEGINEXECUTE immediate 'ALTER SESSION SET NLS_CALENDAR=PERSIAN';
EXECUTE immediate 'ALTER SESSION SET NLS_DATE_FORMAT=''YYYY/MM/DD''';
END;
You should make a copy from [standard] template and create a new template for example "standard-fix-date" because we must add some codes to "Execute when Page Loads" part.
$(window).load(function () {
apexrad.util.loadjscssFile("#APP_IMAGES#apexrad-datepicker-fa.min.js", "js")
});
Tips : Application Primary Language must be [Farsi(fa)]
Now, run your application and see Jalali date via Item datepicker.
Enjoy it!
Great And valuable Post, Hope see more post of you soon.
ReplyDeleteThanks
Today button does not work.
ReplyDeleteIt does not select date of today.
Thenks