PEP8 cleanups, remove unused imports, add missing imports
This commit is contained in:
@@ -28,7 +28,7 @@ from .links import (document_list, document_list_recent,
|
||||
document_update_page_count, document_clear_transformations,
|
||||
document_print, document_history_view,
|
||||
document_missing_list)
|
||||
from .links import (document_type_list, document_type_setup, document_type_document_list,
|
||||
from .links import (document_type_list, document_type_document_list,
|
||||
document_type_edit, document_type_delete, document_type_create, document_type_filename_list,
|
||||
document_type_filename_create, document_type_filename_edit, document_type_filename_delete,
|
||||
link_documents_menu)
|
||||
@@ -121,4 +121,3 @@ class_permissions(Document, [
|
||||
PERMISSION_DOCUMENT_VERSION_REVERT,
|
||||
PERMISSION_HISTORY_VIEW
|
||||
])
|
||||
|
||||
|
||||
@@ -31,6 +31,7 @@ from .icons import (icon_documents, icon_create_siblings, icon_document_delete,
|
||||
icon_document_type_filename_edit, icon_document_type_filename_delete,
|
||||
icon_document_missing_list)
|
||||
|
||||
|
||||
# Document page links expressions
|
||||
def is_first_page(context):
|
||||
return context['page'].page_number <= 1
|
||||
|
||||
@@ -5,7 +5,7 @@ import tempfile
|
||||
from django.db import models
|
||||
from django.utils.translation import ugettext_lazy as _
|
||||
|
||||
from common.utils import validate_path, encapsulate
|
||||
from common.utils import validate_path
|
||||
|
||||
from .models import DocumentVersion, get_filename_from_uuid
|
||||
from .settings import STORAGE_BACKEND, CACHE_PATH
|
||||
@@ -15,4 +15,4 @@ from .settings import STORAGE_BACKEND, CACHE_PATH
|
||||
if (validate_path(CACHE_PATH) == False) or (not CACHE_PATH):
|
||||
setattr(document_settings, 'CACHE_PATH', tempfile.mkdtemp())
|
||||
|
||||
DocumentVersion._meta.get_field('file').storage=STORAGE_BACKEND()
|
||||
DocumentVersion._meta.get_field('file').storage = STORAGE_BACKEND()
|
||||
|
||||
Reference in New Issue
Block a user