Automating the LBAC module Installation.

Week 01 [May 27, 2019 — June 02, 2019]

May 31 · 2 min read

Location Based Access Control

I have successfully completed the Task and the pull request was created.

  • LBAC-20: Automating the module installation requirements.

Installation of LBAC requires the Person to have a PersonAttributeType to store the location attribute of the person. A PersonAttribute is an attribute to store the UUID value of an Entity in the corresponding table based on the PersonAttributeType. PersonAttributeType describes the value the attribute is used to store. Example Citizenship, Location, BirthPlace etc..

Every User has user properties. The Location is assigned to a user and stored as a user property. Every User Property for a user are stored using Map Data-Structure as Map<key ,value> the value here is again a UUID point to an entity in the corresponding table, the key (String) is to know the table pointed to.

Here we use constant value as Key to store the location property of the user. OpenMRS provides to maintain a list of global properties in the system. we use this global property value to get the location of a user also the same value can be used for other apps installed in OpenMRS to access the Location of the user.

To Install this Module User has to perform

  1. create a PersonAttributeType describing the person attribute which stores the location information of the patients
  2. Add Global Property used to get the user Location Property value.

Above changes can be done programmatically before installation of the module using BaseModuleActivator class.

You can follow this talk forum to get more discussions about this section

After this ticket, I started to work on

  • LBAC-33: Allowing User to have more than one Location.
User can select Multiple Locations


Written by

Senior Undergraduate in Computer Science at IIT(BHU) Varanasi