mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-04-02 13:45:10 -05:00
Remove debug line
This commit is contained in:
parent
90b800b030
commit
15fb3e5328
@ -28,12 +28,21 @@ from documents.models import Document
|
||||
from documents.models import MatchingModel
|
||||
from documents.models import PaperlessTask
|
||||
from documents.models import Tag
|
||||
from documents.permissions import get_objects_for_user_owner_aware
|
||||
|
||||
logger = logging.getLogger("paperless.handlers")
|
||||
|
||||
|
||||
def add_inbox_tags(sender, document=None, logging_group=None, **kwargs):
|
||||
inbox_tags = Tag.objects.filter(is_inbox_tag=True)
|
||||
if document.owner is not None:
|
||||
tags = get_objects_for_user_owner_aware(
|
||||
document.owner,
|
||||
"documents.view_documenttype",
|
||||
Tag,
|
||||
)
|
||||
else:
|
||||
tags = Tag.objects.all()
|
||||
inbox_tags = tags.filter(is_inbox_tag=True)
|
||||
document.tags.add(*inbox_tags)
|
||||
|
||||
|
||||
|
@ -194,7 +194,6 @@ class TagViewSet(ModelViewSet, PassUserMixin):
|
||||
)
|
||||
|
||||
def get_serializer_class(self, *args, **kwargs):
|
||||
print(self.request.version)
|
||||
if int(self.request.version) == 1:
|
||||
return TagSerializerVersion1
|
||||
else:
|
||||
|
Loading…
x
Reference in New Issue
Block a user