Skip to content

Commit

Permalink
TRUNK-4109: Get observations by accession number
Browse files Browse the repository at this point in the history
org.openmrs.api.ObsService#getObservations and
org.openmrs.api.ObsService#getObservationCount are now overloaded to support
specification of accession number.
If specified, only observations (or their count) with matching accession
number are returned.

See https://issues.openmrs.org/browse/TRUNK-4109

Unit tests for org.openmrs.api.ObsService#getObservations and
org.openmrs.api.ObsService#getObservationCount now use the new
(and most general) methods.
  • Loading branch information
vencik committed Jun 25, 2014
1 parent 2a25bd8 commit 2859347
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions api/src/main/java/org/openmrs/api/ObsService.java
Original file line number Diff line number Diff line change
Expand Up @@ -409,6 +409,7 @@ public List<Obs> getObservations(List<Person> whom, List<Encounter> encounters,
* @param includeVoidedObs true/false whether to also include the voided obs (required)
* @param accessionNumber accession number (optional)
* @return list of Observations that match all of the criteria given in the arguments
* @since 1.12
* @throws APIException
* @should compare dates using lte and gte
* @should get all obs assigned to given encounters
Expand Down Expand Up @@ -489,6 +490,7 @@ public Integer getObservationCount(List<Person> whom, List<Encounter> encounters
* @param includeVoidedObs true/false whether to also include the voided obs (required)
* @param accessionNumber accession number (optional)
* @return list of Observations that match all of the criteria given in the arguments
* @since 1.12
* @throws APIException
* @should compare dates using lte and gte
* @should get the count of all obs assigned to given encounters
Expand Down

0 comments on commit 2859347

Please sign in to comment.