Change how the HOME_VIEW setting is defined

HOME_VIEW is now COMMON_HOME_VIEW.

Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
This commit is contained in:
Roberto Rosario
2019-04-11 22:00:33 -04:00
parent 4c8e647415
commit 4d91d82515
8 changed files with 26 additions and 14 deletions

View File

@@ -9,6 +9,9 @@ from django.utils.translation import ugettext_lazy as _
import mayan
from mayan.apps.smart_settings import Namespace
from .literals import DEFAULT_COMMON_HOME_VIEW
namespace = Namespace(name='common', label=_('Common'))
setting_auto_logging = namespace.add_setting(
@@ -24,6 +27,14 @@ settings_db_sync_task_delay = namespace.add_setting(
'propagate.'
)
)
setting_home_view = namespace.add_setting(
global_name='COMMON_HOME_VIEW',
default=DEFAULT_COMMON_HOME_VIEW, help_text=_(
'Name of the view attached to the branch anchor in the main menu. '
'This is also the view to which users will be redirected after '
'log in.'
),
)
setting_paginate_by = namespace.add_setting(
global_name='COMMON_PAGINATE_BY',
default=40,
@@ -234,14 +245,6 @@ setting_django_file_upload_max_memory_size = namespace.add_setting(
'DATA_UPLOAD_MAX_MEMORY_SIZE.'
),
)
# Not really a Django setting, but since it is flat and defined in setting.py
# We need to put it here.
setting_home_view = namespace.add_setting(
global_name='HOME_VIEW',
default=settings.HOME_VIEW, help_text=_(
'Name of the view attached to the branch anchor in the main menu.'
),
)
setting_django_installed_apps = namespace.add_setting(
global_name='INSTALLED_APPS',
default=settings.INSTALLED_APPS,