diff --git a/web/src/main/java/org/phoenixctms/ctsms/web/jersey/resource/trial/VisitScheduleItemResource.java b/web/src/main/java/org/phoenixctms/ctsms/web/jersey/resource/trial/VisitScheduleItemResource.java index 5fe9bd937eb6..ebb29b0a7c20 100644 --- a/web/src/main/java/org/phoenixctms/ctsms/web/jersey/resource/trial/VisitScheduleItemResource.java +++ b/web/src/main/java/org/phoenixctms/ctsms/web/jersey/resource/trial/VisitScheduleItemResource.java @@ -59,9 +59,10 @@ public VisitScheduleItemOutVO getVisitScheduleItem(@PathParam("id") Long id) thr @GET @Produces({ MediaType.APPLICATION_JSON }) @Path("interval") - public Collection getVisitScheduleItemInterval(@QueryParam("trial_id") Long trialId, @QueryParam("from") String from, + public Collection getVisitScheduleItemInterval(@QueryParam("trial_id") Long trialId, @QueryParam("proband_id") Long probandId, + @QueryParam("from") String from, @QueryParam("to") String to, @QueryParam("sort") Boolean sort) throws Exception { - return WebUtil.getServiceLocator().getTrialService().getVisitScheduleItemInterval(auth, trialId, null, null, null, + return WebUtil.getServiceLocator().getTrialService().getVisitScheduleItemInterval(auth, trialId, null, probandId, null, null, (Date) (CommonUtil.isEmptyString(from) ? null : StringConverter.getConverter(Date.class).convert(from)), (Date) (CommonUtil.isEmptyString(to) ? null : StringConverter.getConverter(Date.class).convert(to)), sort); } diff --git a/web/src/main/java/org/phoenixctms/ctsms/web/model/inventory/InventoryBookingLazyScheduleModel.java b/web/src/main/java/org/phoenixctms/ctsms/web/model/inventory/InventoryBookingLazyScheduleModel.java index c3d626a357b0..50dd0b603a22 100644 --- a/web/src/main/java/org/phoenixctms/ctsms/web/model/inventory/InventoryBookingLazyScheduleModel.java +++ b/web/src/main/java/org/phoenixctms/ctsms/web/model/inventory/InventoryBookingLazyScheduleModel.java @@ -283,7 +283,7 @@ protected void getLazyResult(Date start, Date stop) { Collection visitScheduleAppointments = null; try { visitScheduleAppointments = WebUtil.getServiceLocator().getTrialService() - .getVisitScheduleItemInterval(auth, trialId, departmentId, null, visitTypeId, from, to, false); + .getVisitScheduleItemInterval(auth, trialId, departmentId, probandId, null, visitTypeId, from, to, false); } catch (ServiceException | AuthorisationException | IllegalArgumentException e) { } catch (AuthenticationException e) { WebUtil.publishException(e); diff --git a/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/DutyRosterLazyScheduleModel.java b/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/DutyRosterLazyScheduleModel.java index 2a14d6a28122..500f0ec669c2 100644 --- a/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/DutyRosterLazyScheduleModel.java +++ b/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/DutyRosterLazyScheduleModel.java @@ -61,7 +61,7 @@ public class DutyRosterLazyScheduleModel extends LazyScheduleModelBase { private boolean showProbandStatus; private Long showCollisionsThresholdDays; private Long staffNaCountLimit; - private boolean showStaffNaCount; + //private boolean showStaffNaCount; private Long departmentId; private Long staffCategoryId; private Long trialId; @@ -291,7 +291,7 @@ protected void getLazyResult(Date start, Date end) { Collection visitScheduleAppointments = null; try { visitScheduleAppointments = WebUtil.getServiceLocator().getTrialService() - .getVisitScheduleItemInterval(auth, trialId, departmentId, statusId, visitTypeId, from, to, false); + .getVisitScheduleItemInterval(auth, trialId, departmentId, null, statusId, visitTypeId, from, to, false); } catch (ServiceException | AuthorisationException | IllegalArgumentException e) { } catch (AuthenticationException e) { WebUtil.publishException(e); diff --git a/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/TimelineTrialTimelineEventBean.java b/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/TimelineTrialTimelineEventBean.java index 30fbfae8e30b..dbf3b5c104ed 100644 --- a/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/TimelineTrialTimelineEventBean.java +++ b/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/TimelineTrialTimelineEventBean.java @@ -370,7 +370,7 @@ public void updateTimelineModel() { visitScheduleAppointments = WebUtil .getServiceLocator() .getTrialService() - .getVisitScheduleItemInterval(WebUtil.getAuthentication(), filterTrialId, filterDepartmentId, filterStatusId, filterVisitTypeId, rangeStart, rangeEnd, + .getVisitScheduleItemInterval(WebUtil.getAuthentication(), filterTrialId, filterDepartmentId, null, filterStatusId, filterVisitTypeId, rangeStart, rangeEnd, false); } catch (ServiceException | AuthorisationException | IllegalArgumentException e) { } catch (AuthenticationException e) { diff --git a/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/VisitScheduleAppointmentEvent.java b/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/VisitScheduleAppointmentEvent.java index a1b19fe3de5e..542e95f15e14 100644 --- a/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/VisitScheduleAppointmentEvent.java +++ b/web/src/main/java/org/phoenixctms/ctsms/web/model/trial/VisitScheduleAppointmentEvent.java @@ -144,6 +144,7 @@ public String getTitle() { sb.append(in.getToken()); appended = true; } + appended = sb.length() > 0; ProbandOutVO proband = null; proband = (out != null ? out.getProband() : null); if (proband != null) {