Move vlan_translation_policy into 802.1Q Switching fieldset

This commit is contained in:
Brian Tiemann 2024-10-28 14:28:01 -04:00
parent 3a50d9f024
commit e0f5fd048b
3 changed files with 3 additions and 5 deletions

View File

@ -1396,12 +1396,11 @@ class InterfaceForm(InterfaceCommonForm, ModularDeviceComponentForm):
FieldSet('vdcs', 'mtu', 'tx_power', 'enabled', 'mgmt_only', 'mark_connected', name=_('Operation')),
FieldSet('parent', 'bridge', 'lag', name=_('Related Interfaces')),
FieldSet('poe_mode', 'poe_type', name=_('PoE')),
FieldSet('mode', 'vlan_group', 'untagged_vlan', 'tagged_vlans', name=_('802.1Q Switching')),
FieldSet('mode', 'vlan_group', 'untagged_vlan', 'tagged_vlans', 'vlan_translation_policy', name=_('802.1Q Switching')),
FieldSet(
'rf_role', 'rf_channel', 'rf_channel_frequency', 'rf_channel_width', 'wireless_lan_group', 'wireless_lans',
name=_('Wireless')
),
FieldSet('vlan_translation_policy', name=_('VLAN Translation'))
)
class Meta:

View File

@ -126,5 +126,5 @@ class VLANTranslationPolicySerializer(NetBoxModelSerializer):
class Meta:
model = VLANTranslationPolicy
fields = ('id', 'url', 'name', 'description', 'display', 'rules')
fields = ['id', 'url', 'name', 'description', 'display', 'rules']
brief_fields = ('id', 'url', 'name', 'description', 'display')

View File

@ -354,8 +354,7 @@ class VMInterfaceForm(InterfaceCommonForm, VMComponentForm):
FieldSet('vrf', 'mac_address', name=_('Addressing')),
FieldSet('mtu', 'enabled', name=_('Operation')),
FieldSet('parent', 'bridge', name=_('Related Interfaces')),
FieldSet('mode', 'vlan_group', 'untagged_vlan', 'tagged_vlans', name=_('802.1Q Switching')),
FieldSet('vlan_translation_policy', name=_('VLAN Translation'))
FieldSet('mode', 'vlan_group', 'untagged_vlan', 'tagged_vlans', 'vlan_translation_policy', name=_('802.1Q Switching')),
)
class Meta: