From c1dcaacda95e6f89ab97b61f59bf2ff2605de58c Mon Sep 17 00:00:00 2001 From: Shu Muto Date: Mon, 26 Dec 2016 13:11:16 +0900 Subject: [PATCH] Set reasonable name to browser title bar Currently, when using anuglar table, the name of title bar on browser is always "Horizon - OpenStack Dashboard". It's not good at point of view of usability. This patch fix it. Change-Id: I73c5077058d4214b20116577759ea2d5b96742cc Closes-Bug: #1647855 --- magnum_ui/content/cluster_templates/urls.py | 7 +++++-- magnum_ui/content/clusters/urls.py | 7 +++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/magnum_ui/content/cluster_templates/urls.py b/magnum_ui/content/cluster_templates/urls.py index 433e834e..389d1fc9 100644 --- a/magnum_ui/content/cluster_templates/urls.py +++ b/magnum_ui/content/cluster_templates/urls.py @@ -13,10 +13,13 @@ # under the License. from django.conf.urls import url +from django.utils.translation import ugettext_lazy as _ from horizon.browsers import views +title = _("Container Infra - Cluster Templates") urlpatterns = [ - url(r'^[0-9a-f\-]{36}$', views.AngularIndexView.as_view(), name='detail'), - url(r'^$', views.AngularIndexView.as_view(), name='index'), + url(r'^[0-9a-f\-]{36}$', views.AngularIndexView.as_view(title=title), + name='detail'), + url(r'^$', views.AngularIndexView.as_view(title=title), name='index'), ] diff --git a/magnum_ui/content/clusters/urls.py b/magnum_ui/content/clusters/urls.py index 433e834e..b48178d0 100644 --- a/magnum_ui/content/clusters/urls.py +++ b/magnum_ui/content/clusters/urls.py @@ -13,10 +13,13 @@ # under the License. from django.conf.urls import url +from django.utils.translation import ugettext_lazy as _ from horizon.browsers import views +title = _("Container Infra - Clusters") urlpatterns = [ - url(r'^[0-9a-f\-]{36}$', views.AngularIndexView.as_view(), name='detail'), - url(r'^$', views.AngularIndexView.as_view(), name='index'), + url(r'^[0-9a-f\-]{36}$', views.AngularIndexView.as_view(title=title), + name='detail'), + url(r'^$', views.AngularIndexView.as_view(title=title), name='index'), ]