Remove unused app/constants/ dir
All the constants are defined here:
https://github.com/openbmc/phosphor-webui/blob/master/app/common/services/constants.js
Constants are injected as part of app.common.services.
This environment-constants.js or environment-constants.json could
be repurposed to configure features but going with something else,
https://gerrit.openbmc-project.xyz/#/c/11311/.
Tested: Quick manual regression test on the pages.
Change-Id: I59ba4f47fe8a927cb5f68a2657dfea9c61cd5f28
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
diff --git a/app/configuration/index.js b/app/configuration/index.js
index abe0190..1ac4162 100644
--- a/app/configuration/index.js
+++ b/app/configuration/index.js
@@ -9,9 +9,7 @@
'use strict';
angular
- .module(
- 'app.configuration',
- ['ngRoute', 'app.constants', 'app.common.services'])
+ .module('app.configuration', ['ngRoute', 'app.common.services'])
// Route configuration
.config([
'$routeProvider',
diff --git a/app/constants/environment-constants.js b/app/constants/environment-constants.js
deleted file mode 100644
index 26986fc..0000000
--- a/app/constants/environment-constants.js
+++ /dev/null
@@ -1,26 +0,0 @@
-/**
- * A module with constants for the REST API
- *
- * @module app/constants
- * @exports app/constants
- *
- */
-
-window.angular && (function(angular) {
- 'use strict';
-
- angular.module('app.constants').constant('EnvironmentConstants', {
- 'inDevelopmentMode': true,
- 'RestConstants': {},
- FLASH_MESSAGE: {
- duration: 2000,
- classes: {
- warning: 'message-warning',
- info: 'message-info',
- error: 'message-error',
- success: 'message-success'
- }
- }
- });
-
-})(window.angular);
diff --git a/app/constants/index.js b/app/constants/index.js
deleted file mode 100644
index cc46665..0000000
--- a/app/constants/index.js
+++ /dev/null
@@ -1,13 +0,0 @@
-/**
- * A module with constants for the application
- *
- * @module app/constants/index
- * @exports app/constants/index
- */
-
-window.angular && (function(angular) {
- 'use strict';
-
- angular.module('app.constants', []).constant('AppConstants', {});
-
-})(window.angular);
diff --git a/app/index.js b/app/index.js
index f9f3051..7154c0b 100644
--- a/app/index.js
+++ b/app/index.js
@@ -27,9 +27,6 @@
// TODO(Ed) clean this up, add the appropriate imports to phosphor-webui
-import constants_index from './constants/index.js';
-import environment_constants from './constants/environment-constants.js';
-
import services_index from './common/services/index.js';
import constants from './common/services/constants.js';
import dataService from './common/services/dataService.js';
@@ -102,9 +99,8 @@
'ngRoute', 'angular-clipboard',
'angularUtils.directives.dirPagination',
// Basic resources
- 'app.constants', 'app.templates', 'app.vendors',
- 'app.common.services', 'app.common.directives',
- 'app.common.filters',
+ 'app.templates', 'app.vendors', 'app.common.services',
+ 'app.common.directives', 'app.common.filters',
// Model resources
'app.login', 'app.overview', 'app.serverControl',
'app.serverHealth', 'app.configuration', 'app.users',
diff --git a/app/login/index.js b/app/login/index.js
index 9ec06bf..fcafc7c 100644
--- a/app/login/index.js
+++ b/app/login/index.js
@@ -9,7 +9,7 @@
'use strict';
angular
- .module('app.login', ['ngRoute', 'app.constants', 'app.common.services'])
+ .module('app.login', ['ngRoute', 'app.common.services'])
// Route configuration
.config([
'$routeProvider',
diff --git a/app/multi-server/index.js b/app/multi-server/index.js
index b96ebb5..2cae8f5 100644
--- a/app/multi-server/index.js
+++ b/app/multi-server/index.js
@@ -9,9 +9,7 @@
'use strict';
angular
- .module(
- 'app.multiServer',
- ['ngRoute', 'app.constants', 'app.common.services'])
+ .module('app.multiServer', ['ngRoute', 'app.common.services'])
// Route configuration
.config([
'$routeProvider',
diff --git a/app/overview/index.js b/app/overview/index.js
index 81c357d..2622710 100644
--- a/app/overview/index.js
+++ b/app/overview/index.js
@@ -9,8 +9,7 @@
'use strict';
angular
- .module(
- 'app.overview', ['ngRoute', 'app.constants', 'app.common.services'])
+ .module('app.overview', ['ngRoute', 'app.common.services'])
// Route configuration
.config([
'$routeProvider',
diff --git a/app/server-control/index.js b/app/server-control/index.js
index 797f144..0b0fa93 100644
--- a/app/server-control/index.js
+++ b/app/server-control/index.js
@@ -9,9 +9,7 @@
'use strict';
angular
- .module(
- 'app.serverControl',
- ['ngRoute', 'app.constants', 'app.common.services'])
+ .module('app.serverControl', ['ngRoute', 'app.common.services'])
// Route configuration
.config([
'$routeProvider',
diff --git a/app/server-health/index.js b/app/server-health/index.js
index c5bdd28..554bc00 100644
--- a/app/server-health/index.js
+++ b/app/server-health/index.js
@@ -9,9 +9,7 @@
'use strict';
angular
- .module(
- 'app.serverHealth',
- ['ngRoute', 'app.constants', 'app.common.services'])
+ .module('app.serverHealth', ['ngRoute', 'app.common.services'])
// Route configuration
.config([
'$routeProvider',
diff --git a/app/users/index.js b/app/users/index.js
index 695c294..1972c4c 100644
--- a/app/users/index.js
+++ b/app/users/index.js
@@ -9,7 +9,7 @@
'use strict';
angular
- .module('app.users', ['ngRoute', 'app.constants', 'app.common.services'])
+ .module('app.users', ['ngRoute', 'app.common.services'])
// Route configuration
.config([
'$routeProvider',