Update HostManager to return only a single matching hostname for SmartInventory filter

This commit is contained in:
Wayne Witzel III
2017-08-21 01:53:21 -04:00
parent 031b5f3269
commit c352ea7596
2 changed files with 2 additions and 2 deletions

View File

@@ -42,7 +42,7 @@ class HostManager(models.Manager):
# injected by the related object mapper.
self.core_filters = {}
qs = qs & q
return qs.distinct()
return qs.order_by('pk').distinct('name')
return qs