1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Merge branch 'feature' into 6732-asn-model

This commit is contained in:
Daniel Sheppard
2021-11-03 08:37:11 -05:00
committed by GitHub
40 changed files with 1137 additions and 19 deletions

View File

@@ -599,6 +599,12 @@ class Interface(ComponentModel, BaseInterface, LinkTermination, PathEndpoint):
object_id_field='assigned_object_id',
related_query_name='interface'
)
fhrp_group_assignments = GenericRelation(
to='ipam.FHRPGroupAssignment',
content_type_field='interface_type',
object_id_field='interface_id',
related_query_name='+'
)
clone_fields = ['device', 'parent', 'bridge', 'lag', 'type', 'mgmt_only']

View File

@@ -1747,7 +1747,7 @@ class InterfaceView(generic.ObjectView):
def get_extra_context(self, request, instance):
# Get assigned IP addresses
ipaddress_table = InterfaceIPAddressTable(
ipaddress_table = AssignedIPAddressesTable(
data=instance.ip_addresses.restrict(request.user, 'view').prefetch_related('vrf', 'tenant'),
orderable=False
)