diff options
| author | Feist, James <james.feist@intel.com> | 2017-08-22 13:07:42 -0700 |
|---|---|---|
| committer | Feist, James <james.feist@intel.com> | 2017-08-22 16:39:37 -0700 |
| commit | 694015b374a4fd498423b2845de6e292d9c766b4 (patch) | |
| tree | 19dae87df552c3d8c3281ceb003e4c2f50cb9f19 /static | |
| parent | ef915c26b0235afa181529cecd4cb080f15cb137 (diff) | |
| download | bmcweb-694015b374a4fd498423b2845de6e292d9c766b4.tar.gz bmcweb-694015b374a4fd498423b2845de6e292d9c766b4.zip | |
Add System Configuration Page
Parses json file and writes entites to page.
Change-Id: I486070deb48e0b447c904542148dbc3721f1facf
Diffstat (limited to 'static')
| -rw-r--r-- | static/CMakeLists.txt | 2 | ||||
| -rw-r--r-- | static/index.html | 3 | ||||
| -rw-r--r-- | static/js/bmcApp.js | 3 | ||||
| -rw-r--r-- | static/js/systemConfigController.js | 11 | ||||
| -rw-r--r-- | static/partial-systemconfig.html | 28 |
5 files changed, 46 insertions, 1 deletions
diff --git a/static/CMakeLists.txt b/static/CMakeLists.txt index a99abc7..b9137dd 100644 --- a/static/CMakeLists.txt +++ b/static/CMakeLists.txt @@ -20,6 +20,7 @@ set(JAVASCRIPT_ASSETS js/angular.js js/angular-ui-router-uib-modal.js js/smart-table.js + js/systemConfigController.js noVNC/core/inflator.js noVNC/core/input/xtscancodes.js @@ -60,6 +61,7 @@ set(HTML_ASSETS partial-systeminfo.html partial-fwupdate.html partial-fwupdateconfirm.html + partial-systemconfig.html ) set(OTHER_ASSETS diff --git a/static/index.html b/static/index.html index c2b5c98..e0a2058 100644 --- a/static/index.html +++ b/static/index.html @@ -37,7 +37,7 @@ <script type="text/javascript" src="static/js/ipmiController.js" defer></script> <script type="text/javascript" src="static/js/sensorController.js" defer></script> <script type="text/javascript" src="static/js/fwupdateController.js" defer></script> - + <script type="text/javascript" src="static/js/systemConfigController.js" defer></script> <script type="text/javascript" src="static/noVNC/core/util.js" defer></script> <script type="text/javascript" src="static/noVNC/app/webutil.js" defer></script> @@ -137,6 +137,7 @@ <li><a href="#">SOL</a></li> <li><a href="#">SDR Configuration</a></li> <li><a ui-sref="fwupdate">Firmware Update</a></li> + <li><a ui-sref="systemconfig">System Configuration</a></li> </ul> </li> <li class="dropdown" uib-dropdown dropdown-append-to-body> diff --git a/static/js/bmcApp.js b/static/js/bmcApp.js index 1812261..fb641ab 100644 --- a/static/js/bmcApp.js +++ b/static/js/bmcApp.js @@ -128,6 +128,9 @@ app.config([ .state('sensor', {url : '/sensor', templateUrl : 'static/partial-sensor.html'}) + .state('systemconfig', + {url: '/systemconfig', templateUrl : 'static/partial-systemconfig.html'}) + .state( 'fwupdate', {url : '/fwupdate', templateUrl : 'static/partial-fwupdate.html'}) diff --git a/static/js/systemConfigController.js b/static/js/systemConfigController.js new file mode 100644 index 0000000..d32f6ce --- /dev/null +++ b/static/js/systemConfigController.js @@ -0,0 +1,11 @@ +angular.module('bmcApp') + .controller( + 'systemConfigController', [ + '$scope', '$http', + function($scope, $http) { + $http.get('/intel/system_config').then(function(response) { + $scope.configuration = response.data; + }); + } + ] + ); diff --git a/static/partial-systemconfig.html b/static/partial-systemconfig.html new file mode 100644 index 0000000..a6b48d3 --- /dev/null +++ b/static/partial-systemconfig.html @@ -0,0 +1,28 @@ +<div class="container" ng-controller="systemConfigController"> + <div class="row"> + <div class="col-md-12"> + <div class="box box-primary"> + <div class="box-header with-border"> + <h4>System Configuration + </h4> + <div class="horizontal-scroll box-body"> </div> + + <table class="table table-striped system-status-table" st-table="smartTableData"> + <thead> + <tr class="sortable "> + <th class="table-id" st-sort="id" st-sort-default="true">#</th> + <th st-sort="name">Name</th> + </tr> + </thead> + <tbody> + <tr ng-repeat="(key, item) in configuration"> + <td class="table-id">{{$index}}</td> + <td>{{item.name}}</td> + </tr> + </tbody> + </table> + </div> + </div> + </div> + </div> +</div> |

