Search in sources :

Example 11 with AssessmentFormEvent

use of org.olat.modules.assessment.ui.event.AssessmentFormEvent in project openolat by klemens.

the class GTACoachedParticipantGradingController method event.

@Override
protected void event(UserRequest ureq, Controller source, Event event) {
    if (assessmentForm == source) {
        if (event instanceof AssessmentFormEvent) {
            UserCourseEnvironment assessedUserCourseEnv = assessmentForm.getAssessedUserCourseEnvironment();
            doGraded(ureq, assessedUserCourseEnv);
        }
        cmc.deactivate();
        cleanUp();
    } else if (cmc == source) {
        cleanUp();
    }
    super.event(ureq, source, event);
}
Also used : AssessmentFormEvent(org.olat.modules.assessment.ui.event.AssessmentFormEvent) UserCourseEnvironment(org.olat.course.run.userview.UserCourseEnvironment)

Example 12 with AssessmentFormEvent

use of org.olat.modules.assessment.ui.event.AssessmentFormEvent in project openolat by klemens.

the class AssessedIdentityRepositoryEntryController method event.

@Override
protected void event(UserRequest ureq, Controller source, Event event) {
    if (assessmentForm == source) {
        if (event instanceof AssessmentFormEvent) {
            AssessmentFormEvent afe = (AssessmentFormEvent) event;
            if (afe.isClose()) {
                stackPanel.popController(assessmentForm);
                fireEvent(ureq, Event.DONE_EVENT);
            } else {
                fireEvent(ureq, Event.CHANGED_EVENT);
            }
        } else if (event == Event.CANCELLED_EVENT) {
            stackPanel.popController(assessmentForm);
        }
    } else if (detailsCtrl == source) {
        if (event == Event.CHANGED_EVENT || event == Event.DONE_EVENT) {
            assessmentForm.reloadData();
            fireEvent(ureq, Event.CHANGED_EVENT);
        }
    }
    super.event(ureq, source, event);
}
Also used : AssessmentFormEvent(org.olat.modules.assessment.ui.event.AssessmentFormEvent)

Example 13 with AssessmentFormEvent

use of org.olat.modules.assessment.ui.event.AssessmentFormEvent in project openolat by klemens.

the class AssessmentForm method formOK.

@Override
protected void formOK(UserRequest ureq) {
    doUpdateAssessmentData(false);
    fireEvent(ureq, new AssessmentFormEvent(AssessmentFormEvent.ASSESSMENT_CHANGED, true));
}
Also used : AssessmentFormEvent(org.olat.modules.assessment.ui.event.AssessmentFormEvent)

Example 14 with AssessmentFormEvent

use of org.olat.modules.assessment.ui.event.AssessmentFormEvent in project openolat by klemens.

the class AssessmentForm method formInnerEvent.

@Override
protected void formInnerEvent(UserRequest ureq, FormItem source, FormEvent event) {
    if (saveAndDoneLink == source) {
        if (validateFormLogic(ureq)) {
            doUpdateAssessmentData(true);
            fireEvent(ureq, new AssessmentFormEvent(AssessmentFormEvent.ASSESSMENT_DONE, true));
        }
    } else if (reopenLink == source) {
        doReopen();
        fireEvent(ureq, new AssessmentFormEvent(AssessmentFormEvent.ASSESSMENT_CHANGED, false));
    }
    super.formInnerEvent(ureq, source, event);
}
Also used : AssessmentFormEvent(org.olat.modules.assessment.ui.event.AssessmentFormEvent)

Aggregations

AssessmentFormEvent (org.olat.modules.assessment.ui.event.AssessmentFormEvent)14 FormLink (org.olat.core.gui.components.form.flexible.elements.FormLink)2 ShowDetailsEvent (org.olat.course.assessment.ui.tool.event.ShowDetailsEvent)2 UserCourseEnvironment (org.olat.course.run.userview.UserCourseEnvironment)2