Skip to content

Conversation

@vimla01
Copy link

@vimla01 vimla01 commented Dec 9, 2025

Requirements

  • This PR has a title that briefly describes the work done and includes the ticket number.
  • My work is validated through manual testing using an OpenMRS RefApp SDK server.

Summary

This PR hides the “Admit to Inpatient” button on the clinician-facing patient dashboard.

Removing the privilege referenceapplication.simpleAdmission does not prevent the UI from rendering the action.
As recommended in the Jira discussion, a small CSS override is applied to hide the button at the UI level. This
ensures that users who should not see the admission option do not have access to it visually, while other visit
actions (Transfer, Discharge, Visit Note, Capture Vitals, etc.) remain fully accessible.

Related Issue

Fixes RA-1747

Changes

  • Added a CSS rule to referenceapplication.scss targeting the extension with ID
    referenceapplication.realTime.simpleAdmission.
  • This hides only the “Admit to Inpatient” button without affecting any other UI elements or backend workflows.

CSS Applied

#referenceapplication\.realTime\.simpleAdmission {
    display: none !important;
}

Testing

Before the change

  • Logged in as clinician.
  • Navigated to Inpatient Ward → Select patient → Visits → Visit Actions.
  • Observed the “Admit to Inpatient” button still visible even without the privilege.

After the change

  • Rebuilt and redeployed the module using OpenMRS SDK.
  • Verified that the “Admit to Inpatient” action no longer appears.
  • All other visit actions remain functional.

Screenshots

Before:
before

After:
after

Checklist

  • Manually tested on OpenMRS RefApp SDK
  • No regressions in visit action functionality
  • Matches OpenMRS coding and UI guidelines
  • The change is minimal, clean, and reversible

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant