Remove document flat_tags helper, update document index template accordingly
This commit is contained in:
@@ -11,5 +11,9 @@
|
|||||||
{{ object.file_mimetype }}
|
{{ object.file_mimetype }}
|
||||||
{{ object.description|default:' ' }}
|
{{ object.description|default:' ' }}
|
||||||
{{ object.flat_comments }}
|
{{ object.flat_comments }}
|
||||||
{{ object.flat_tags }}
|
|
||||||
|
{% for tag in object.tags.all %}
|
||||||
|
{{ tag }}
|
||||||
|
{% endfor %}
|
||||||
|
|
||||||
{{ object.uuid }}
|
{{ object.uuid }}
|
||||||
|
|||||||
@@ -66,11 +66,4 @@ class_permissions(Tag, [
|
|||||||
PERMISSION_TAG_VIEW,
|
PERMISSION_TAG_VIEW,
|
||||||
])
|
])
|
||||||
|
|
||||||
|
|
||||||
def flat_tags(document):
|
|
||||||
return u' '.join(document.tags.values_list('name', flat=True))
|
|
||||||
|
|
||||||
|
|
||||||
Document.add_to_class('tags', TaggableManager())
|
Document.add_to_class('tags', TaggableManager())
|
||||||
Document.add_to_class('flat_tags', flat_tags)
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user