Merge "Sort security group rules by protocol and port" into stable/icehouse
This commit is contained in:
commit
18a47ba1a9
|
@ -58,7 +58,8 @@ class DetailView(tables.DataTableView):
|
|||
data = self._get_data()
|
||||
if data is None:
|
||||
return []
|
||||
return data.rules
|
||||
return sorted(data.rules, key=lambda rule: (rule.ip_protocol,
|
||||
rule.from_port))
|
||||
|
||||
def get_context_data(self, **kwargs):
|
||||
context = super(DetailView, self).get_context_data(**kwargs)
|
||||
|
|
Loading…
Reference in New Issue