Browse Source

Remove neutron-lbaas checks and rename "slug"

This patch removes the dependency on neutron-lbaas being enabled in neutron
and it renames the "slug" from ngloadbalancersv2 to load_balancer.  These
changes should allow co-installation of the neutron-lbaas-dashboard with
octavia-dashboard (however, they will both show up as "Load Balancers" in the
menu).

Change-Id: I4b02f67ba10e6339316fd17fcaf522f7339993ca
changes/42/497642/1
Michael Johnson 5 years ago
parent
commit
8eae426c16
  1. 2
      README.rst
  2. 2
      devstack/settings
  3. 0
      octavia_dashboard/dashboards/project/load_balancer/__init__.py
  4. 19
      octavia_dashboard/dashboards/project/load_balancer/panel.py
  5. 0
      octavia_dashboard/dashboards/project/load_balancer/templates/load_balancer/index.html
  6. 2
      octavia_dashboard/dashboards/project/load_balancer/urls.py
  7. 2
      octavia_dashboard/dashboards/project/load_balancer/views.py
  8. 4
      octavia_dashboard/enabled/_1482_project_load_balancer_panel.py
  9. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/actions/create/create.action.service.js
  10. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/actions/create/create.action.service.spec.js
  11. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/actions/delete/delete.action.service.js
  12. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/actions/delete/delete.action.service.spec.js
  13. 10
      octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/detail.html
  14. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/lbaasv2.module.js
  15. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/lbaasv2.module.spec.js
  16. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/listeners/actions/batch-actions.service.js
  17. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/listeners/actions/batch-actions.service.spec.js
  18. 4
      octavia_dashboard/static/dashboard/project/lbaasv2/listeners/actions/delete/delete.action.service.js
  19. 6
      octavia_dashboard/static/dashboard/project/lbaasv2/listeners/actions/delete/delete.action.service.spec.js
  20. 8
      octavia_dashboard/static/dashboard/project/lbaasv2/listeners/detail.html
  21. 4
      octavia_dashboard/static/dashboard/project/lbaasv2/listeners/table.html
  22. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/actions/batch-actions.service.js
  23. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/actions/batch-actions.service.spec.js
  24. 4
      octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/actions/delete/delete.action.service.js
  25. 6
      octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/actions/delete/delete.action.service.spec.js
  26. 4
      octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/detail.html
  27. 4
      octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/table.html
  28. 8
      octavia_dashboard/static/dashboard/project/lbaasv2/members/detail.html
  29. 4
      octavia_dashboard/static/dashboard/project/lbaasv2/members/table.html
  30. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/pools/actions/create/create.action.service.js
  31. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/pools/actions/create/create.action.service.spec.js
  32. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/pools/actions/delete/delete.action.service.js
  33. 2
      octavia_dashboard/static/dashboard/project/lbaasv2/pools/actions/delete/delete.action.service.spec.js
  34. 10
      octavia_dashboard/static/dashboard/project/lbaasv2/pools/detail.html

2
README.rst

@ -35,7 +35,7 @@ Howto
install on the horizon machine or within horizon's python virtual
environment.
2. Copy ``_1481_project_ng_loadbalancersv2_panel.py`` in
2. Copy ``_1482_project_load_balancer_panel.py`` in
``octavia_dashboard/enabled`` directory
to ``openstack_dashboard/local/enabled``.

2
devstack/settings

@ -1,5 +1,5 @@
OCTAVIA_DASHBOARD_DIR=$DEST/octavia-dashboard
OCTAVIA_DASHBOARD_ENABLE_FILE_NAME=_1481_project_ng_loadbalancersv2_panel.py
OCTAVIA_DASHBOARD_ENABLE_FILE_NAME=_1482_project_load_balancer_panel.py
OCTAVIA_DASHBOARD_ENABLE_FILE_PATH=$OCTAVIA_DASHBOARD_DIR/octavia_dashboard/enabled/$OCTAVIA_DASHBOARD_ENABLE_FILE_NAME

0
octavia_dashboard/dashboards/project/ngloadbalancersv2/__init__.py → octavia_dashboard/dashboards/project/load_balancer/__init__.py

19
octavia_dashboard/dashboards/project/ngloadbalancersv2/panel.py → octavia_dashboard/dashboards/project/load_balancer/panel.py

@ -18,27 +18,10 @@ from django.utils.translation import ugettext_lazy as _
import horizon
from openstack_dashboard.api import neutron
LOG = logging.getLogger(__name__)
class NGLoadBalancers(horizon.Panel):
name = _("Load Balancers")
slug = 'ngloadbalancersv2'
slug = 'load_balancer'
permissions = ('openstack.services.network',)
def allowed(self, context):
request = context['request']
try:
if not neutron.is_service_enabled(request,
config_name='enable_lb',
ext_name='lbaasv2'):
return False
except Exception:
LOG.error("Call to list enabled services failed. This is likely "
"due to a problem communicating with the Neutron "
"endpoint. Load Balancers v2 panel will not be "
"displayed")
return False
return super(NGLoadBalancers, self).allowed(context)

0
octavia_dashboard/dashboards/project/ngloadbalancersv2/templates/ngloadbalancersv2/index.html → octavia_dashboard/dashboards/project/load_balancer/templates/load_balancer/index.html

2
octavia_dashboard/dashboards/project/ngloadbalancersv2/urls.py → octavia_dashboard/dashboards/project/load_balancer/urls.py

@ -14,7 +14,7 @@
from django.conf.urls import url
from octavia_dashboard.dashboards.project.ngloadbalancersv2 import views
from octavia_dashboard.dashboards.project.load_balancer import views
urlpatterns = [

2
octavia_dashboard/dashboards/project/ngloadbalancersv2/views.py → octavia_dashboard/dashboards/project/load_balancer/views.py

@ -16,5 +16,5 @@ from horizon.views import HorizonTemplateView
class IndexView(HorizonTemplateView):
template_name = 'project/ngloadbalancersv2/index.html'
template_name = 'project/load_balancer/index.html'
page_title = 'Load Balancers'

4
octavia_dashboard/enabled/_1481_project_ng_loadbalancersv2_panel.py → octavia_dashboard/enabled/_1482_project_load_balancer_panel.py

@ -13,7 +13,7 @@
# limitations under the License.
# The slug of the panel to be added to HORIZON_CONFIG. Required.
PANEL = 'ngloadbalancersv2'
PANEL = 'load_balancer'
# The slug of the dashboard the PANEL is associated with. Required.
PANEL_DASHBOARD = 'project'
# The slug of the panel group the PANEL is associated with.
@ -21,7 +21,7 @@ PANEL_GROUP = 'network'
# Python panel class of the PANEL to be added.
ADD_PANEL = (
'octavia_dashboard.dashboards.project.ngloadbalancersv2.panel'
'octavia_dashboard.dashboards.project.load_balancer.panel'
'.NGLoadBalancers')
ADD_INSTALLED_APPS = ['octavia_dashboard']

2
octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/actions/create/create.action.service.js

@ -80,7 +80,7 @@
function onCreate(response) {
var healthMonitorId = response.data.id;
$location.path('project/ngloadbalancersv2/' + loadbalancerId + '/listeners/' +
$location.path('project/load_balancer/' + loadbalancerId + '/listeners/' +
listenerId + '/pools/' + poolId + '/healthmonitors/' + healthMonitorId);
}

2
octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/actions/create/create.action.service.spec.js

@ -98,7 +98,7 @@
init('loadbalancer1', 'listener1', loadBalancerState.promise).create.allowed({id: 'pool1'});
service.create.perform();
expect($location.path).toHaveBeenCalledWith(
'project/ngloadbalancersv2/loadbalancer1/listeners/listener1/pools/pool1/' +
'project/load_balancer/loadbalancer1/listeners/listener1/pools/pool1/' +
'healthmonitors/healthmonitor1');
});

2
octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/actions/delete/delete.action.service.js

@ -106,7 +106,7 @@
$route.reload();
} else {
// Success, go back to pool details page
var path = 'project/ngloadbalancersv2/' + loadbalancerId +
var path = 'project/load_balancer/' + loadbalancerId +
'/listeners/' + listenerId +
'/pools/' + poolId;
$location.path(path);

2
octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/actions/delete/delete.action.service.spec.js

@ -143,7 +143,7 @@
});
it('should return to pool details after delete', function() {
var path = 'project/ngloadbalancersv2/1/listeners/2/pools/3';
var path = 'project/load_balancer/1/listeners/2/pools/3';
spyOn($location, 'path');
spyOn(toast, 'add');
service.perform(monitor);

10
octavia_dashboard/static/dashboard/project/lbaasv2/healthmonitors/detail.html

@ -3,10 +3,10 @@
<div ng-if="!ctrl.loading && !ctrl.error">
<div class="page-header">
<ol class="breadcrumb">
<li><a href="project/ngloadbalancersv2/"><translate>Load Balancers</translate></a></li>
<li><a href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}">{$ ::(ctrl.loadbalancer.name || ctrl.loadbalancer.id) $}</a></li>
<li><a href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}">{$ ::(ctrl.listener.name || ctrl.listener.id) $}</a></li>
<li><a href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}/pools/{$ ::ctrl.pool.id $}">{$ ::(ctrl.pool.name || ctrl.pool.id) $}</a></li>
<li><a href="project/load_balancer/"><translate>Load Balancers</translate></a></li>
<li><a href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}">{$ ::(ctrl.loadbalancer.name || ctrl.loadbalancer.id) $}</a></li>
<li><a href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}">{$ ::(ctrl.listener.name || ctrl.listener.id) $}</a></li>
<li><a href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}/pools/{$ ::ctrl.pool.id $}">{$ ::(ctrl.pool.name || ctrl.pool.id) $}</a></li>
<li class="active">{$ ::(ctrl.healthmonitor.name || ctrl.healthmonitor.id) $}</li>
<actions allowed="ctrl.actions" type="row" item="ctrl.healthmonitor"
ng-if="ctrl.healthmonitor" class="actions_column pull-right"></actions>
@ -39,4 +39,4 @@
</div>
</div>
</div>
</div>
</div>

2
octavia_dashboard/static/dashboard/project/lbaasv2/lbaasv2.module.js

@ -57,7 +57,7 @@
var basePath = $windowProvider.$get().STATIC_URL + 'dashboard/project/lbaasv2/';
$provide.constant('horizon.dashboard.project.lbaasv2.basePath', basePath);
var loadbalancers = '/project/ngloadbalancersv2';
var loadbalancers = '/project/load_balancer';
var listener = loadbalancers + '/:loadbalancerId/listeners/:listenerId';
var pool = listener + '/pools/:poolId';
var member = pool + '/members/:memberId';

2
octavia_dashboard/static/dashboard/project/lbaasv2/lbaasv2.module.spec.js

@ -105,7 +105,7 @@
});
it('should route URLs', function () {
var loadbalancers = '/project/ngloadbalancersv2';
var loadbalancers = '/project/load_balancer';
var listener = loadbalancers + '/:loadbalancerId/listeners/:listenerId';
var pool = listener + '/pools/:poolId';
var member = pool + '/members/:memberId';

2
octavia_dashboard/static/dashboard/project/lbaasv2/listeners/actions/batch-actions.service.js

@ -100,7 +100,7 @@
function onCreate(response) {
var id = response.data.id;
$location.path('project/ngloadbalancersv2/' + loadBalancerId + '/listeners/' + id);
$location.path('project/load_balancer/' + loadBalancerId + '/listeners/' + id);
}
}

2
octavia_dashboard/static/dashboard/project/lbaasv2/listeners/actions/batch-actions.service.spec.js

@ -98,7 +98,7 @@
it('should redirect after create', function() {
spyOn($location, 'path').and.callThrough();
actions[0].service.perform();
expect($location.path).toHaveBeenCalledWith('project/ngloadbalancersv2/1234/listeners/5678');
expect($location.path).toHaveBeenCalledWith('project/load_balancer/1234/listeners/5678');
});
});

4
octavia_dashboard/static/dashboard/project/lbaasv2/listeners/actions/delete/delete.action.service.js

@ -115,11 +115,11 @@
} else {
// If the user is on the listeners table then just reload the page, otherwise they
// are on the details page and we return to the table.
var regex = new RegExp('project\/ngloadbalancersv2\/' + loadbalancerId + '(\/)?$');
var regex = new RegExp('project\/load_balancer\/' + loadbalancerId + '(\/)?$');
if (regex.test($location.path())) {
$route.reload();
} else {
$location.path('project/ngloadbalancersv2/' + loadbalancerId);
$location.path('project/load_balancer/' + loadbalancerId);
}
}
}

6
octavia_dashboard/static/dashboard/project/lbaasv2/listeners/actions/delete/delete.action.service.spec.js

@ -144,7 +144,7 @@
});
it('should reload table after delete', function() {
path = 'project/ngloadbalancersv2/1';
path = 'project/load_balancer/1';
spyOn($route, 'reload');
service.perform(items);
$scope.$apply();
@ -152,12 +152,12 @@
});
it('should return to table after delete if on detail page', function() {
path = 'project/ngloadbalancersv2/1/listeners/2';
path = 'project/load_balancer/1/listeners/2';
spyOn($location, 'path');
spyOn(toast, 'add');
service.perform(items[0]);
$scope.$apply();
expect($location.path).toHaveBeenCalledWith('project/ngloadbalancersv2/1');
expect($location.path).toHaveBeenCalledWith('project/load_balancer/1');
expect(toast.add).toHaveBeenCalledWith('success', 'Deleted listeners: First.');
});

8
octavia_dashboard/static/dashboard/project/lbaasv2/listeners/detail.html

@ -3,8 +3,8 @@
<div ng-if="!ctrl.loading && !ctrl.error">
<div class="page-header">
<ol class="breadcrumb">
<li><a href="project/ngloadbalancersv2/"><translate>Load Balancers</translate></a></li>
<li><a href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}">{$ ::(ctrl.loadbalancer.name || ctrl.loadbalancer.id) $}</a></li>
<li><a href="project/load_balancer/"><translate>Load Balancers</translate></a></li>
<li><a href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}">{$ ::(ctrl.loadbalancer.name || ctrl.loadbalancer.id) $}</a></li>
<li class="active">{$ ::(ctrl.listener.name || ctrl.listener.id) $}</li>
<actions allowed="ctrl.actions" type="row" item="ctrl.listener" ng-if="ctrl.listener"
class="actions_column pull-right"></actions>
@ -24,7 +24,7 @@
<dd>{$ ctrl.listener.admin_state_up | yesno $}</dd>
<dt translate>Default Pool ID</dt>
<dd>
<a ng-href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}/pools/{$ ::ctrl.listener.default_pool_id $}" ng-if="ctrl.listener.default_pool_id">
<a ng-href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}/pools/{$ ::ctrl.listener.default_pool_id $}" ng-if="ctrl.listener.default_pool_id">
{$ ::ctrl.listener.default_pool_id $}
</a>
<span ng-if="!ctrl.listener.default_pool_id">
@ -39,4 +39,4 @@
</div>
</div>
</div>
</div>
</div>

4
octavia_dashboard/static/dashboard/project/lbaasv2/listeners/table.html

@ -68,7 +68,7 @@
duration="200">
</span>
</td>
<td class="rsp-p1"><a ng-href="project/ngloadbalancersv2/{$ ::table.loadbalancerId $}/listeners/{$ ::item.id $}">{$ ::(item.name || item.id) $}</a></td>
<td class="rsp-p1"><a ng-href="project/load_balancer/{$ ::table.loadbalancerId $}/listeners/{$ ::item.id $}">{$ ::(item.name || item.id) $}</a></td>
<td class="rsp-p1">{$ ::item.description | noValue $}</td>
<td class="rsp-p1">{$ ::item.protocol$}</td>
<td class="rsp-p1">{$ ::item.protocol_port$}</td>
@ -121,4 +121,4 @@
-->
<tfoot hz-table-footer items="table.items"></tfoot>
</table>
</table>

2
octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/actions/batch-actions.service.js

@ -86,7 +86,7 @@
}
function onCreate(response) {
$location.path('project/ngloadbalancersv2/' + response.data.id);
$location.path('project/load_balancer/' + response.data.id);
}
}

2
octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/actions/batch-actions.service.spec.js

@ -76,7 +76,7 @@
it('should redirect after create', function() {
spyOn($location, 'path').and.callThrough();
actions[0].service.perform();
expect($location.path).toHaveBeenCalledWith('project/ngloadbalancersv2/1');
expect($location.path).toHaveBeenCalledWith('project/load_balancer/1');
});
});

4
octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/actions/delete/delete.action.service.js

@ -142,10 +142,10 @@
} else {
// If the user is on the load balancers table then just reload the page, otherwise they
// are on the details page and we return to the table.
if (/\/ngloadbalancersv2(\/)?$/.test($location.path())) {
if (/\/load_balancer(\/)?$/.test($location.path())) {
$route.reload();
} else {
$location.path('project/ngloadbalancersv2');
$location.path('project/load_balancer');
}
}
}

6
octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/actions/delete/delete.action.service.spec.js

@ -156,7 +156,7 @@
});
it('should reload table after delete', function() {
path = 'project/ngloadbalancersv2';
path = 'project/load_balancer';
spyOn($route, 'reload');
service.perform(items);
$scope.$apply();
@ -164,12 +164,12 @@
});
it('should return to table after delete if on detail page', function() {
path = 'project/ngloadbalancersv2/1';
path = 'project/load_balancer/1';
spyOn($location, 'path');
spyOn(toast, 'add');
service.perform(items[0]);
$scope.$apply();
expect($location.path).toHaveBeenCalledWith('project/ngloadbalancersv2');
expect($location.path).toHaveBeenCalledWith('project/load_balancer');
expect(toast.add).toHaveBeenCalledWith('success', 'Deleted load balancers: First.');
});

4
octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/detail.html

@ -3,7 +3,7 @@
<div ng-if="!ctrl.loading && !ctrl.error">
<div class="page-header">
<ol class="breadcrumb">
<li><a href="project/ngloadbalancersv2/"><translate>Load Balancers</translate></a></li>
<li><a href="project/load_balancer/"><translate>Load Balancers</translate></a></li>
<li class="active">{$ ctrl.loadbalancer.name || ctrl.loadbalancer.id $}</li>
<actions allowed="ctrl.actions" type="row" item="ctrl.loadbalancer"
ng-if="ctrl.loadbalancer" class="actions_column pull-right"></actions>
@ -54,4 +54,4 @@
</tab>
</tabset>
</div>
</div>
</div>

4
octavia_dashboard/static/dashboard/project/lbaasv2/loadbalancers/table.html

@ -72,7 +72,7 @@
duration="200">
</span>
</td>
<td class="rsp-p1"><a ng-href="project/ngloadbalancersv2/{$ ::item.id $}">{$ ::(item.name || item.id) $}</a></td>
<td class="rsp-p1"><a ng-href="project/load_balancer/{$ ::item.id $}">{$ ::(item.name || item.id) $}</a></td>
<td class="rsp-p1">{$ ::item.description | noValue $}</td>
<td class="rsp-p1">{$ ::item.operating_status | decode:table.operatingStatus $}</td>
<td class="rsp-p1">{$ ::item.provisioning_status | decode:table.provisioningStatus $}</td>
@ -152,4 +152,4 @@
-->
<tfoot hz-table-footer items="table.items"></tfoot>
</table>
</table>

8
octavia_dashboard/static/dashboard/project/lbaasv2/members/detail.html

@ -3,10 +3,10 @@
<div ng-if="!ctrl.loading && !ctrl.error">
<div class="page-header">
<ol class="breadcrumb">
<li><a href="project/ngloadbalancersv2/"><translate>Load Balancers</translate></a></li>
<li><a href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}">{$ ::(ctrl.loadbalancer.name || ctrl.loadbalancer.id) $}</a></li>
<li><a href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}">{$ ::(ctrl.listener.name || ctrl.listener.id) $}</a></li>
<li><a href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}/pools/{$ ::ctrl.pool.id $}">{$ ::(ctrl.pool.name || ctrl.pool.id) $}</a></li>
<li><a href="project/load_balancer/"><translate>Load Balancers</translate></a></li>
<li><a href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}">{$ ::(ctrl.loadbalancer.name || ctrl.loadbalancer.id) $}</a></li>
<li><a href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}">{$ ::(ctrl.listener.name || ctrl.listener.id) $}</a></li>
<li><a href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}/pools/{$ ::ctrl.pool.id $}">{$ ::(ctrl.pool.name || ctrl.pool.id) $}</a></li>
<li class="active">{$ ::(ctrl.member.name || ctrl.member.id) $}</li>
<actions allowed="ctrl.actions" type="row" item="ctrl.member"
ng-if="ctrl.member" class="actions_column pull-right"></actions>

4
octavia_dashboard/static/dashboard/project/lbaasv2/members/table.html

@ -62,7 +62,7 @@
ng-model="tCtrl.selections[item.id].checked"
hz-select="item">
</td>
<td class="rsp-p1"><a ng-href="project/ngloadbalancersv2/{$ ::table.loadbalancerId $}/listeners/{$ ::table.listenerId $}/pools/{$ ::table.poolId $}/members/{$ ::item.id $}">{$ ::item.id $}</a></td>
<td class="rsp-p1"><a ng-href="project/load_balancer/{$ ::table.loadbalancerId $}/listeners/{$ ::table.listenerId $}/pools/{$ ::table.poolId $}/members/{$ ::item.id $}">{$ ::item.id $}</a></td>
<td class="rsp-p1">{$ ::item.address $}</td>
<td class="rsp-p1">{$ ::item.protocol_port $}</td>
<td class="rsp-p1">{$ ::item.operating_status | decode:table.operatingStatus $}</td>
@ -86,4 +86,4 @@
-->
<tfoot hz-table-footer items="table.items"></tfoot>
</table>
</table>

2
octavia_dashboard/static/dashboard/project/lbaasv2/pools/actions/create/create.action.service.js

@ -81,7 +81,7 @@
function onCreate(response) {
var poolId = response.data.id;
$location.path('project/ngloadbalancersv2/' + loadbalancerId + '/listeners/' +
$location.path('project/load_balancer/' + loadbalancerId + '/listeners/' +
listenerId + '/pools/' + poolId);
}

2
octavia_dashboard/static/dashboard/project/lbaasv2/pools/actions/create/create.action.service.spec.js

@ -104,7 +104,7 @@
init('1234', defer.promise).create.allowed({id: '5678'});
createPoolService.create.perform();
expect($location.path).toHaveBeenCalledWith(
'project/ngloadbalancersv2/1234/listeners/5678/pools/9012');
'project/load_balancer/1234/listeners/5678/pools/9012');
});
});

2
octavia_dashboard/static/dashboard/project/lbaasv2/pools/actions/delete/delete.action.service.js

@ -103,7 +103,7 @@
$route.reload();
} else {
// Success, go back to listener details page
var path = 'project/ngloadbalancersv2/' + loadbalancerId + '/listeners/' + listenerId;
var path = 'project/load_balancer/' + loadbalancerId + '/listeners/' + listenerId;
$location.path(path);
}
}

2
octavia_dashboard/static/dashboard/project/lbaasv2/pools/actions/delete/delete.action.service.spec.js

@ -146,7 +146,7 @@
spyOn(toast, 'add');
service.perform(pool);
$scope.$apply();
expect($location.path).toHaveBeenCalledWith('project/ngloadbalancersv2/1/listeners/2');
expect($location.path).toHaveBeenCalledWith('project/load_balancer/1/listeners/2');
expect(toast.add).toHaveBeenCalledWith('success', 'Deleted pool: Pool1.');
});

10
octavia_dashboard/static/dashboard/project/lbaasv2/pools/detail.html

@ -3,9 +3,9 @@
<div ng-if="!ctrl.loading && !ctrl.error">
<div class="page-header">
<ol class="breadcrumb">
<li><a href="project/ngloadbalancersv2/"><translate>Load Balancers</translate></a></li>
<li><a href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}">{$ ::(ctrl.loadbalancer.name || ctrl.loadbalancer.id) $}</a></li>
<li><a href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}">{$ ::(ctrl.listener.name || ctrl.listener.id) $}</a></li>
<li><a href="project/load_balancer/"><translate>Load Balancers</translate></a></li>
<li><a href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}">{$ ::(ctrl.loadbalancer.name || ctrl.loadbalancer.id) $}</a></li>
<li><a href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}">{$ ::(ctrl.listener.name || ctrl.listener.id) $}</a></li>
<li class="active">{$ ::(ctrl.pool.name || ctrl.pool.id) $}</li>
<actions allowed="ctrl.actions" type="row" item="ctrl.pool"
ng-if="ctrl.pool" class="actions_column pull-right"></actions>
@ -27,7 +27,7 @@
<dd>{$ ctrl.pool.admin_state_up | yesno $}</dd>
<dt translate>Health Monitor ID</dt>
<dd>
<a ng-href="project/ngloadbalancersv2/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}/pools/{$ ::ctrl.pool.id $}/healthmonitors/{$ ::ctrl.pool.healthmonitor_id $}" ng-if="ctrl.pool.healthmonitor_id">
<a ng-href="project/load_balancer/{$ ::ctrl.loadbalancer.id $}/listeners/{$ ::ctrl.listener.id $}/pools/{$ ::ctrl.pool.id $}/healthmonitors/{$ ::ctrl.pool.healthmonitor_id $}" ng-if="ctrl.pool.healthmonitor_id">
{$ ::ctrl.pool.healthmonitor_id $}
</a>
<span ng-if="!ctrl.pool.healthmonitor_id">
@ -47,4 +47,4 @@
</tab>
</tabset>
</div>
</div>
</div>

Loading…
Cancel
Save