mirror of
https://github.com/netbox-community/netbox.git
synced 2026-04-11 03:37:06 +02:00
* Initial work on #13428 (QinQ) * Misc cleanup; add tests for Q-in-Q fields * Address PR feedback
This commit is contained in:
@@ -461,10 +461,26 @@ class VLANImportForm(NetBoxModelImportForm):
|
||||
to_field_name='name',
|
||||
help_text=_('Functional role')
|
||||
)
|
||||
qinq_role = CSVChoiceField(
|
||||
label=_('Q-in-Q role'),
|
||||
choices=VLANStatusChoices,
|
||||
required=False,
|
||||
help_text=_('Operational status')
|
||||
)
|
||||
qinq_svlan = CSVModelChoiceField(
|
||||
label=_('Q-in-Q SVLAN'),
|
||||
queryset=VLAN.objects.all(),
|
||||
required=False,
|
||||
to_field_name='vid',
|
||||
help_text=_("Service VLAN (for Q-in-Q/802.1ad customer VLANs)")
|
||||
)
|
||||
|
||||
class Meta:
|
||||
model = VLAN
|
||||
fields = ('site', 'group', 'vid', 'name', 'tenant', 'status', 'role', 'description', 'comments', 'tags')
|
||||
fields = (
|
||||
'site', 'group', 'vid', 'name', 'tenant', 'status', 'role', 'description', 'qinq_role', 'qinq_svlan',
|
||||
'comments', 'tags',
|
||||
)
|
||||
|
||||
|
||||
class VLANTranslationPolicyImportForm(NetBoxModelImportForm):
|
||||
|
||||
Reference in New Issue
Block a user