[Blocker] Adding Location Based Restrictions to Reporting Rest

I want to Add Location based Restrictions to the Reports of OpenMRS as my GSoC project Objective.

I was able to understand part of the report generation module How reports are generated, Dataset Definitions things. But many of the things are not connected still are blank.

I am having the Blocker of understanding how these queries are executed and which part of reporting modules handles it.

cc: @suthagar23,@dkayiwa

Hi @vankineenitawrun,

This was the blocker when I started to do more work on this after last year also, and I haven’t touch it much. Let me check it one more time and get back to you.

In the mean time, @dkayiwa, you help is much appreciated :slight_smile:

Thanks.

Hi @suthagar23 ,

The thing is the return values of the reporting module are not a defined type of Objects to use Spring AOP as used in the LBAC module.

These are custom SQL queries so I think we need to modify the queries it self before being executed. by adding something like where locations in :locations to the query if possible.