diff --git a/docs/exam_config.rst b/docs/exam_config.rst index 1fd8441b..376d8bc5 100644 --- a/docs/exam_config.rst +++ b/docs/exam_config.rst @@ -6,10 +6,14 @@ Exam Configuration Overview -------- -An exam configuration defines all the SEB settings for an exam and can be applied to an exam. A SEB client that is connecting to SEB Server +An exam configuration defines all the SEB settings for an exam. A SEB client that is connecting to SEB Server and an exam defined by the SEB Server is downloading this exam configuration from SEB Server and reconfigure itself before accessing the exam on the learning management system (LMS) and present it to the user. +.. note:: + For more information and detailed description of the SEB exam settings, see `SEB Configuration `_. + Currently not all settings are available and some has different uses. For details about differences see :ref:`setting-dif-label` + An exam administrator is able to create, modify and maintain exam configurations while the SEB Server administrator and the institutional administrator role have only read access either for all exam configurations or for the exam configurations of the institution. A exam supporter role is able to see and modify only the exam configurations to which the user-account is assigned as supporter. @@ -76,6 +80,17 @@ Use Cases **Create new Exam Configuration** +For the upcoming semester you have to create several new exam configurations for the different kind of exams your institution is going to provide +during the semester. + +- Sign into SEB Server with your exam administrator role account +- Navigate to the "Exam Configuration" menu within the SEB Configuration section on the left hand side. +- You see a list of all available exam configuration. +- Use the "Add Exam Configuration" action on the action pane on the right hand side to create a new exam configuration +- The creation form at least needs a unique name for the exam configuration. You can also add a description or hint to recognize and find this configuration more easily later on. +- In the "Status" field you are able to choose if the configuration is still under construction and cannot be added to exams yet, or if it is ready to use. +- Save the form with the "Save Exam Configuration" action at the right action pane to create the configuration. + **Edit SEB Settings and prepare for Use** **Export an Exam Configuration** diff --git a/docs/images/account/list_serveradmin.png b/docs/images/account/list_serveradmin.png index 0a194ef8..0dd22a79 100644 Binary files a/docs/images/account/list_serveradmin.png and b/docs/images/account/list_serveradmin.png differ diff --git a/docs/useraccount.rst b/docs/useraccount.rst index 918c0c20..52afe1a7 100644 --- a/docs/useraccount.rst +++ b/docs/useraccount.rst @@ -38,6 +38,7 @@ of all institution within a SEB Server instance. The filter above the list can b - "Institution" filter to select a certain institution and show only the user-accounts that belongs to this institution. - "First Name" filter to search for user-accounts with the given occurrence of text in the First Name. +- "Surname" filter to search for user-accounts with the given occurrence of text in the Surname. - "User Name" filter to search for user-accounts with the given occurrence of text in the Username. - "Mail" filter to find an user-account by e-mail address - "Status" filter to select the either and see either only active, only inactive or all user-accounts diff --git a/src/main/java/ch/ethz/seb/sebserver/gui/content/LmsSetupList.java b/src/main/java/ch/ethz/seb/sebserver/gui/content/LmsSetupList.java index 49ceb0f9..ea8e2221 100644 --- a/src/main/java/ch/ethz/seb/sebserver/gui/content/LmsSetupList.java +++ b/src/main/java/ch/ethz/seb/sebserver/gui/content/LmsSetupList.java @@ -178,10 +178,13 @@ public class LmsSetupList implements TemplateComposer { .publishIf(() -> userGrant.im() && table.hasAnyContent(), false) .newAction(ActionDefinition.LMS_SETUP_TOGGLE_ACTIVITY) - .withExec(this.pageService.activationToggleActionFunction( - table, - EMPTY_SELECTION_TEXT_KEY, - action -> LmsSetupForm.testLmsSetup(action, null, restService))) + .withSelect( + table.getGrantedSelection(currentUser, NO_MODIFY_PRIVILEGE_ON_OTHER_INSTITUTION), + this.pageService.activationToggleActionFunction( + table, + EMPTY_SELECTION_TEXT_KEY, + action -> LmsSetupForm.testLmsSetup(action, null, restService)), + EMPTY_SELECTION_TEXT_KEY) .withConfirm(this.pageService.confirmDeactivation(table)) .publishIf(() -> userGrant.im() && table.hasAnyContent(), false); diff --git a/src/main/java/ch/ethz/seb/sebserver/gui/content/SebClientConfigList.java b/src/main/java/ch/ethz/seb/sebserver/gui/content/SebClientConfigList.java index 885e7180..461ae3f0 100644 --- a/src/main/java/ch/ethz/seb/sebserver/gui/content/SebClientConfigList.java +++ b/src/main/java/ch/ethz/seb/sebserver/gui/content/SebClientConfigList.java @@ -181,12 +181,13 @@ public class SebClientConfigList implements TemplateComposer { .publishIf(() -> clientConfigGrant.im() && table.hasAnyContent(), false) .newAction(ActionDefinition.SEB_CLIENT_CONFIG_TOGGLE_ACTIVITY) - .withExec(this.pageService.activationToggleActionFunction(table, EMPTY_SELECTION_TEXT_KEY)) + .withSelect( + table.getGrantedSelection(this.currentUser, NO_MODIFY_PRIVILEGE_ON_OTHER_INSTITUTION), + this.pageService.activationToggleActionFunction(table, EMPTY_SELECTION_TEXT_KEY), + EMPTY_SELECTION_TEXT_KEY) .withConfirm(this.pageService.confirmDeactivation(table)) .publishIf(() -> clientConfigGrant.im() && table.hasAnyContent(), false); - - } private static Function clientConfigInstitutionNameFunction( diff --git a/src/main/java/ch/ethz/seb/sebserver/gui/content/SebExamConfigForm.java b/src/main/java/ch/ethz/seb/sebserver/gui/content/SebExamConfigForm.java index bfa5260d..e2bb8e55 100644 --- a/src/main/java/ch/ethz/seb/sebserver/gui/content/SebExamConfigForm.java +++ b/src/main/java/ch/ethz/seb/sebserver/gui/content/SebExamConfigForm.java @@ -219,7 +219,7 @@ public class SebExamConfigForm implements TemplateComposer { .publishIf(() -> modifyGrant && isReadonly) - .newAction( (!modifyGrant || examConfig.status == ConfigurationStatus.IN_USE) + .newAction((!modifyGrant || examConfig.status == ConfigurationStatus.IN_USE) ? ActionDefinition.SEB_EXAM_CONFIG_VIEW : ActionDefinition.SEB_EXAM_CONFIG_MODIFY) .withEntityKey(entityKey) diff --git a/src/main/java/ch/ethz/seb/sebserver/gui/content/SebExamConfigList.java b/src/main/java/ch/ethz/seb/sebserver/gui/content/SebExamConfigList.java index d370917a..ea7066b3 100644 --- a/src/main/java/ch/ethz/seb/sebserver/gui/content/SebExamConfigList.java +++ b/src/main/java/ch/ethz/seb/sebserver/gui/content/SebExamConfigList.java @@ -170,7 +170,10 @@ public class SebExamConfigList implements TemplateComposer { .publishIf(() -> examConfigGrant.im() && configTable.hasAnyContent(), false) .newAction(ActionDefinition.SEB_EXAM_CONFIG_IMPORT_TO_NEW_CONFIG) - .withExec(SebExamConfigImportPopup.importFunction(this.pageService, true)) + .withSelect( + configTable.getGrantedSelection(this.currentUser, NO_MODIFY_PRIVILEGE_ON_OTHER_INSTITUTION), + SebExamConfigImportPopup.importFunction(this.pageService, true), + EMPTY_SELECTION_TEXT_KEY) .noEventPropagation() .publishIf(examConfigGrant::im); } diff --git a/src/main/java/ch/ethz/seb/sebserver/gui/service/page/PageService.java b/src/main/java/ch/ethz/seb/sebserver/gui/service/page/PageService.java index f45d06bd..c4b22b97 100644 --- a/src/main/java/ch/ethz/seb/sebserver/gui/service/page/PageService.java +++ b/src/main/java/ch/ethz/seb/sebserver/gui/service/page/PageService.java @@ -172,7 +172,7 @@ public interface PageService { return () -> confirmDeactivation(table .getSelectedROWData() .stream() - .filter(Activatable::isActive) // NOTE: Activatable::isActive leads to an error here!? + .filter(entity -> entity.isActive()) // NOTE: Activatable::isActive leads to an error here!? .collect(Collectors.toSet())) .get(); } diff --git a/src/main/java/ch/ethz/seb/sebserver/gui/service/page/event/ActionActivationEvent.java b/src/main/java/ch/ethz/seb/sebserver/gui/service/page/event/ActionActivationEvent.java index 51098fd9..88d8a180 100644 --- a/src/main/java/ch/ethz/seb/sebserver/gui/service/page/event/ActionActivationEvent.java +++ b/src/main/java/ch/ethz/seb/sebserver/gui/service/page/event/ActionActivationEvent.java @@ -26,6 +26,12 @@ public class ActionActivationEvent implements PageEvent { this.decoration = null; } + public ActionActivationEvent(final boolean activation, final Collection actions) { + this.activation = activation; + this.actions = Utils.immutableCollectionOf(actions); + this.decoration = null; + } + public ActionActivationEvent( final boolean activation, final Tuple decoration, diff --git a/src/main/java/ch/ethz/seb/sebserver/webservice/weblayer/api/ActivatableEntityController.java b/src/main/java/ch/ethz/seb/sebserver/webservice/weblayer/api/ActivatableEntityController.java index 6b801ffa..82c90739 100644 --- a/src/main/java/ch/ethz/seb/sebserver/webservice/weblayer/api/ActivatableEntityController.java +++ b/src/main/java/ch/ethz/seb/sebserver/webservice/weblayer/api/ActivatableEntityController.java @@ -146,7 +146,7 @@ public abstract class ActivatableEntityController