diff --git a/client/src/app/site/pages/meetings/pages/meeting-settings/pages/meeting-settings-group-detail/components/meeting-settings-group-detail-field/meeting-settings-group-detail-field.component.html b/client/src/app/site/pages/meetings/pages/meeting-settings/pages/meeting-settings-group-detail/components/meeting-settings-group-detail-field/meeting-settings-group-detail-field.component.html
index 34cee03cea..19f56cb608 100644
--- a/client/src/app/site/pages/meetings/pages/meeting-settings/pages/meeting-settings-group-detail/components/meeting-settings-group-detail-field/meeting-settings-group-detail-field.component.html
+++ b/client/src/app/site/pages/meetings/pages/meeting-settings/pages/meeting-settings-group-detail/components/meeting-settings-group-detail-field/meeting-settings-group-detail-field.component.html
@@ -95,7 +95,14 @@
{{ setting.label | translate }}
@if (setting.helpText) {
-
{{ setting.helpText | translate }}
+
+ {{ setting.helpText | translate }}
+
+ }
+ @if (getWarning()) {
+
+ {{ setting.warnText | translate }}
+
}
@if (error) {
{{ error }}
diff --git a/client/src/app/site/pages/meetings/pages/meeting-settings/pages/meeting-settings-group-detail/components/meeting-settings-group-detail-field/meeting-settings-group-detail-field.component.ts b/client/src/app/site/pages/meetings/pages/meeting-settings/pages/meeting-settings-group-detail/components/meeting-settings-group-detail-field/meeting-settings-group-detail-field.component.ts
index 79b76f94be..7c3d0b6772 100644
--- a/client/src/app/site/pages/meetings/pages/meeting-settings/pages/meeting-settings-group-detail/components/meeting-settings-group-detail-field/meeting-settings-group-detail-field.component.ts
+++ b/client/src/app/site/pages/meetings/pages/meeting-settings/pages/meeting-settings-group-detail/components/meeting-settings-group-detail-field/meeting-settings-group-detail-field.component.ts
@@ -274,6 +274,18 @@ export class MeetingSettingsGroupDetailFieldComponent extends BaseComponent impl
this.cd.detach();
}
+ /**
+ * Checks if a warning should be given
+ *
+ */
+ public getWarning(): boolean {
+ if (this.setting.warn) {
+ return this.setting.warn(this.orgaSettings);
+ } else {
+ return false;
+ }
+ }
+
public getRestrictedValue
(value: T): T {
if (this.setting.restrictionFn) {
return this.setting.restrictionFn(this.orgaSettings, value);
diff --git a/client/src/app/site/pages/meetings/services/meeting-settings-definition.service/meeting-settings-definitions.ts b/client/src/app/site/pages/meetings/services/meeting-settings-definition.service/meeting-settings-definitions.ts
index 2647b28af6..d5fdb3775f 100644
--- a/client/src/app/site/pages/meetings/services/meeting-settings-definition.service/meeting-settings-definitions.ts
+++ b/client/src/app/site/pages/meetings/services/meeting-settings-definition.service/meeting-settings-definitions.ts
@@ -60,6 +60,7 @@ export interface SettingsInput {
// alternative to `choices`; overwrites `choices` if both are given
choicesFunc?: ChoicesFunctionDefinition;
helpText?: string; // default: ""
+ warnText?: string; // default: ""
indentation?: number; // default: 0. Indents the input field by the given amount to simulate nested settings
validators?: ValidatorFn[]; // default: []
automaticChangesSetting?: SettingsItemAutomaticChangeSetting;
@@ -88,6 +89,13 @@ export interface SettingsInput {
* @returns whether to disable the setting or not
*/
forbidden?: (meetingView: ViewMeeting) => boolean;
+ /**
+ * A function to conditionally give a warning depending on used organization's settings
+ *
+ * @param orgaSettings: The `OrganizationSettingsService` has to be passed, because it is not injected in the
+ * settings definitions
+ */
+ warn?: (orgaSettings: OrganizationSettingsService) => boolean;
hide?: boolean; // Hide the setting in the settings view
}
@@ -207,7 +215,11 @@ export const meetingSettings: SettingsGroup[] = fillInSettingsDefaults([
type: `boolean`,
helpText: _(
`Enables public access to this meeting without login data. Permissions can be set after activation in the new group 'Public'.`
- )
+ ),
+ warnText: _(
+ `The public access setting is deactivated for the organization. Please contact your admins or hosting providers to activate the setting.`
+ ),
+ warn: orgaSettings => !orgaSettings.instant(`enable_anonymous`)
}
]
},