Wiki Spaces


Get Help from Others

Q&A: Ask OpenMRS
Discussion: OpenMRS Talk
Real-Time: IRC Chat | Slack


Page tree
Skip to end of metadata
Go to start of metadata


  1. All the information in the table can be retrieved from the Order, I believe, with the exception of Last Dispensed.  Assuming we add the MedicationDispense object, to determine the provider we can fetch all MedicationDispesned objects associated with an order, sorted by dateHandedOver, take the most recent and then take the provider from it.  (Tech question: is this the preferred method, to get MedicationDispense via a separate request, or should we provide some composite object?)
  2. Still need to figure out the "orderless" use case.


  1. What is the query logic for the table?  All non-voided orders with date_activated before or equal to current date, ordered by date activated descending?  (In this case would obviously needed to be paginated)
  2. What are all the possible statuses and what do they mean? I could see the following:
    1. See O3-1214 - Getting issue details... STATUS for current thoughts
    2. Active prescription: order is active (current date is after or equal dateActivated, and current date before dateExpired or dateStopped, and type not DISCONTINUED... see complete logic here:
    3. Completed: Curious what the business logic would be here.  Does this mean that a single, complete dispensing event has occurred? Or that all the refills have been satisfied?  Does this take precedence over all other status (ie, if an order is both "expired" and "completed" we display "completed") (We do have a field on Order, fulfiller_status, with values: RECEIVED, IN_PROGRESS, EXCEPTION and COMPLETED, so we could use "completed" for this)
    4. Returned:  I assume this means that it is being returned to the prescriber? We do have a fulfiller_status of "EXCEPTION" (see above), which we can use to reflected
    5. Expired: Not pictured in the above, but I think needed, and  would be any order that fulfills the isExpired logic:
    6. Discontinued: Not pictured in the above, but I think needed, and would be any order the fulfills the isDiscontinued logic: 
    7. Any other states I missed?
  3. Will need to define how to display the Drug column based on name of underling drug and/or name of underlying concept, and/or drugNonCoded field.
  4. Do we need to support "Change Date View" in phase 1, or just stick to the current date.  In general, seems like setting a historical date would likely just be confusing for the user?  Is this actually meant to limit to certain date?


  • This is actually a row-per-encounter table, with potentially multiple orders per row.
  • Relevant active tickets here:
    • O3-1214 - Getting issue details... STATUS
    • FM2-480 - Getting issue details... STATUS
  • No labels