diff --git a/api/src/main/java/org/openmrs/api/ObsService.java b/api/src/main/java/org/openmrs/api/ObsService.java index 6675515e4177..dc2970ae53a2 100644 --- a/api/src/main/java/org/openmrs/api/ObsService.java +++ b/api/src/main/java/org/openmrs/api/ObsService.java @@ -501,11 +501,18 @@ public Integer getObservationCount(List whom, List encounters /** * @see org.openmrs.api.ObsService#getObservations(java.util.List, java.util.List, - * java.util.List, java.util.List, List, List, java.util.List, java.util.List, java.lang.Integer, + * java.util.List, java.util.List, List, List, java.util.List, java.lang.Integer, * java.lang.Integer, java.util.Date, java.util.Date, boolean, java.lang.String) * + * This method works exactly the same; it only adds visits to the search criteria. + * It effectively surpasses the above method; the old one is however kept for backward + * compatibility reasons. + * + * @param visits List<Visit> to restrict obs to (optional) + * * @since 2.7.0 */ + @Authorized(PrivilegeConstants.GET_OBS) public List getObservations(List whom, List encounters, List questions, List answers, List personTypes, List locations, List sort, List visits, Integer mostRecentN, Integer obsGroupId, Date fromDate, Date toDate, @@ -513,11 +520,18 @@ public List getObservations(List whom, List encounters, /** * @see org.openmrs.api.ObsService#getObservationCount(java.util.List, java.util.List, - * java.util.List, java.util.List, java.util.List, java.util.List, java.util.List, java.lang.Integer, + * java.util.List, java.util.List, java.util.List, java.util.List, java.lang.Integer, * java.util.Date, java.util.Date, boolean, java.lang.String) * + * This method works exactly the same; it only adds visits to the search criteria. + * It effectively surpasses the above method; the old one is however kept for backward + * compatibility reasons. + * + * @param visits List<Visit> to restrict obs to (optional) + * * @since 2.7.0 */ + @Authorized(PrivilegeConstants.GET_OBS) public Integer getObservationCount(List whom, List encounters, List questions, List answers, List personTypes, List locations, List visits, Integer obsGroupId, Date fromDate, Date toDate, boolean includeVoidedObs, String accessionNumber)