Moves this to the more standard Django location
This commit is contained in:
parent
6d1f9b0e0c
commit
6d8ffa3382
@ -9,7 +9,7 @@ from django.db.utils import OperationalError
|
||||
from django.db.utils import ProgrammingError
|
||||
|
||||
from documents.signals import document_consumer_declaration
|
||||
from documents.templatetags import convert_to_django_template_format
|
||||
from documents.templatetags.filepath import convert_to_django_template_format
|
||||
|
||||
|
||||
@register()
|
||||
|
@ -17,7 +17,7 @@ from documents.models import Document
|
||||
from documents.models import DocumentType
|
||||
from documents.models import StoragePath
|
||||
from documents.models import Tag
|
||||
from documents.templatetags import convert_to_django_template_format
|
||||
from documents.templatetags.filepath import convert_to_django_template_format
|
||||
|
||||
logger = logging.getLogger("paperless.filehandling")
|
||||
|
||||
@ -26,7 +26,7 @@ INVALID_VARIABLE_STR = "InvalidVarError"
|
||||
filepath_engine = Engine(
|
||||
autoescape=False,
|
||||
string_if_invalid=f"{INVALID_VARIABLE_STR}: %s",
|
||||
libraries={"filepath": "documents.templatetags"},
|
||||
libraries={"filepath": "documents.templatetags.filepath"},
|
||||
)
|
||||
|
||||
|
||||
|
@ -10,7 +10,7 @@ def convert_from_format_to_template(apps, schema_editor):
|
||||
|
||||
StoragePath = apps.get_model("documents", "StoragePath")
|
||||
|
||||
from documents.templatetags import convert_to_django_template_format
|
||||
from documents.templatetags.filepath import convert_to_django_template_format
|
||||
|
||||
with transaction.atomic():
|
||||
for storage_path in StoragePath.objects.all():
|
||||
|
0
src/documents/templatetags/__init__.py
Normal file
0
src/documents/templatetags/__init__.py
Normal file
Loading…
x
Reference in New Issue
Block a user