SEBSLI-4 implementation
This commit is contained in:
parent
cd9fcff8f0
commit
75c559d01a
9 changed files with 27 additions and 26 deletions
|
@ -150,7 +150,7 @@ public class UserAccountList implements TemplateComposer {
|
||||||
restService.getRestCall(GetUserAccountPage.class))
|
restService.getRestCall(GetUserAccountPage.class))
|
||||||
.withEmptyMessage(EMPTY_TEXT_KEY)
|
.withEmptyMessage(EMPTY_TEXT_KEY)
|
||||||
.withPaging(this.pageSize)
|
.withPaging(this.pageSize)
|
||||||
.withDefaultSort(isSEBAdmin ? Domain.USER.ATTR_INSTITUTION_ID : Domain.USER.ATTR_NAME)
|
.withDefaultSort(Domain.USER.ATTR_NAME)
|
||||||
.withColumnIf(
|
.withColumnIf(
|
||||||
() -> isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
() -> isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
||||||
() -> new ColumnDefinition<>(
|
() -> new ColumnDefinition<>(
|
||||||
|
|
|
@ -194,7 +194,9 @@ public class UserActivityLogs implements TemplateComposer {
|
||||||
? UserActivityLog.FILTER_ATTR_INSTITUTION
|
? UserActivityLog.FILTER_ATTR_INSTITUTION
|
||||||
: UserActivityLog.ATTR_USER_NAME)
|
: UserActivityLog.ATTR_USER_NAME)
|
||||||
.withColumnIf(
|
.withColumnIf(
|
||||||
() -> isSEBAdmin.getAsBoolean() && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
() -> isSEBAdmin.getAsBoolean()
|
||||||
|
&& currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
||||||
|
&& !pageService.isSEBServerLightSetup(),
|
||||||
() -> new ColumnDefinition<>(
|
() -> new ColumnDefinition<>(
|
||||||
UserActivityLog.FILTER_ATTR_INSTITUTION,
|
UserActivityLog.FILTER_ATTR_INSTITUTION,
|
||||||
INSTITUTION_TEXT_KEY,
|
INSTITUTION_TEXT_KEY,
|
||||||
|
|
|
@ -119,9 +119,7 @@ public class ConfigTemplateList implements TemplateComposer {
|
||||||
ConfigurationType.TEMPLATE.name())
|
ConfigurationType.TEMPLATE.name())
|
||||||
.withEmptyMessage(EMPTY_TEMPLATE_LIST_TEXT_KEY)
|
.withEmptyMessage(EMPTY_TEMPLATE_LIST_TEXT_KEY)
|
||||||
.withPaging(this.pageSize)
|
.withPaging(this.pageSize)
|
||||||
.withDefaultSort(isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
.withDefaultSort(Domain.CONFIGURATION_NODE.ATTR_NAME)
|
||||||
? Domain.LMS_SETUP.ATTR_INSTITUTION_ID
|
|
||||||
: Domain.CONFIGURATION_NODE.ATTR_NAME)
|
|
||||||
.withColumnIf(
|
.withColumnIf(
|
||||||
() -> isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
() -> isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
||||||
() -> new ColumnDefinition<>(
|
() -> new ColumnDefinition<>(
|
||||||
|
|
|
@ -125,11 +125,11 @@ public class SEBClientConfigList implements TemplateComposer {
|
||||||
this.pageService.entityTableBuilder(this.restService.getRestCall(GetClientConfigPage.class))
|
this.pageService.entityTableBuilder(this.restService.getRestCall(GetClientConfigPage.class))
|
||||||
.withEmptyMessage(EMPTY_LIST_TEXT_KEY)
|
.withEmptyMessage(EMPTY_LIST_TEXT_KEY)
|
||||||
.withPaging(this.pageSize)
|
.withPaging(this.pageSize)
|
||||||
.withDefaultSort(isSEBAdmin
|
.withDefaultSort(Domain.SEB_CLIENT_CONFIGURATION.ATTR_NAME)
|
||||||
? Domain.LMS_SETUP.ATTR_INSTITUTION_ID
|
|
||||||
: Domain.SEB_CLIENT_CONFIGURATION.ATTR_NAME)
|
|
||||||
.withColumnIf(
|
.withColumnIf(
|
||||||
() -> isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
() -> isSEBAdmin
|
||||||
|
&& currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
||||||
|
&& !pageService.isSEBServerLightSetup(),
|
||||||
() -> new ColumnDefinition<>(
|
() -> new ColumnDefinition<>(
|
||||||
Domain.LMS_SETUP.ATTR_INSTITUTION_ID,
|
Domain.LMS_SETUP.ATTR_INSTITUTION_ID,
|
||||||
INSTITUTION_TEXT_KEY,
|
INSTITUTION_TEXT_KEY,
|
||||||
|
|
|
@ -142,11 +142,11 @@ public class SEBExamConfigList implements TemplateComposer {
|
||||||
ConfigurationType.EXAM_CONFIG.name())
|
ConfigurationType.EXAM_CONFIG.name())
|
||||||
.withEmptyMessage(EMPTY_CONFIG_LIST_TEXT_KEY)
|
.withEmptyMessage(EMPTY_CONFIG_LIST_TEXT_KEY)
|
||||||
.withPaging(this.pageSize)
|
.withPaging(this.pageSize)
|
||||||
.withDefaultSort(isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
.withDefaultSort(Domain.CONFIGURATION_NODE.ATTR_NAME)
|
||||||
? Domain.LMS_SETUP.ATTR_INSTITUTION_ID
|
|
||||||
: Domain.CONFIGURATION_NODE.ATTR_NAME)
|
|
||||||
.withColumnIf(
|
.withColumnIf(
|
||||||
() -> isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
() -> isSEBAdmin
|
||||||
|
&& currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
||||||
|
&& !pageService.isSEBServerLightSetup(),
|
||||||
() -> new ColumnDefinition<>(
|
() -> new ColumnDefinition<>(
|
||||||
Domain.LMS_SETUP.ATTR_INSTITUTION_ID,
|
Domain.LMS_SETUP.ATTR_INSTITUTION_ID,
|
||||||
INSTITUTION_TEXT_KEY,
|
INSTITUTION_TEXT_KEY,
|
||||||
|
|
|
@ -172,12 +172,12 @@ public class ExamList implements TemplateComposer {
|
||||||
.withPaging(this.pageSize)
|
.withPaging(this.pageSize)
|
||||||
.withRowDecorator(decorateOnExamConsistency(this.pageService))
|
.withRowDecorator(decorateOnExamConsistency(this.pageService))
|
||||||
.withStaticFilter(Exam.FILTER_ATTR_ACTIVE, Constants.TRUE_STRING)
|
.withStaticFilter(Exam.FILTER_ATTR_ACTIVE, Constants.TRUE_STRING)
|
||||||
.withDefaultSort(isSEBAdmin.getAsBoolean() && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
.withDefaultSort(Domain.EXAM.ATTR_QUIZ_NAME)
|
||||||
? Domain.EXAM.ATTR_INSTITUTION_ID
|
|
||||||
: Domain.EXAM.ATTR_LMS_SETUP_ID)
|
|
||||||
|
|
||||||
.withColumnIf(
|
.withColumnIf(
|
||||||
() -> isSEBAdmin.getAsBoolean() && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
() -> isSEBAdmin.getAsBoolean()
|
||||||
|
&& currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
||||||
|
&& !pageService.isSEBServerLightSetup(),
|
||||||
() -> new ColumnDefinition<Exam>(
|
() -> new ColumnDefinition<Exam>(
|
||||||
Domain.EXAM.ATTR_INSTITUTION_ID,
|
Domain.EXAM.ATTR_INSTITUTION_ID,
|
||||||
COLUMN_TITLE_INSTITUTION_KEY,
|
COLUMN_TITLE_INSTITUTION_KEY,
|
||||||
|
|
|
@ -135,12 +135,11 @@ public class ExamTemplateList implements TemplateComposer {
|
||||||
this.pageService.entityTableBuilder(restService.getRestCall(GetExamTemplatePage.class))
|
this.pageService.entityTableBuilder(restService.getRestCall(GetExamTemplatePage.class))
|
||||||
.withEmptyMessage(EMPTY_LIST_TEXT_KEY)
|
.withEmptyMessage(EMPTY_LIST_TEXT_KEY)
|
||||||
.withPaging(this.pageSize)
|
.withPaging(this.pageSize)
|
||||||
.withDefaultSort(isSEBAdmin.getAsBoolean() && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
.withDefaultSort(Domain.EXAM_TEMPLATE.ATTR_NAME)
|
||||||
? Domain.EXAM_TEMPLATE.ATTR_INSTITUTION_ID
|
|
||||||
: Domain.EXAM_TEMPLATE.ATTR_NAME)
|
|
||||||
|
|
||||||
.withColumnIf(
|
.withColumnIf(
|
||||||
() -> isSEBAdmin.getAsBoolean() && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
() -> isSEBAdmin.getAsBoolean()
|
||||||
|
&& currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
||||||
() -> new ColumnDefinition<ExamTemplate>(
|
() -> new ColumnDefinition<ExamTemplate>(
|
||||||
Domain.EXAM_TEMPLATE.ATTR_INSTITUTION_ID,
|
Domain.EXAM_TEMPLATE.ATTR_INSTITUTION_ID,
|
||||||
COLUMN_TITLE_INSTITUTION_KEY,
|
COLUMN_TITLE_INSTITUTION_KEY,
|
||||||
|
|
|
@ -124,11 +124,11 @@ public class LmsSetupList implements TemplateComposer {
|
||||||
this.pageService.entityTableBuilder(restService.getRestCall(GetLmsSetupPage.class))
|
this.pageService.entityTableBuilder(restService.getRestCall(GetLmsSetupPage.class))
|
||||||
.withEmptyMessage(EMPTY_LIST_TEXT_KEY)
|
.withEmptyMessage(EMPTY_LIST_TEXT_KEY)
|
||||||
.withPaging(this.pageSize)
|
.withPaging(this.pageSize)
|
||||||
.withDefaultSort(isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
.withDefaultSort(Domain.LMS_SETUP.ATTR_NAME)
|
||||||
? Domain.LMS_SETUP.ATTR_INSTITUTION_ID
|
|
||||||
: Domain.LMS_SETUP.ATTR_NAME)
|
|
||||||
.withColumnIf(
|
.withColumnIf(
|
||||||
() -> !isLight && isSEBAdmin && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
() -> !isLight
|
||||||
|
&& isSEBAdmin
|
||||||
|
&& currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
||||||
() -> new ColumnDefinition<>(
|
() -> new ColumnDefinition<>(
|
||||||
Domain.LMS_SETUP.ATTR_INSTITUTION_ID,
|
Domain.LMS_SETUP.ATTR_INSTITUTION_ID,
|
||||||
INSTITUTION_TEXT_KEY,
|
INSTITUTION_TEXT_KEY,
|
||||||
|
|
|
@ -193,7 +193,9 @@ public class QuizLookupList implements TemplateComposer {
|
||||||
.withPaging(this.pageSize)
|
.withPaging(this.pageSize)
|
||||||
|
|
||||||
.withColumnIf(
|
.withColumnIf(
|
||||||
() -> isSEBAdmin.getAsBoolean() && currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION),
|
() -> isSEBAdmin.getAsBoolean()
|
||||||
|
&& currentUser.isFeatureEnabled(UserFeatures.Feature.ADMIN_INSTITUTION)
|
||||||
|
&& !pageService.isSEBServerLightSetup(),
|
||||||
() -> new ColumnDefinition<QuizData>(
|
() -> new ColumnDefinition<QuizData>(
|
||||||
QuizData.QUIZ_ATTR_INSTITUTION_ID,
|
QuizData.QUIZ_ATTR_INSTITUTION_ID,
|
||||||
INSTITUTION_TEXT_KEY,
|
INSTITUTION_TEXT_KEY,
|
||||||
|
|
Loading…
Reference in a new issue