diff --git a/src/main/java/org/olat/course/nodes/SurveyCourseNode.java b/src/main/java/org/olat/course/nodes/SurveyCourseNode.java index 7c4831555f2765992ad3d6b86534d2215603f3e7..2a0135e47dc1497fa70b71a339261243bfcba8c1 100644 --- a/src/main/java/org/olat/course/nodes/SurveyCourseNode.java +++ b/src/main/java/org/olat/course/nodes/SurveyCourseNode.java @@ -177,7 +177,7 @@ public class SurveyCourseNode extends AbstractAccessableCourseNode { RepositoryEntry ores = userCourseEnv.getCourseEnvironment().getCourseGroupManager().getCourseEntry(); SurveyRunSecurityCallback secCallback = new SurveyRunSecurityCallback(getModuleConfiguration(), userCourseEnv); Identity identity = userCourseEnv.getIdentityEnvironment().getIdentity(); - return new SurveyStatisticResourceResult(of(ores, getIdent()), identity, secCallback); + return new SurveyStatisticResourceResult(ores, this, identity, secCallback); } return null; } diff --git a/src/main/java/org/olat/course/nodes/gta/ui/DirectoryController.java b/src/main/java/org/olat/course/nodes/gta/ui/DirectoryController.java index 26ed8046db4d5f8a7505cdcc58a9bf20db965efc..efc975c9874b30c6885d5c3668d628768cbfece7 100644 --- a/src/main/java/org/olat/course/nodes/gta/ui/DirectoryController.java +++ b/src/main/java/org/olat/course/nodes/gta/ui/DirectoryController.java @@ -140,7 +140,9 @@ public class DirectoryController extends BasicController implements Activateable linkNames.add(new DocumentInfos(link.getComponentName(), uploadedBy, lastModified)); } mainVC.contextPut("linkNames", linkNames); - bulkReviewLink.setVisible(!linkNames.isEmpty()); + if(bulkReviewLink != null) { + bulkReviewLink.setVisible(!linkNames.isEmpty()); + } putInitialPanel(mainVC); } diff --git a/src/main/java/org/olat/course/nodes/st/STCourseNodeDisplayConfigFormController.java b/src/main/java/org/olat/course/nodes/st/STCourseNodeDisplayConfigFormController.java index 16502c0c6a99a3db6baf869ed774a02c9474d015..02acbb248ffea768281aed941c298809c59859f8 100644 --- a/src/main/java/org/olat/course/nodes/st/STCourseNodeDisplayConfigFormController.java +++ b/src/main/java/org/olat/course/nodes/st/STCourseNodeDisplayConfigFormController.java @@ -19,6 +19,8 @@ */ package org.olat.course.nodes.st; +import java.util.stream.Collectors; + import org.olat.core.gui.UserRequest; import org.olat.core.gui.components.form.flexible.FormItem; import org.olat.core.gui.components.form.flexible.FormItemContainer; @@ -269,12 +271,7 @@ public class STCourseNodeDisplayConfigFormController extends FormBasicController if (selectedPeekviewChildren == null || selectedPeekviewChildren.getSelectedKeys().isEmpty()) { moduleConfig.remove(STCourseNodeEditController.CONFIG_KEY_PEEKVIEW_CHILD_NODES); } else { - StringBuilder config = new StringBuilder(); - for (String childKey : selectedPeekviewChildren.getSelectedKeys()) { - if (selectedPeekviewChildNodesConfig.length() > 0) config.append(","); - config.append(childKey); - } - selectedPeekviewChildNodesConfig = config.toString(); + selectedPeekviewChildNodesConfig = selectedPeekviewChildren.getSelectedKeys().stream().collect(Collectors.joining(",")); moduleConfig.set(STCourseNodeEditController.CONFIG_KEY_PEEKVIEW_CHILD_NODES, selectedPeekviewChildNodesConfig); } } else if (STCourseNodeEditController.CONFIG_VALUE_DISPLAY_DELEGATE.equals(displayType)) { diff --git a/src/main/java/org/olat/course/nodes/survey/SurveyRunController.java b/src/main/java/org/olat/course/nodes/survey/SurveyRunController.java deleted file mode 100644 index f696ec369a88e86693c97ea428ffb7f60e05be04..0000000000000000000000000000000000000000 --- a/src/main/java/org/olat/course/nodes/survey/SurveyRunController.java +++ /dev/null @@ -1,291 +0,0 @@ -/** - * <a href="http://www.openolat.org"> - * OpenOLAT - Online Learning and Training</a><br> - * <p> - * Licensed under the Apache License, Version 2.0 (the "License"); <br> - * you may not use this file except in compliance with the License.<br> - * You may obtain a copy of the License at the - * <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache homepage</a> - * <p> - * Unless required by applicable law or agreed to in writing,<br> - * software distributed under the License is distributed on an "AS IS" BASIS, <br> - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. <br> - * See the License for the specific language governing permissions and <br> - * limitations under the License. - * <p> - * Initial code contributed and copyrighted by<br> - * frentix GmbH, http://www.frentix.com - * <p> - */ -package org.olat.course.nodes.survey; - -import static org.olat.modules.forms.EvaluationFormSurveyIdentifier.of; - -import java.util.UUID; - -import org.apache.logging.log4j.Logger; -import org.olat.core.gui.UserRequest; -import org.olat.core.gui.components.Component; -import org.olat.core.gui.components.link.Link; -import org.olat.core.gui.components.link.LinkFactory; -import org.olat.core.gui.components.velocity.VelocityContainer; -import org.olat.core.gui.control.Controller; -import org.olat.core.gui.control.Event; -import org.olat.core.gui.control.WindowControl; -import org.olat.core.gui.control.controller.BasicController; -import org.olat.core.gui.control.generic.closablewrapper.CloseableModalController; -import org.olat.core.gui.control.generic.messages.MessageUIFactory; -import org.olat.core.gui.translator.Translator; -import org.olat.core.id.Identity; -import org.olat.core.id.OLATResourceable; -import org.olat.core.logging.Tracing; -import org.olat.core.util.UserSession; -import org.olat.core.util.Util; -import org.olat.course.assessment.AssessmentManager; -import org.olat.course.nodes.SurveyCourseNode; -import org.olat.course.nodes.survey.ui.SurveyDeleteDataConfirmationController; -import org.olat.course.nodes.survey.ui.SurveyReportingController; -import org.olat.course.run.userview.UserCourseEnvironment; -import org.olat.modules.assessment.Role; -import org.olat.modules.forms.EvaluationFormManager; -import org.olat.modules.forms.EvaluationFormParticipation; -import org.olat.modules.forms.EvaluationFormParticipationIdentifier; -import org.olat.modules.forms.EvaluationFormSession; -import org.olat.modules.forms.EvaluationFormSurvey; -import org.olat.modules.forms.ui.EvaluationFormExecutionController; -import org.springframework.beans.factory.annotation.Autowired; - -/** - * - * Initial date: 24.04.2018<br> - * @author uhensler, urs.hensler@frentix.com, http://www.frentix.com - * - */ -public class SurveyRunController extends BasicController { - - private static final Logger log = Tracing.createLoggerFor(SurveyRunController.class); - - private VelocityContainer mainVC; - private Link resetLink; - - private CloseableModalController cmc; - private SurveyDeleteDataConfirmationController deleteDataConfirmationCtrl; - private EvaluationFormExecutionController executionCtrl; - - private final UserCourseEnvironment userCourseEnv; - private final SurveyCourseNode courseNode; - private final OLATResourceable ores; - private final String subIdent; - private final SurveyRunSecurityCallback secCallback; - private EvaluationFormSurvey survey; - private EvaluationFormParticipation participation; - - @Autowired - private EvaluationFormManager evaluationFormManager; - - public SurveyRunController(UserRequest ureq, WindowControl wControl, UserCourseEnvironment userCourseEnv, - SurveyCourseNode courseNode, SurveyRunSecurityCallback secCallback) { - super(ureq, wControl); - this.userCourseEnv = userCourseEnv; - this.courseNode = courseNode; - this.ores = userCourseEnv.getCourseEnvironment().getCourseGroupManager().getCourseEntry(); - this.subIdent = courseNode.getIdent(); - this.secCallback = secCallback; - - mainVC = createVelocityContainer("run"); - putInitialPanel(mainVC); - - initVelocityContainer(ureq); - } - - private void initVelocityContainer(UserRequest ureq) { - mainVC.clear(); - - if (secCallback.canRunCommands()) { - resetLink = LinkFactory.createButtonSmall("run.reset", mainVC, this); - resetLink.setIconLeftCSS("o_icon o_icon-fw o_icon_surv_reset"); - mainVC.contextPut("withCmds", Boolean.TRUE); - } - - survey = evaluationFormManager.loadSurvey(of(ores, subIdent)); - if (survey == null) { - String title = getTranslator().translate("run.no.survey.title"); - String message = getTranslator().translate("run.no.survey.message"); - doShowMessage(ureq, title, message); - log.warn("Published survey course node has no survey in the database!"); - return; - } - - doShowView(ureq); - } - - private void doShowView(UserRequest ureq) { - if (secCallback.canParticipate()) { - participation = loadOrCreateParticipation(ureq); - } - if (secCallback.canViewReporting(participation)) { - doShowReporting(ureq); - } else if (secCallback.hasParticipated(participation)) { - doShowParticipationDone(ureq); - } else if (secCallback.isReadOnly()) { - doShowReadOnly(ureq); - } else if (secCallback.canExecute(participation)) { - doShowExecution(ureq); - } else { - doShowNoAccess(ureq); - } - } - - private EvaluationFormParticipation loadOrCreateParticipation(UserRequest ureq) { - if (secCallback.isGuestOnly()) { - UserSession usess = ureq.getUserSession(); - String anonymousIdentifier = getAnonymousIdentifier(usess); - EvaluationFormParticipationIdentifier identifier = new EvaluationFormParticipationIdentifier("course-node", anonymousIdentifier); - return loadOrCreateParticipation(identifier); - } - return loadOrCreateParticipation(getIdentity()); - } - - private String getAnonymousIdentifier(UserSession usess) { - String sessionId = usess.getSessionInfo().getSession().getId(); - Object id = usess.getEntry(sessionId); - if (id instanceof String) { - return (String) id; - } - - String newId = UUID.randomUUID().toString(); - usess.putEntryInNonClearedStore(sessionId, newId); - return newId; - } - - private EvaluationFormParticipation loadOrCreateParticipation(EvaluationFormParticipationIdentifier identifier) { - EvaluationFormParticipation loadedParticipation = evaluationFormManager.loadParticipationByIdentifier(survey, identifier); - if (loadedParticipation == null) { - loadedParticipation = evaluationFormManager.createParticipation(survey, identifier); - loadedParticipation.setAnonymous(true); - loadedParticipation = evaluationFormManager.updateParticipation(loadedParticipation); - } - return loadedParticipation; - } - - private EvaluationFormParticipation loadOrCreateParticipation(Identity executor) { - EvaluationFormParticipation loadedParticipation = evaluationFormManager.loadParticipationByExecutor(survey, executor); - if (loadedParticipation == null) { - loadedParticipation = evaluationFormManager.createParticipation(survey, executor); - loadedParticipation.setAnonymous(true); - loadedParticipation = evaluationFormManager.updateParticipation(loadedParticipation); - } - return loadedParticipation; - } - - private EvaluationFormSession loadOrCreateSesssion(EvaluationFormParticipation participation) { - EvaluationFormSession session = evaluationFormManager.loadSessionByParticipation(participation); - if (session == null) { - session = evaluationFormManager.createSession(participation); - } - return session; - } - - @Override - protected void event(UserRequest ureq, Component source, Event event) { - if (source == resetLink) { - doConfirmDeleteAllData(ureq); - } - } - - @Override - protected void event(UserRequest ureq, Controller source, Event event) { - if (source == executionCtrl && event == Event.DONE_EVENT) { - doPostExecution(ureq); - } else if(source == deleteDataConfirmationCtrl) { - if (event == Event.DONE_EVENT) { - doDeleteAllData(ureq); - } - cmc.deactivate(); - cleanUp(); - } - super.event(ureq, source, event); - } - - private void cleanUp() { - removeAsListenerAndDispose(deleteDataConfirmationCtrl); - removeAsListenerAndDispose(cmc); - deleteDataConfirmationCtrl = null; - cmc = null; - } - - private void doPostExecution(UserRequest ureq) { - AssessmentManager am = userCourseEnv.getCourseEnvironment().getAssessmentManager(); - Identity mySelf = userCourseEnv.getIdentityEnvironment().getIdentity(); - am.incrementNodeAttempts(courseNode, mySelf, userCourseEnv, Role.auto); - doShowView(ureq); - } - - private void doConfirmDeleteAllData(UserRequest ureq) { - long countOfSessions = evaluationFormManager.getCountOfSessions(survey); - deleteDataConfirmationCtrl = new SurveyDeleteDataConfirmationController(ureq, getWindowControl(), countOfSessions); - listenTo(deleteDataConfirmationCtrl); - cmc = new CloseableModalController(getWindowControl(), translate("close"), - deleteDataConfirmationCtrl.getInitialComponent(), true, translate("run.command.delete.data.all.title"), true); - listenTo(cmc); - cmc.activate(); - } - - private void doDeleteAllData(UserRequest ureq) { - evaluationFormManager.deleteAllData(survey); - initVelocityContainer(ureq); - } - - private void doShowExecution(UserRequest ureq) { - removeAllComponents(); - EvaluationFormSession session = loadOrCreateSesssion(participation); - executionCtrl = new EvaluationFormExecutionController(ureq, getWindowControl(), session); - listenTo(executionCtrl); - mainVC.put("execution", executionCtrl.getInitialComponent()); - } - - private void doShowReporting(UserRequest ureq) { - removeAllComponents(); - participation = loadOrCreateParticipation(ureq); - Controller reportingCtrl = new SurveyReportingController(ureq, getWindowControl(), survey); - mainVC.put("reporting", reportingCtrl.getInitialComponent()); - } - - private void doShowNoAccess(UserRequest ureq) { - String title = getTranslator().translate("run.noaccess.title"); - String message = getTranslator().translate("run.noaccess.message"); - doShowMessage(ureq, title, message); - } - - private void doShowReadOnly(UserRequest ureq) { - Translator trans = Util.createPackageTranslator(SurveyCourseNode.class, getLocale()); - String title = trans.translate("freezenoaccess.title"); - String message = trans.translate("freezenoaccess.message"); - doShowMessage(ureq, title, message); - } - - private void doShowParticipationDone(UserRequest ureq) { - String title = getTranslator().translate("run.participation.done.title"); - String message = getTranslator().translate("run.participation.done.message"); - doShowMessage(ureq, title, message); - } - - private void doShowMessage(UserRequest ureq, String title, String message) { - removeAllComponents(); - Controller ctrl = MessageUIFactory.createInfoMessage(ureq, getWindowControl(), title, message); - mainVC.put("message", ctrl.getInitialComponent()); - } - - private void removeAllComponents() { - mainVC.remove("message"); - mainVC.remove("execution"); - mainVC.remove("reporting"); - } - - @Override - protected void doDispose() { - removeAsListenerAndDispose(executionCtrl); - executionCtrl = null; - } - -} diff --git a/src/main/java/org/olat/course/nodes/survey/ui/SurveyReportingController.java b/src/main/java/org/olat/course/nodes/survey/ui/SurveyReportingController.java index 0390897757309ad22968de2c5b97c6f2a491ac7d..ade781e3fd7bd636ea943898a68d9aea95f519d4 100644 --- a/src/main/java/org/olat/course/nodes/survey/ui/SurveyReportingController.java +++ b/src/main/java/org/olat/course/nodes/survey/ui/SurveyReportingController.java @@ -25,13 +25,17 @@ import org.olat.core.gui.components.velocity.VelocityContainer; import org.olat.core.gui.control.Event; import org.olat.core.gui.control.WindowControl; import org.olat.core.gui.control.controller.BasicController; +import org.olat.course.nodes.SurveyCourseNode; import org.olat.course.nodes.survey.SurveyManager; import org.olat.modules.ceditor.DataStorage; import org.olat.modules.forms.EvaluationFormSurvey; +import org.olat.modules.forms.Figures; +import org.olat.modules.forms.FiguresBuilder; import org.olat.modules.forms.SessionFilter; import org.olat.modules.forms.SessionFilterFactory; import org.olat.modules.forms.model.xml.Form; import org.olat.modules.forms.ui.EvaluationFormReportsController; +import org.olat.repository.RepositoryEntry; import org.springframework.beans.factory.annotation.Autowired; /** @@ -47,14 +51,20 @@ public class SurveyReportingController extends BasicController { @Autowired private SurveyManager surveyManager; - public SurveyReportingController(UserRequest ureq, WindowControl wControl, EvaluationFormSurvey survey) { + public SurveyReportingController(UserRequest ureq, WindowControl wControl, RepositoryEntry courseEntry, + SurveyCourseNode courseNode, EvaluationFormSurvey survey) { super(ureq, wControl); mainVC = createVelocityContainer("reporting"); Form form = surveyManager.loadForm(survey); DataStorage storage = surveyManager.loadStorage(survey); SessionFilter filter = SessionFilterFactory.createSelectDone(survey); - EvaluationFormReportsController reportsCtrl = new EvaluationFormReportsController(ureq, wControl, form, storage, filter); + + Figures figures = FiguresBuilder.builder() + .addCustomFigure(translate("figure.course"), courseEntry.getDisplayname()) + .addCustomFigure(translate("figure.course.node"), courseNode.getShortTitle()) + .build(); + EvaluationFormReportsController reportsCtrl = new EvaluationFormReportsController(ureq, wControl, form, storage, filter, figures); mainVC.put("report", reportsCtrl.getInitialComponent()); putInitialPanel(mainVC); diff --git a/src/main/java/org/olat/course/nodes/survey/ui/SurveyRunController.java b/src/main/java/org/olat/course/nodes/survey/ui/SurveyRunController.java index 4f5c79f61b68b4ce766b7c9b281c589abc53fe35..4b3efbce6ae261d56a554392072cdb314ab6bafa 100644 --- a/src/main/java/org/olat/course/nodes/survey/ui/SurveyRunController.java +++ b/src/main/java/org/olat/course/nodes/survey/ui/SurveyRunController.java @@ -65,6 +65,7 @@ public class SurveyRunController extends BasicController { private EvaluationFormExecutionController executionCtrl; private final UserCourseEnvironment userCourseEnv; + private final RepositoryEntry courseEntry; private final SurveyCourseNode courseNode; private final SurveyRunSecurityCallback secCallback; private final EvaluationFormSurveyIdentifier surveyIdent; @@ -79,7 +80,7 @@ public class SurveyRunController extends BasicController { super(ureq, wControl); this.userCourseEnv = userCourseEnv; this.courseNode = courseNode; - RepositoryEntry courseEntry = userCourseEnv.getCourseEnvironment().getCourseGroupManager().getCourseEntry(); + this.courseEntry = userCourseEnv.getCourseEnvironment().getCourseGroupManager().getCourseEntry(); this.surveyIdent = surveyManager.getSurveyIdentifier(courseNode, courseEntry); this.secCallback = secCallback; @@ -204,7 +205,7 @@ public class SurveyRunController extends BasicController { private void doShowReporting(UserRequest ureq) { removeAllComponents(); participation = loadOrCreateParticipation(ureq); - Controller reportingCtrl = new SurveyReportingController(ureq, getWindowControl(), survey); + Controller reportingCtrl = new SurveyReportingController(ureq, getWindowControl(), courseEntry, courseNode, survey); mainVC.put("reporting", reportingCtrl.getInitialComponent()); } diff --git a/src/main/java/org/olat/course/nodes/survey/ui/SurveyStatisticResourceResult.java b/src/main/java/org/olat/course/nodes/survey/ui/SurveyStatisticResourceResult.java index dc36f9538a10c29a4fcc892a70b9dcef12bab773..7d2afca4d11ab7f9444048f0648f2f778b8168bf 100644 --- a/src/main/java/org/olat/course/nodes/survey/ui/SurveyStatisticResourceResult.java +++ b/src/main/java/org/olat/course/nodes/survey/ui/SurveyStatisticResourceResult.java @@ -30,12 +30,14 @@ import org.olat.core.gui.control.generic.messages.SimpleMessageController; import org.olat.core.gui.translator.Translator; import org.olat.core.id.Identity; import org.olat.core.util.Util; +import org.olat.course.nodes.SurveyCourseNode; import org.olat.course.nodes.survey.SurveyRunSecurityCallback; import org.olat.course.statistic.StatisticResourceResult; import org.olat.modules.forms.EvaluationFormManager; import org.olat.modules.forms.EvaluationFormParticipation; import org.olat.modules.forms.EvaluationFormSurvey; import org.olat.modules.forms.EvaluationFormSurveyIdentifier; +import org.olat.repository.RepositoryEntry; import org.springframework.beans.factory.annotation.Autowired; /** @@ -46,16 +48,18 @@ import org.springframework.beans.factory.annotation.Autowired; */ public class SurveyStatisticResourceResult implements StatisticResourceResult { - private final EvaluationFormSurveyIdentifier surveyIdent; + private final RepositoryEntry courseEntry; + private final SurveyCourseNode courseNode; private final Identity identity; private final SurveyRunSecurityCallback secCallback; @Autowired private EvaluationFormManager evaluationFormManager; - public SurveyStatisticResourceResult(EvaluationFormSurveyIdentifier surveyIdent, Identity identity, + public SurveyStatisticResourceResult(RepositoryEntry courseEntry, SurveyCourseNode courseNode, Identity identity, SurveyRunSecurityCallback secCallback) { - this.surveyIdent = surveyIdent; + this.courseEntry = courseEntry; + this.courseNode = courseNode; this.identity = identity; this.secCallback = secCallback; CoreSpringFactory.autowireObject(this); @@ -69,10 +73,10 @@ public class SurveyStatisticResourceResult implements StatisticResourceResult { @Override public Controller getController(UserRequest ureq, WindowControl wControl, TooledStackedPanel stackPanel, TreeNode selectedNode) { - EvaluationFormSurvey survey = evaluationFormManager.loadSurvey(surveyIdent); + EvaluationFormSurvey survey = evaluationFormManager.loadSurvey(EvaluationFormSurveyIdentifier.of(courseEntry, courseNode.getIdent())); EvaluationFormParticipation participation = evaluationFormManager.loadParticipationByExecutor(survey, identity); if (secCallback.canViewReporting(participation)) { - return new SurveyReportingController(ureq, wControl, survey); + return new SurveyReportingController(ureq, wControl, courseEntry, courseNode, survey); } Translator translator = Util.createPackageTranslator(SurveyReportingController.class, ureq.getLocale()); String noAccess = translator.translate("report.noaccess"); diff --git a/src/main/java/org/olat/course/nodes/survey/ui/_i18n/LocalStrings_de.properties b/src/main/java/org/olat/course/nodes/survey/ui/_i18n/LocalStrings_de.properties index 984725549fb831bb8838fa6b513108d00b32d9d2..56d4753a81a90b5ee40a1fd20ba7f389d0309749 100644 --- a/src/main/java/org/olat/course/nodes/survey/ui/_i18n/LocalStrings_de.properties +++ b/src/main/java/org/olat/course/nodes/survey/ui/_i18n/LocalStrings_de.properties @@ -1,40 +1,42 @@ course.node.link.text=Umfrage -edit.choose=W\u00E4hlen, erstellen oder importieren -edit.choose.evaluation.form=Fragebogen ausw\u00E4hlen +edit.choose=W\u00e4hlen, erstellen oder importieren +edit.choose.evaluation.form=Fragebogen ausw\u00e4hlen edit.edit=Bearbeiten edit.execution=Teilnahme durch edit.execution.by.owner=Besitzer edit.execution.by.coach=Betreuer edit.execution.by.participant=Teilnehmer -edit.execution.by.guest=G\u00E4ste +edit.execution.by.guest=G\u00e4ste edit.preview=Vorschau edit.evaluation.form=Fragebogen edit.evaluation.form.link={0} -edit.evaluation.form.not.choosen=Kein Fragebogen ausw\u00E4hlt +edit.evaluation.form.not.choosen=Kein Fragebogen ausw\u00e4hlt edit.replace=Ersetzen -edit.report=Resultate sichtbar f\u00FCr +edit.report=Resultate sichtbar f\u00fcr edit.report.for.owner=Besitzer edit.report.for.coach=Betreuer edit.report.for.participant=Teilnehmer -edit.report.for.guest=G\u00E4ste +edit.report.for.guest=G\u00e4ste edit.title=Umfrage -error.repo.no.key.long=F\u00FCr "{0}" muss in der Konfiguration ein Fragebogen im Reiter "Umfrage" ausgew\u00E4hlt werden. -error.repo.no.key.short=Es ist kein Fragebogen ausw\u00E4hlt. -error.repo.entry.missing=Der Fragebogen, welchen Sie anzeigen m\u00F6chten, wurde in der Zwischenzeit aus der Ablage der Lernressourcen gel\u00F6scht. -error.repo.entry.not.replaceable=Der Fragebogen kann nicht mehr ge\u00E4ndert werden. +error.repo.no.key.long=F\u00fcr "{0}" muss in der Konfiguration ein Fragebogen im Reiter "Umfrage" ausgew\u00e4hlt werden. +error.repo.no.key.short=Es ist kein Fragebogen ausw\u00e4hlt. +error.repo.entry.missing=Der Fragebogen, welchen Sie anzeigen m\u00f6chten, wurde in der Zwischenzeit aus der Ablage der Lernressourcen gel\u00f6scht. +error.repo.entry.not.replaceable=Der Fragebogen kann nicht mehr ge\u00e4ndert werden. +figure.course=Kurs +figure.course.node=Kursbaustein fully.assessed.trigger.status.done=Fragebogen eingereicht pane.tab.config=Umfrage report.noaccess=Sie haben keinen Zugang zu den Statistiken dieser Umfrage. Entweder fehlen ihnen die entsprechenden Berechtigungen oder Sie haben an der Umfrage noch nicht teilgenommen. -run.command.delete.data.all=Umfrage zur\u00FCksetzen -run.command.delete.data.all.confirmation.error=Best\u00E4tigen Sie bitte das L\u00F6schen. -run.command.delete.data.all.button=L\u00F6schen -run.command.delete.data.all.check=Alle Antworten l\u00F6schen -run.command.delete.data.all.message=Wollen Sie wirklich alle Antworten l\u00F6schen? Es haben bereits {0} Benutzer/innen an dieser Umfrage teilgenommen. Die Antworten k\u00F6nnen nicht wieder hergestellt werden! -run.command.delete.data.all.title=Alle Antworten l\u00F6schen -run.participation.done.message=Sie haben den Fragebogen bereits ausgef\u00FCllt. Vielen Dank f\u00FCr Ihre Teilnahme. -run.participation.done.title=Fragebogen ausgef\u00FCllt -run.noaccess.message=Dieser Teil des Kurses ist f\u00FCr Sie nicht zug\u00E4nglich. +run.command.delete.data.all=Umfrage zur\u00fcksetzen +run.command.delete.data.all.confirmation.error=Best\u00e4tigen Sie bitte das L\u00f6schen. +run.command.delete.data.all.button=L\u00f6schen +run.command.delete.data.all.check=Alle Antworten l\u00f6schen +run.command.delete.data.all.message=Wollen Sie wirklich alle Antworten l\u00f6schen? Es haben bereits {0} Benutzer/innen an dieser Umfrage teilgenommen. Die Antworten k\u00f6nnen nicht wieder hergestellt werden! +run.command.delete.data.all.title=Alle Antworten l\u00f6schen +run.participation.done.message=Sie haben den Fragebogen bereits ausgef\u00fcllt. Vielen Dank f\u00fcr Ihre Teilnahme. +run.participation.done.title=Fragebogen ausgef\u00fcllt +run.noaccess.message=Dieser Teil des Kurses ist f\u00fcr Sie nicht zug\u00e4nglich. run.noaccess.title=Kein Zugang run.no.survey.title=Umfrage nicht bereit. run.no.survey.message=Diese Umfrage steht nicht zur Teilnahme bereit. -run.reset=Zur\u00FCcksetzen +run.reset=Zur\u00fccksetzen diff --git a/src/main/java/org/olat/course/nodes/survey/ui/_i18n/LocalStrings_en.properties b/src/main/java/org/olat/course/nodes/survey/ui/_i18n/LocalStrings_en.properties index e2ad852840dd21c15f77d6378e4b17d1ba2a00f1..56e0442448ccbd3b5f58881f173a8ecc6c24c07d 100644 --- a/src/main/java/org/olat/course/nodes/survey/ui/_i18n/LocalStrings_en.properties +++ b/src/main/java/org/olat/course/nodes/survey/ui/_i18n/LocalStrings_en.properties @@ -22,6 +22,8 @@ error.repo.no.key.long=For "{0}" you have to select a questionnaire in the tab " error.repo.no.key.short=No questionnaire chosen. error.repo.entry.missing=This survey has been deleted in the meantime within the storage folder of learning resources. error.repo.entry.not.replaceable=The questionnaire can not be replaced anymore. +figure.course=Course +figure.course.node=Course element fully.assessed.trigger.status.done=Survey finished pane.tab.config=Survey report.noaccess=You do not have access to the statistics of this survey. Either you do not have the required rights or you do not have finished your participation. diff --git a/src/main/java/org/olat/modules/forms/ui/EvaluationFormReportsController.java b/src/main/java/org/olat/modules/forms/ui/EvaluationFormReportsController.java index 2707bddebbfc62e1ff4a125ce2315a48ffa6733b..397e28f82483270d3e7194331ad3ebdddd845213 100644 --- a/src/main/java/org/olat/modules/forms/ui/EvaluationFormReportsController.java +++ b/src/main/java/org/olat/modules/forms/ui/EvaluationFormReportsController.java @@ -71,13 +71,9 @@ public class EvaluationFormReportsController extends BasicController { @Autowired private PdfModule pdfModule; - public EvaluationFormReportsController(UserRequest ureq, WindowControl wControl, Form form, DataStorage storage, SessionFilter filter) { - this(ureq, wControl, form, storage, filter, null); - } - - public EvaluationFormReportsController(UserRequest ureq, WindowControl wControl, Form form, DataStorage storage, SessionFilter filter, - ReportSegment show) { - this(ureq, wControl, form, storage, filter, show, null, null, null); + public EvaluationFormReportsController(UserRequest ureq, WindowControl wControl, Form form, DataStorage storage, + SessionFilter filter, Figures figures) { + this(ureq, wControl, form, storage, filter, null, null, figures, null); } public EvaluationFormReportsController(UserRequest ureq, WindowControl wControl, Form form, DataStorage storage, SessionFilter filter, diff --git a/src/test/java/org/olat/selenium/page/course/CourseEditorPageFragment.java b/src/test/java/org/olat/selenium/page/course/CourseEditorPageFragment.java index 81c02d4f132c95201526aa937a0400d8bfd0f01f..73e66f0fba97a202a48e03feb5df3776d31f6d89 100644 --- a/src/test/java/org/olat/selenium/page/course/CourseEditorPageFragment.java +++ b/src/test/java/org/olat/selenium/page/course/CourseEditorPageFragment.java @@ -536,11 +536,10 @@ public class CourseEditorPageFragment { * @return */ public PublisherPageFragment publish() { - WebElement publishButton = browser.findElement(publishButtonBy); - Assert.assertTrue(publishButton.isDisplayed()); - publishButton.click(); + OOGraphene.waitElement(publishButtonBy, browser); + browser.findElement(publishButtonBy).click(); OOGraphene.waitBusyAndScrollTop(browser); - OOGraphene.waitElement(By.cssSelector("div.o_sel_publish_nodes"), 5, browser); + OOGraphene.waitElement(By.cssSelector("div.o_sel_publish_nodes"), browser); return new PublisherPageFragment(browser); }