Adapted realm and global styling

This commit is contained in:
2025-02-20 17:07:39 +01:00
parent 0782dc404d
commit a4c3bcd6af
4 changed files with 174 additions and 109 deletions

View File

@@ -5,6 +5,13 @@ def get_oauth2_enabled(applications, application_id):
enabled = app.get('oauth2_proxy', {}).get('enabled', False)
return bool(enabled)
def get_oidc_enabled(applications, application_id):
# Retrieve the application dictionary based on the ID
app = applications.get(application_id, {})
# Retrieve the value for oidc.enabled, default is False
enabled = app.get('oidc', {}).get('enabled', False)
return bool(enabled)
def get_css_enabled(applications, application_id):
# Retrieve the application dictionary based on the given application_id.
app = applications.get(application_id, {})
@@ -16,5 +23,6 @@ class FilterModule(object):
def filters(self):
return {
'get_css_enabled': get_css_enabled,
'get_oidc_enabled': get_oidc_enabled,
'get_oauth2_enabled': get_oauth2_enabled
}