Uploaded image for project: 'OpenMRS Core'
  1. OpenMRS Core
  2. TRUNK-1647

Recent encounters on patientHeader.jsp should use model object provided

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: TBD
    • Resolution: Fixed
    • Affects Version/s: OpenMRS 1.6.1
    • Fix Version/s: OpenMRS 1.7.0
    • Component/s: None
    • Labels:
      None
    • Complexity:
      Low

      Description

      In the patient header jsp page, the code that displays the "No previous encounters" doesn't test against the right model object. The line should read:

      <c:if test="${fn:length(model.patientEncounters) == 0}">
      <spring:message code="Encounter.no.previous"/>
      </c:if>

      but right now it reads:

      <c:if test="${fn:length(encounters) == 0}">
      <spring:message code="Encounter.no.previous"/>
      </c:if>

      The "model" object is the object populated by the portlet controller. This code "works" right now because the the "encounters" object is populated by the main patient dashboard controller... but if you try to include the header elsewhere (like in a module UI) it always displays "No previous encounters" since the "encounters" object isn't populated in this case.

      A patch is attached.

        Gliffy Diagrams

          Attachments

            Activity

              People

              Assignee:
              mogoodrich Mark Goodrich
              Reporter:
              mogoodrich Mark Goodrich
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: