diff --git a/InvenTree/InvenTree/settings.py b/InvenTree/InvenTree/settings.py index 1446c33aad..8f7b9e2e35 100644 --- a/InvenTree/InvenTree/settings.py +++ b/InvenTree/InvenTree/settings.py @@ -62,12 +62,6 @@ DEBUG = _is_true(get_setting( CONFIG.get('debug', True) )) -# Determine if we are running in "demo mode" -DEMO_MODE = _is_true(get_setting( - 'INVENTREE_DEMO', - CONFIG.get('demo', False) -)) - DOCKER = _is_true(get_setting( 'INVENTREE_DOCKER', False @@ -217,9 +211,6 @@ MEDIA_URL = '/media/' if DEBUG: logger.info("InvenTree running with DEBUG enabled") -if DEMO_MODE: - logger.warning("InvenTree running in DEMO mode") # pragma: no cover - logger.debug(f"MEDIA_ROOT: '{MEDIA_ROOT}'") logger.debug(f"STATIC_ROOT: '{STATIC_ROOT}'") diff --git a/InvenTree/part/templatetags/inventree_extras.py b/InvenTree/part/templatetags/inventree_extras.py index 5701658087..889946ff19 100644 --- a/InvenTree/part/templatetags/inventree_extras.py +++ b/InvenTree/part/templatetags/inventree_extras.py @@ -160,13 +160,6 @@ def inventree_in_debug_mode(*args, **kwargs): return djangosettings.DEBUG -@register.simple_tag() -def inventree_demo_mode(*args, **kwargs): - """ Return True if the server is running in DEMO mode """ - - return djangosettings.DEMO_MODE - - @register.simple_tag() def inventree_show_about(user, *args, **kwargs): """ Return True if the about modal should be shown """ diff --git a/InvenTree/templates/InvenTree/settings/user.html b/InvenTree/templates/InvenTree/settings/user.html index 32bc4d43e7..d06df06d1e 100644 --- a/InvenTree/templates/InvenTree/settings/user.html +++ b/InvenTree/templates/InvenTree/settings/user.html @@ -13,8 +13,8 @@ {% endblock %} {% block actions %} -{% inventree_demo_mode as demo %} -{% if not demo %} +{% inventree_customize 'hide_password_reset' as hide_password_reset %} +{% if hide_password_reset %}
{% trans "Set Password" %}
diff --git a/InvenTree/templates/account/login.html b/InvenTree/templates/account/login.html index fcdd08a23c..3e0865c4b9 100644 --- a/InvenTree/templates/account/login.html +++ b/InvenTree/templates/account/login.html @@ -12,7 +12,6 @@ {% settings_value 'LOGIN_ENABLE_SSO' as enable_sso %} {% inventree_customize 'login_message' as login_message %} {% mail_configured as mail_conf %} -{% inventree_demo_mode as demo %}

{% trans "Sign In" %}

@@ -42,7 +41,7 @@ for a account and sign in below:{% endblocktrans %}

- {% if mail_conf and enable_pwd_forgot and not demo %} + {% if mail_conf and enable_pwd_forgot %} {% trans "Forgot Password?" %} {% endif %} diff --git a/InvenTree/templates/base.html b/InvenTree/templates/base.html index 0188ecefa5..8c2a949353 100644 --- a/InvenTree/templates/base.html +++ b/InvenTree/templates/base.html @@ -8,7 +8,6 @@ {% settings_value "SERVER_RESTART_REQUIRED" as server_restart_required %} {% settings_value "LABEL_ENABLE" with user=user as labels_enabled %} {% inventree_show_about user as show_about %} -{% inventree_demo_mode as demo_mode %} @@ -94,7 +93,7 @@ {% block alerts %}
- {% if server_restart_required and not demo_mode %} + {% if server_restart_required %}