diff --git a/mayan/apps/common/apps.py b/mayan/apps/common/apps.py index 53df51ce0d..c70585fc1b 100644 --- a/mayan/apps/common/apps.py +++ b/mayan/apps/common/apps.py @@ -213,11 +213,11 @@ class CommonApp(MayanAppConfig): if os.path.exists(settings.MEDIA_ROOT) and setting_production_error_logging.value: logging_configuration['handlers']['logfile'] = { - 'backupCount': 3, - 'class': 'logging.handlers.RotatingFileHandler', - 'filename': setting_production_error_log_path.value, - 'formatter': 'logfile', - 'maxBytes': 1024, + 'backupCount': 3, + 'class': 'logging.handlers.RotatingFileHandler', + 'filename': setting_production_error_log_path.value, + 'formatter': 'logfile', + 'maxBytes': 1024, } logging.config.dictConfig(logging_configuration) diff --git a/mayan/apps/common/icons.py b/mayan/apps/common/icons.py index 49e4dff16d..413e807e62 100644 --- a/mayan/apps/common/icons.py +++ b/mayan/apps/common/icons.py @@ -40,6 +40,6 @@ icon_setup = Icon( icon_support = Icon( driver_name='fontawesome', symbol='phone' ) -icon_tools = Icon( +icon_tools = Icon( driver_name='fontawesome', symbol='wrench' ) diff --git a/mayan/apps/common/management/commands/initialsetup.py b/mayan/apps/common/management/commands/initialsetup.py index 1eeb3de98a..91eba1078a 100644 --- a/mayan/apps/common/management/commands/initialsetup.py +++ b/mayan/apps/common/management/commands/initialsetup.py @@ -31,6 +31,7 @@ class Command(management.BaseCommand): '--no-javascript', action='store_true', dest='no_javascript', help='Don\'t download the Javascript dependencies.', ) + def initialize_system(self, force=False): system_path = os.path.join(settings.MEDIA_ROOT, SYSTEM_DIR) settings_path = os.path.join(settings.MEDIA_ROOT, 'mayan_settings') diff --git a/mayan/apps/common/widgets.py b/mayan/apps/common/widgets.py index 01030856a1..f8ebf0fca4 100644 --- a/mayan/apps/common/widgets.py +++ b/mayan/apps/common/widgets.py @@ -4,7 +4,6 @@ from django import forms from django.utils.encoding import force_text from django.utils.html import format_html from django.utils.safestring import mark_safe -from django.utils.translation import ugettext_lazy as _ class DisableableSelectWidget(forms.SelectMultiple): diff --git a/mayan/apps/documents/runtime.py b/mayan/apps/documents/runtime.py index 15c09b5dd0..f10fe5204d 100644 --- a/mayan/apps/documents/runtime.py +++ b/mayan/apps/documents/runtime.py @@ -6,8 +6,6 @@ from django.utils.translation import ugettext_lazy as _ from .settings import setting_language_codes -import operator - language_choices = sorted( [ ( diff --git a/mayan/apps/ocr/links.py b/mayan/apps/ocr/links.py index fff0e796df..6aa928b700 100644 --- a/mayan/apps/ocr/links.py +++ b/mayan/apps/ocr/links.py @@ -46,7 +46,7 @@ link_document_ocr_errors_list = Link( view='ocr:document_ocr_error_list' ) link_document_ocr_download = Link( - args='resolved_object.id', icon_class=icon_document_ocr_download, + args='resolved_object.id', icon_class=icon_document_ocr_download, permissions=(permission_ocr_content_view,), text=_('Download OCR text'), view='ocr:document_ocr_download' ) diff --git a/mayan/apps/sources/tests/test_models.py b/mayan/apps/sources/tests/test_models.py index 05e8b11279..ca050d6546 100644 --- a/mayan/apps/sources/tests/test_models.py +++ b/mayan/apps/sources/tests/test_models.py @@ -18,7 +18,7 @@ from metadata.models import MetadataType from ..literals import SOURCE_UNCOMPRESS_CHOICE_Y from ..models import ( - EmailBaseModel, IMAPEmail, POP3Email, WatchFolderSource, WebFormSource + EmailBaseModel, POP3Email, WatchFolderSource, WebFormSource ) from .literals import (