Pull request for /api/interpretations/chart/{chartId} to add new request param 'ou'

Hello,

We are planning to use ‘/api/interpretations’ API in DHIS2.23 for adding comments to charts.

We are able to create interpretation for charts and reports but, we are not able to add the organisationUnit to the interpretation for chart (/api/interpretation/chart/{chartId}) unlike the interpretation for report (/api/interpretation/reportTable/{reportId}) which accepts a request param ‘ou’. In order to provide this functionality to interpretation for chart API, we have added a non mandatory request param ‘ou’ which will accept the organisation unit similar to interpretation for report API. As mentioned, this is not a mandatory param, if it is not provided, it will fallback to the existing functionality.

We have sent a pull request with the above mentioned functionality to 2.23/2.24 and master branches. Please let us know if there is any issue.

Thanks,
Poulami/Jhansi

Hi there,

I agree this part is not great and inconsistent. Thanks for the pull requests.

I would say we should centralize this code so that we get consistency across interpretations (report table, chart, event report, event chart). I have committed a modified version of your PR here:

https://github.com/dhis2/dhis2-core/commit/dcc738794325ae6d5dcf03bf7835bb551fea4b53

Let me know if this is okay.

regards,

Lars

···

On Tue, Sep 27, 2016 at 1:33 PM, jhansi jhansirk@thoughtworks.com wrote:

Hello,

We are planning to use ‘/api/interpretations’ API in DHIS2.23 for adding comments to charts.

We are able to create interpretation for charts and reports but, we are not able to add the organisationUnit to the interpretation for chart (/api/interpretation/chart/{chartId}) unlike the interpretation for report (/api/interpretation/reportTable/{reportId}) which accepts a request param ‘ou’. In order to provide this functionality to interpretation for chart API, we have added a non mandatory request param ‘ou’ which will accept the organisation unit similar to interpretation for report API. As mentioned, this is not a mandatory param, if it is not provided, it will fallback to the existing functionality.

We have sent a pull request with the above mentioned functionality to 2.23/2.24 and master branches. Please let us know if there is any issue.

Thanks,

Poulami/Jhansi


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Lars Helge Øverland

Lead developer, DHIS 2

University of Oslo

Skype: larshelgeoverland

lars@dhis2.org

http://www.dhis2.org

Thanks Lars, it looks good. Could we also get these changes merged into 2.23 and 2.24 branches as well.

Thanks,

Jhansi

···

On 27-Sep-2016, at 5:43 pm, Lars Helge Øverland lars@dhis2.org wrote:

interpretations

Hi Lars,

Thanks for merging in our pull request. We’re planning to upgrade our DHIS instance to v2.23 and v2.24 over the coming months, so could you please apply the same changes to the 2.23 branch and 2.24 branch?

Thanks,

David

···

On Tue, Sep 27, 2016 at 5:43 PM, Lars Helge Øverland lars@dhis2.org wrote:

Hi there,

I agree this part is not great and inconsistent. Thanks for the pull requests.

I would say we should centralize this code so that we get consistency across interpretations (report table, chart, event report, event chart). I have committed a modified version of your PR here:

https://github.com/dhis2/dhis2-core/commit/dcc738794325ae6d5dcf03bf7835bb551fea4b53

Let me know if this is okay.

regards,

Lars


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

On Tue, Sep 27, 2016 at 1:33 PM, jhansi jhansirk@thoughtworks.com wrote:

Hello,

We are planning to use ‘/api/interpretations’ API in DHIS2.23 for adding comments to charts.

We are able to create interpretation for charts and reports but, we are not able to add the organisationUnit to the interpretation for chart (/api/interpretation/chart/{chartId}) unlike the interpretation for report (/api/interpretation/reportTable/{reportId}) which accepts a request param ‘ou’. In order to provide this functionality to interpretation for chart API, we have added a non mandatory request param ‘ou’ which will accept the organisation unit similar to interpretation for report API. As mentioned, this is not a mandatory param, if it is not provided, it will fallback to the existing functionality.

We have sent a pull request with the above mentioned functionality to 2.23/2.24 and master branches. Please let us know if there is any issue.

Thanks,

Poulami/Jhansi


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Lars Helge Øverland

Lead developer, DHIS 2

University of Oslo

Skype: larshelgeoverland

lars@dhis2.org

http://www.dhis2.org