diff --git a/api/src/main/java/org/openmrs/module/ipd/api/events/handler/impl/RolloverTaskEventHandler.java b/api/src/main/java/org/openmrs/module/ipd/api/events/handler/impl/RolloverTaskEventHandler.java index 59e59e3..9dc34a3 100644 --- a/api/src/main/java/org/openmrs/module/ipd/api/events/handler/impl/RolloverTaskEventHandler.java +++ b/api/src/main/java/org/openmrs/module/ipd/api/events/handler/impl/RolloverTaskEventHandler.java @@ -40,7 +40,7 @@ public void handleEvent(IPDEvent event) { List taskNames = eventConfig.getTasks().stream() .map(TaskDetail::getName) .collect(Collectors.toList()); - List rolloverTasks = taskService.getTasksByNameAndStatus(taskNames, FhirTask.TaskStatus.REQUESTED); + List rolloverTasks = taskService.searchTasks(taskNames, FhirTask.TaskStatus.REQUESTED); List fhirTaskRequestedPeriods = new ArrayList(); for (Task task : rolloverTasks) { if (task.getFhirTaskRequestedPeriod() != null) { @@ -49,6 +49,6 @@ public void handleEvent(IPDEvent event) { fhirTaskRequestedPeriods.add(fhirTaskRequestedPeriod); } } - taskRequestedPeriodDao.bulkUpdate(fhirTaskRequestedPeriods); + taskRequestedPeriodDao.update(fhirTaskRequestedPeriods); } } \ No newline at end of file diff --git a/api/src/main/java/org/openmrs/module/ipd/api/events/handler/impl/ShiftStartTaskEventHandler.java b/api/src/main/java/org/openmrs/module/ipd/api/events/handler/impl/ShiftStartTaskEventHandler.java index 12d1960..e97d620 100644 --- a/api/src/main/java/org/openmrs/module/ipd/api/events/handler/impl/ShiftStartTaskEventHandler.java +++ b/api/src/main/java/org/openmrs/module/ipd/api/events/handler/impl/ShiftStartTaskEventHandler.java @@ -45,7 +45,7 @@ public void handleEvent(IPDEvent event) { } } if(tasks.size() > 0){ - taskService.bulkSaveTasks(tasks); + taskService.saveTask(tasks); } }