Determining which module to adjust

Is there a way to easily determine which module controls a specific part of the application?

For example, I want to change the OpenMRS logo. I wasn’t sure which module controls the logo being displayed but eventually I found this module: GitHub - openmrs/openmrs-module-referenceapplication: A module that provides the basic web features. This seemed like the correct place to make changes, so I updated the login.gsp file, added my logo to the images folder, built the module and copied over the new OMOD file into my server.

Unfortunately, i’m seeing this image

After inspecting the code, I noticed it’s still trying to reference openMrsLogo as you can see in the image below, but i’m not sure which module is referencing it. How can I find where this part of the code exists? image

This is a specific example, but this is also relevant for all other components of the application. In general, how can I determine which module I need to modify when trying to change something in the application.


@danialbet you replace the openmrs logo reference here with your new logo that you have added in the images something like

<div class= "row">
        <div class="col-12 col-sm-12 col-md-12 col-lg-12">
                <div class="logo">
                    <a href="${ui.pageLink("referenceapplication", "home")}">
                        <img src="${ui.resourceLink("referenceapplication", "images/new-logo.png")}"/>

and test it out

Thats exactly what I did but it wasn’t working. I tried doing it in a different server that is also running the reference application and it worked there though!

I noticed the openmrs logo still exists once I log in though. How can I find out which module controls that logo?

@danialbet you can have a look at this reference

1 Like

I looked at this previously, but I wasn’t sure which part you’re referring to. I noticed someone mention the UI Commons module, but I wasn’t able to find any mention of an openMrsLogo there.

I’m still confused about how I can figure out which module is responsible for each part of the application. Logo aside, how can I figure it out? I want to modify the application quite a bit and I want to understand how to identify what controls what.