mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-12-25 00:13:45 +00:00
Optimisation sur la methode qui renvoie les interfaces d'un user
This commit is contained in:
parent
b8288bfc57
commit
90b789d51b
1 changed files with 1 additions and 1 deletions
|
@ -378,7 +378,7 @@ class User(AbstractBaseUser):
|
|||
def user_interfaces(self, active=True):
|
||||
""" Renvoie toutes les interfaces dont les machines appartiennent à self
|
||||
Par defaut ne prend que les interfaces actives"""
|
||||
return Interface.objects.filter(machine__in=Machine.objects.filter(user=self, active=active))
|
||||
return Interface.objects.filter(machine__in=Machine.objects.filter(user=self, active=active)).select_related('domain__extension')
|
||||
|
||||
def assign_ips(self):
|
||||
""" Assign une ipv4 aux machines d'un user """
|
||||
|
|
Loading…
Reference in a new issue