Files
mayan-edms/mayan/apps/checkouts/hooks.py
Roberto Rosario d5fc50272d Enable pre save hook
Signed-off-by: Roberto Rosario <Roberto.Rosario@mayan-edms.com>
2019-01-31 06:07:29 -04:00

14 lines
327 B
Python

from __future__ import unicode_literals
from django.apps import apps
def hook_is_new_version_allowed(document_version):
NewVersionBlock = apps.get_model(
app_label='checkouts', model_name='NewVersionBlock'
)
NewVersionBlock.objects.new_versions_allowed(
document=document_version.document
)