mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-23 11:53:12 +00:00
Merge branch 'fix_sw_order' into 'dev'
Fix display switchs order See merge request federez/re2o!343
This commit is contained in:
commit
a9ec23c260
2 changed files with 2 additions and 2 deletions
|
@ -120,7 +120,7 @@ class EditOptionalTopologieForm(ModelForm):
|
|||
self.fields['vlan_decision_nok'].label = _("VLAN for machines rejected"
|
||||
" by RADIUS")
|
||||
|
||||
self.initial['automatic_provision_switchs'] = Switch.objects.filter(automatic_provision=True)
|
||||
self.initial['automatic_provision_switchs'] = Switch.objects.filter(automatic_provision=True).order_by('interface__domain__name')
|
||||
|
||||
def save(self, commit=True):
|
||||
instance = super().save(commit)
|
||||
|
|
|
@ -260,7 +260,7 @@ class OptionalTopologie(AclMixin, PreferencesModel):
|
|||
def provisioned_switchs(self):
|
||||
"""Liste des switches provisionnés"""
|
||||
from topologie.models import Switch
|
||||
return Switch.objects.filter(automatic_provision=True)
|
||||
return Switch.objects.filter(automatic_provision=True).order_by('interface__domain__name')
|
||||
|
||||
@cached_property
|
||||
def switchs_management_interface(self):
|
||||
|
|
Loading…
Reference in a new issue