return;
}else if(Event.CHANGED_EVENT == event){
//a group was created in group chooser
if(!hasGroups)
//fires an Multiuser designed bgcontext event NOT on the systembus if business group were created
fireEvent(ureq, new BGContextEvent(BGContextEvent.RESOURCE_ADDED,getDefaultBGContext()));
}
} else if (source == areaChooseC) {
if (org.olat.core.gui.control.Event.DONE_EVENT == event) {
//TODO:pb find better solution
this.flc.getRootForm().setDirtyMarking(true);
this.flc.setDirty(true);
cmc.deactivate();
String selection = "";
selection = StringHelper.formatAsCSVString(areaChooseC.getSelectedEntries());
// apply selection to textelement
easyAreaTE.setValue(selection);
validateGroupFields();
}else if (org.olat.core.gui.control.Event.CANCELLED_EVENT == event){
closeCMCandSetWholeFormDirty(source);
return;
}else if(Event.CHANGED_EVENT == event){
if(!hasAreas){
//an area was created in area chooser
//fires an Multiuser designed bgcontext event NOT on the systembus if area were created
fireEvent(ureq, new BGContextEvent(BGContextEvent.RESOURCE_ADDED,getDefaultBGContext()));
}
}
} else if (source == groupCreateCntrllr) {
if (org.olat.core.gui.control.Event.DONE_EVENT == event) {
// validate element -> e.g. remove error
if (easyGroupTE.isEmpty()) {
// was empty before -> set the created groups
easyGroupTE.setValue(StringHelper.formatAsCSVString(groupCreateCntrllr.getCreatedGroupNames()));
}
validateGroupFields();
// toggle prepared links (create -> choose)
flc.remove(createGroupsLink);
flc.add(chooseGroupsLink);
groupCreateCntrllr.dispose();
//TODO:pb find better solution
this.flc.getRootForm().setDirtyMarking(true);
this.flc.setDirty(true);
cmc.deactivate();
if(!hasGroups){
//fires an Multiuser designed bgcontext event NOT on the systembus if business group were created
fireEvent(ureq, new BGContextEvent(BGContextEvent.RESOURCE_ADDED,getDefaultBGContext()));
}
hasGroups = true;// at least one group created
}else if (org.olat.core.gui.control.Event.CANCELLED_EVENT == event){
closeCMCandSetWholeFormDirty(source);
return;
}
} else if (source == areaCreateCntrllr) {
if (org.olat.core.gui.control.Event.DONE_EVENT == event) {
// validate element -> e.g. remove error
if (easyAreaTE.isEmpty()) {
// was empty before -> set the created groups
easyAreaTE.setValue(StringHelper.formatAsCSVString(areaCreateCntrllr.getCreatedAreaNames()));
}
validateGroupFields();
// toggle prepared links (create -> choose)
flc.remove(createAreasLink);
flc.add(chooseAreasLink);
areaCreateCntrllr.dispose();
//TODO:pb find better solution
this.flc.getRootForm().setDirtyMarking(true);
this.flc.setDirty(true);
cmc.deactivate();
if (!hasAreas) {
// fires an Multiuser designed bgcontext event NOT on the systembus if
// area were created
fireEvent(ureq, new BGContextEvent(BGContextEvent.RESOURCE_ADDED,getDefaultBGContext()));
}
hasAreas = true;// at least one group created
}else if (org.olat.core.gui.control.Event.CANCELLED_EVENT == event){
closeCMCandSetWholeFormDirty(source);
return;