mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-23 11:53:12 +00:00
Merge branch 'master' of https://gitlab.rezometz.org/rezo/re2o
This commit is contained in:
commit
63baecd8a0
1 changed files with 4 additions and 0 deletions
|
@ -10,6 +10,10 @@ class EditPortForm(ModelForm):
|
|||
class Meta(PortForm.Meta):
|
||||
fields = ['room', 'machine_interface', 'related', 'details']
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(EditPortForm, self).__init__(*args, **kwargs)
|
||||
self.fields['related'].queryset = Port.objects.all().order_by('switch', 'port')
|
||||
|
||||
class AddPortForm(ModelForm):
|
||||
class Meta(PortForm.Meta):
|
||||
fields = ['port', 'room', 'machine_interface', 'related', 'details']
|
||||
|
|
Loading…
Reference in a new issue