ItEr19S11CUAsignacionRecursosEspecificosAPlanificacionItEr18S14: Showing a message when the criterions list is empty during the resource allocation.
This commit is contained in:
parent
9909aef738
commit
72aa2b07d0
2 changed files with 11 additions and 1 deletions
|
|
@ -46,7 +46,16 @@ public class ResourceAllocationController extends GenericForwardComposer {
|
|||
private Window window;
|
||||
|
||||
public Set<Criterion> getCriterions() {
|
||||
return resourceAllocationModel.getCriterions();
|
||||
Set<Criterion> criterions = resourceAllocationModel.getCriterions();
|
||||
if (criterions.isEmpty()) {
|
||||
window.getFellow("requiredCriterions").setVisible(false);
|
||||
window.getFellow("requiredCriterionsEmpty").setVisible(true);
|
||||
} else {
|
||||
window.getFellow("requiredCriterionsEmpty").setVisible(false);
|
||||
window.getFellow("requiredCriterions").setVisible(true);
|
||||
}
|
||||
|
||||
return criterions;
|
||||
}
|
||||
|
||||
public Set<ResourceAllocation> getResourceAllocations() {
|
||||
|
|
|
|||
|
|
@ -51,6 +51,7 @@
|
|||
<listcell label="@{criterion.name}"></listcell>
|
||||
</listitem>
|
||||
</listbox>
|
||||
<label id="requiredCriterionsEmpty" value="None" visible="false" />
|
||||
<hbox>
|
||||
<button id="addResourceAllocation" label="Add"
|
||||
onClick="allocationController.addResourceAllocation();" />
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue