use of org.olat.course.nodes.gta.ui.events.SelectIdentityEvent in project openolat by klemens.
the class GTACoachedParticipantListController method formInnerEvent.
@Override
protected void formInnerEvent(UserRequest ureq, FormItem source, FormEvent event) {
if (tableEl == source) {
if (event instanceof SelectionEvent) {
SelectionEvent se = (SelectionEvent) event;
String cmd = se.getCommand();
CoachedIdentityRow row = tableModel.getObject(se.getIndex());
if ("duedates".equals(cmd)) {
doEditDueDate(ureq, row);
} else if (StringHelper.containsNonWhitespace(cmd)) {
fireEvent(ureq, new SelectIdentityEvent(row.getIdentity().getIdentityKey()));
}
}
} else if (extendButton == source) {
List<CoachedIdentityRow> rows = getSelectedRows();
doEditMultipleDueDates(ureq, rows);
} else if (source instanceof FormLink) {
FormLink link = (FormLink) source;
String cmd = link.getCmd();
if ("mark".equals(cmd)) {
Long assessableIdentityKey = (Long) link.getUserObject();
boolean marked = doToogleMark(ureq, assessableIdentityKey);
link.setIconLeftCSS(marked ? Mark.MARK_CSS_LARGE : Mark.MARK_ADD_CSS_LARGE);
link.getComponent().setDirty(true);
}
}
super.formInnerEvent(ureq, source, event);
}
use of org.olat.course.nodes.gta.ui.events.SelectIdentityEvent in project OpenOLAT by OpenOLAT.
the class GTACoachedParticipantListController method formInnerEvent.
@Override
protected void formInnerEvent(UserRequest ureq, FormItem source, FormEvent event) {
if (tableEl == source) {
if (event instanceof SelectionEvent) {
SelectionEvent se = (SelectionEvent) event;
String cmd = se.getCommand();
CoachedIdentityRow row = tableModel.getObject(se.getIndex());
if ("duedates".equals(cmd)) {
doEditDueDate(ureq, row);
} else if (StringHelper.containsNonWhitespace(cmd)) {
fireEvent(ureq, new SelectIdentityEvent(row.getIdentity().getIdentityKey()));
}
}
} else if (extendButton == source) {
List<CoachedIdentityRow> rows = getSelectedRows();
doEditMultipleDueDates(ureq, rows);
} else if (source instanceof FormLink) {
FormLink link = (FormLink) source;
String cmd = link.getCmd();
if ("mark".equals(cmd)) {
Long assessableIdentityKey = (Long) link.getUserObject();
boolean marked = doToogleMark(ureq, assessableIdentityKey);
link.setIconLeftCSS(marked ? Mark.MARK_CSS_LARGE : Mark.MARK_ADD_CSS_LARGE);
link.getComponent().setDirty(true);
}
}
super.formInnerEvent(ureq, source, event);
}
use of org.olat.course.nodes.gta.ui.events.SelectIdentityEvent in project OpenOLAT by OpenOLAT.
the class GTACoachSelectionController method event.
@Override
protected void event(UserRequest ureq, Controller source, Event event) {
if (groupListCtrl == source) {
if (event instanceof SelectBusinessGroupEvent) {
SelectBusinessGroupEvent selectEvent = (SelectBusinessGroupEvent) event;
doSelectBusinessGroup(ureq, selectEvent.getBusinessGroup());
backLink.setVisible(true);
}
} else if (participantListCtrl == source) {
if (event instanceof SelectIdentityEvent) {
SelectIdentityEvent selectEvent = (SelectIdentityEvent) event;
Identity selectedIdentity = securityManager.loadIdentityByKey(selectEvent.getIdentityKey());
doSelectParticipant(ureq, selectedIdentity);
backLink.setVisible(true);
}
}
super.event(ureq, source, event);
}
use of org.olat.course.nodes.gta.ui.events.SelectIdentityEvent in project openolat by klemens.
the class GTACoachSelectionController method event.
@Override
protected void event(UserRequest ureq, Controller source, Event event) {
if (groupListCtrl == source) {
if (event instanceof SelectBusinessGroupEvent) {
SelectBusinessGroupEvent selectEvent = (SelectBusinessGroupEvent) event;
doSelectBusinessGroup(ureq, selectEvent.getBusinessGroup());
backLink.setVisible(true);
}
} else if (participantListCtrl == source) {
if (event instanceof SelectIdentityEvent) {
SelectIdentityEvent selectEvent = (SelectIdentityEvent) event;
Identity selectedIdentity = securityManager.loadIdentityByKey(selectEvent.getIdentityKey());
doSelectParticipant(ureq, selectedIdentity);
backLink.setVisible(true);
}
}
super.event(ureq, source, event);
}
Aggregations