API interaction with reportTables bug?

Hey devs,

I have had some issues where suddenly saved favorites go “corrupt” in terms that they somehow lose their relative and fixed periods (and therefore will not load as pe is in dimension but no period selected). I tried through the API to identify the issue and to fix some of these tables. I found a strange issue and tested on play.dhis2.org where it show that:

If I simply GET a “reportTable” and then PUT the whole .json back with only change of the name variable. E.g. from “name”: “ANC: ANC visits 1-3 last 12 months”, to “name”: “ANC: ANC visits 1-3 last 12 months 2” a lot of un-intended changes happen.

Comparing the before and after .json below. I don’t know if I tried doing something rudimentary wrong from an REST viewpoint? If so, perhaps I shouldn’t be allowed or is it plainly a bug?

Thanks!

LEFT side is .json before adding “2” to name and immediately after PUT on RIGHT.

(…)

(…)

Thanks!

Best Regards

Halvar Trøyel Nerbø

Reporting Advisor

+47 992 39 817

Skype: nrc_troyel

www.nrc.no

nrclogo