diff --git a/navalplanner-business/src/main/java/org/navalplanner/business/planner/entities/AggregateOfResourceAllocations.java b/navalplanner-business/src/main/java/org/navalplanner/business/planner/entities/AggregateOfResourceAllocations.java index 991a8ed08..20686fd66 100644 --- a/navalplanner-business/src/main/java/org/navalplanner/business/planner/entities/AggregateOfResourceAllocations.java +++ b/navalplanner-business/src/main/java/org/navalplanner/business/planner/entities/AggregateOfResourceAllocations.java @@ -65,7 +65,16 @@ public class AggregateOfResourceAllocations { } public boolean isEmpty() { - return resourceAllocations.isEmpty(); + return resourceAllocations.isEmpty() || allEmpty(); + } + + private boolean allEmpty() { + for (ResourceAllocation each : resourceAllocations) { + if (each.hasAssignments()) { + return false; + } + } + return true; } public List> getAllocationsSortedByStartDate() {