Uploaded image for project: 'VPMS Web Application'
  1. OVPMS-2015

Enable DataSource.getExpressionDataSource() to access report parameters

    Details

    • Type: Task
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.0
    • Component/s: None
    • Labels:
      None
    • Sprint:

      Description

      The JXPath expression passed to method

      JRRewindableDataSource getExpressionDataSource(String expression)

      of org.openvpms.report.jasper.DataSource cannot access report parameters.
      This prevents passing parameters to subreports. e.g.

      $P{dataSource}.getExpressionDataSource("$OpenVPMS.patient")
      

      This type is of expression is required to replace:

      $P{dataSource}.getDataSource("patient")
      

      which fail in custom Medical Records reports that change the record order. E.g if the record order puts an Investigation Version first in the patient history, the report fails, as the version record has no patient node.
      By using getExpressionDataSource("$OpenVPMS.patient"), the current patient is always available to the report.

        Attachments

          Activity

            People

            • Assignee:
              tanderson Tim Anderson
              Reporter:
              tanderson Tim Anderson
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 1h
                1h

                  Who's Looking?