From 7eaded2a044cc6ac690cef81043e820cf5b55371 Mon Sep 17 00:00:00 2001 From: Shu Muto Date: Tue, 27 Jun 2017 18:13:52 +0900 Subject: [PATCH] Rename pool-flavors module '-' should not be used for python module name. https://www.python.org/dev/peps/pep-0008/#package-and-module-names Change-Id: Ia788a20180cac8e85002cfcd5cdacf7343578b5b --- zaqar_ui/content/{pool-flavors => pool_flavors}/__init__.py | 0 zaqar_ui/content/{pool-flavors => pool_flavors}/panel.py | 2 +- zaqar_ui/content/{pool-flavors => pool_flavors}/urls.py | 0 zaqar_ui/enabled/_2530_admin_pool_flavors.py | 4 ++-- .../dashboard/admin/pool-flavors/pool-flavors.module.js | 2 +- 5 files changed, 4 insertions(+), 4 deletions(-) rename zaqar_ui/content/{pool-flavors => pool_flavors}/__init__.py (100%) rename zaqar_ui/content/{pool-flavors => pool_flavors}/panel.py (96%) rename zaqar_ui/content/{pool-flavors => pool_flavors}/urls.py (100%) diff --git a/zaqar_ui/content/pool-flavors/__init__.py b/zaqar_ui/content/pool_flavors/__init__.py similarity index 100% rename from zaqar_ui/content/pool-flavors/__init__.py rename to zaqar_ui/content/pool_flavors/__init__.py diff --git a/zaqar_ui/content/pool-flavors/panel.py b/zaqar_ui/content/pool_flavors/panel.py similarity index 96% rename from zaqar_ui/content/pool-flavors/panel.py rename to zaqar_ui/content/pool_flavors/panel.py index d15e9f5..58dd421 100644 --- a/zaqar_ui/content/pool-flavors/panel.py +++ b/zaqar_ui/content/pool_flavors/panel.py @@ -19,4 +19,4 @@ import horizon class PoolFlavors(horizon.Panel): name = _("Pool Flavors") - slug = "pool-flavors" + slug = "pool_flavors" diff --git a/zaqar_ui/content/pool-flavors/urls.py b/zaqar_ui/content/pool_flavors/urls.py similarity index 100% rename from zaqar_ui/content/pool-flavors/urls.py rename to zaqar_ui/content/pool_flavors/urls.py diff --git a/zaqar_ui/enabled/_2530_admin_pool_flavors.py b/zaqar_ui/enabled/_2530_admin_pool_flavors.py index 2dd0c18..fd4e0d2 100644 --- a/zaqar_ui/enabled/_2530_admin_pool_flavors.py +++ b/zaqar_ui/enabled/_2530_admin_pool_flavors.py @@ -12,11 +12,11 @@ # See the License for the specific language governing permissions and # limitations under the License. -PANEL = 'pool-flavors' +PANEL = 'pool_flavors' PANEL_GROUP = 'messaging' PANEL_DASHBOARD = 'admin' -ADD_PANEL = ('zaqar_ui.content.pool-flavors.panel.PoolFlavors') +ADD_PANEL = ('zaqar_ui.content.pool_flavors.panel.PoolFlavors') ADD_ANGULAR_MODULES = ['horizon.dashboard.admin.pool-flavors'] ADD_SCSS_FILES = ['dashboard/admin/pool-flavors/pool-flavors.scss'] diff --git a/zaqar_ui/static/dashboard/admin/pool-flavors/pool-flavors.module.js b/zaqar_ui/static/dashboard/admin/pool-flavors/pool-flavors.module.js index 69f852b..64a15bf 100644 --- a/zaqar_ui/static/dashboard/admin/pool-flavors/pool-flavors.module.js +++ b/zaqar_ui/static/dashboard/admin/pool-flavors/pool-flavors.module.js @@ -94,7 +94,7 @@ var path = $windowProvider.$get().STATIC_URL + 'dashboard/admin/pool-flavors/'; $provide.constant('horizon.dashboard.admin.pool-flavors.basePath', path); - $routeProvider.when('/admin/pool-flavors', { + $routeProvider.when('/admin/pool_flavors', { templateUrl: path + 'panel.html' }); }