1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

implement 3664

This commit is contained in:
kobayashi
2019-12-11 04:48:50 -05:00
parent 0d8fd45587
commit 5710f297f1
10 changed files with 77 additions and 3 deletions

View File

@@ -144,7 +144,7 @@ class ObjectListView(View):
table.columns.show('pk')
# Construct queryset for tags list
if hasattr(model, 'tags'):
if hasattr(model, 'tags') and type(model.tags).__name__ is not 'ManyToManyDescriptor':
tags = model.tags.annotate(count=Count('extras_taggeditem_items')).order_by('name')
else:
tags = None