From 28650555320a7df2e92c8a3d64786e27b50b8354 Mon Sep 17 00:00:00 2001 From: Masco Kaliyamoorthy Date: Thu, 11 Jun 2015 14:49:39 +0530 Subject: [PATCH] LB method column is added in pools table In load balancer pools table load balancing method column missing. This patch adding the LB method column in pools table. Change-Id: I0465bd951d31f1bb3f47c8e8ddec18defc8b69e0 Closes-Bug: #1464181 --- .../dashboards/project/loadbalancers/tables.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/openstack_dashboard/dashboards/project/loadbalancers/tables.py b/openstack_dashboard/dashboards/project/loadbalancers/tables.py index 0b8e2ad74d..762adabe99 100644 --- a/openstack_dashboard/dashboards/project/loadbalancers/tables.py +++ b/openstack_dashboard/dashboards/project/loadbalancers/tables.py @@ -312,6 +312,15 @@ STATUS_DISPLAY_CHOICES = ( class PoolsTable(tables.DataTable): + METHOD_DISPLAY_CHOICES = ( + ("round_robin", pgettext_lazy("load balancing method", + u"Round Robin")), + ("least_connections", pgettext_lazy("load balancing method", + u"Least Connections")), + ("source_ip", pgettext_lazy("load balancing method", + u"Source IP")), + ) + name = tables.Column("name_or_id", verbose_name=_("Name"), link="horizon:project:loadbalancers:pooldetails") @@ -320,6 +329,9 @@ class PoolsTable(tables.DataTable): filters=(lambda v: filters.default(v, _('N/A')),)) subnet_name = tables.Column('subnet_name', verbose_name=_("Subnet")) protocol = tables.Column('protocol', verbose_name=_("Protocol")) + method = tables.Column('lb_method', + verbose_name=_("LB Method"), + display_choices=METHOD_DISPLAY_CHOICES) status = tables.Column('status', verbose_name=_("Status"), status=True,