Why does the program enrollment and bacteriology module subtract a day (on the date of sample collection) when you save your entered data?

Hi Bahmni team, @darius, @mseaton, @maheshonopenmrs, @bharatak

Can anyone help me understand this. On the bahmni demo server, when I enroll a patient into a program, it displays that the patient was enrolled a day ago. In my case, I enrolled a patient on 7th april, the graph show 6th April. I don’t think this is a time zone issue, why was this feature designed to work this way?

On a similar related note, on the endTB bacteriology module; When I add the sample collection date as 31st Jan, it saves it as 30th Jan.

Even after editing a recently entered sample, when I save it takes a day off (or just clicking on the edit button and you save without editing anything it takes a day off) . This is incorrect if you are either entering data retrospectively or in real time. Am I missing an important configuration here? Is this a bug that needs to be fixed?

@jmbabazi, is there something specific that makes you think this is not a time zone issue?

I have tested this on my server which is in the same timezone as my pc and I’ve tested this on 2 bahmni servers (same problem). Plus I think, if it was a time zone issue, the date would only change once, but in this case clicking on the edit button and saving without editing subtracts a day (the more you edit and save, the more the days are subtracted). Happy to demonstrate to you, at your convenience.

@jmbabazi We have fixed this issue. You will get an email from Mahesh on the build details. Thank you.