[bgpvpn_dashboard] Fix bug when a network or router name doesn't exist

In the popup Update Networks Association the field network can be empty
when a network has no name. Same thing for the routers.
The fix displays the id when name doesn't exist.
Change-Id: I71d4bf3f74997a1d0bf1e84e93d88ac5c22678fc
Closes-Bug:1742948
This commit is contained in:
Cédric Savignan
2018年01月12日 14:59:21 +01:00
parent ad110f3bb6
commit 2d477cd4bd

View File

@@ -47,7 +47,7 @@ class UpdateAssociations(workflows.MembershipAction):
all_resources = self._get_resources(request, context, resource_type,
err_msg)
resources_list = [(resource.id, resource.name)
resources_list = [(resource.id, resource.name_or_id)
for resource in all_resources]
self.fields[field_name].choices = resources_list
Reference in New Issue
openstack/networking-bgpvpn
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.

The note is not visible to the blocked user.