dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #21987
Non-gregorian calendar systems
Hi Devs,
I have a question regarding non-Gregorian (Western) calendar systems. This
issue has come up in a couple of different places which I know of, namely
Ethiopia (Ethiopian calendar) and Afghanistan (Solar Hijri calendar).
Currently, the system only supports a Gregorian calendar system, but I am
trying to think of ways how we can support different ones, specifically
the Bikram Sambat (BS) calendar system used in Nepal.
There appears to be no easy way to convert between a Gregorian calendar. I
dug out some code here
<https://github.com/bahadurbaniya/Date-Converter-Bikram-Sambat-to-English-Date>
which
will convert between Gregorian dates and BS dates (but not the other way
around). The approach is to use a look-up table, because of the fact that
it seems to be difficult (if not impossible) to calculate the
conversion algorithmically.
This leads me to my question. Would it be possible that we consider adding
a "Calendar system" to the application. The default would be "Gregorian",
which is currently the case. The Second alternative might be "Bikram
Sambat". This would require someone to prepopulate the system with periods
(BS months, quarters and years) which would be calculated through some
other means (common Lisp code
here<http://emr.cs.uiuc.edu/~reingold/calendar.l> which
may be able to do this). These would be in Gregorian periods, but instead
of the system calculating future periods, they would have to be
pre-calculated and entered/imported into the system somehow.
The second part of this (which I think may be more difficult) is the use of
the JavaScript Gregorian calendar throughout the system. For data entry of
aggregate data, it would not to be too problematic. But for the tracker
module (and other places in the system), a Gregorian Javascript widget is
used, and it would seem to be potentially difficult to replace this.
Could the developers comment on feasibility and possible level of effort?
Best regards,
Jason
Follow ups