From f3008cb175ee5de5e2a186985b2ede4b183f13a2 Mon Sep 17 00:00:00 2001 From: Peter Piela Date: Sat, 19 Mar 2016 09:39:11 -0400 Subject: [PATCH] Add support for magic-search-bar Change-Id: Ibf4dc019c85210dd87f63222aa16d5f37a182922 --- .../ironic/node-list/node-list.controller.js | 39 +++++++++++++++++++ .../admin/ironic/node-list/node-list.html | 7 ++++ 2 files changed, 46 insertions(+) diff --git a/ironic_ui/static/dashboard/admin/ironic/node-list/node-list.controller.js b/ironic_ui/static/dashboard/admin/ironic/node-list/node-list.controller.js index 41b40e8e..79a1f3fa 100755 --- a/ironic_ui/static/dashboard/admin/ironic/node-list/node-list.controller.js +++ b/ironic_ui/static/dashboard/admin/ironic/node-list/node-list.controller.js @@ -1,5 +1,6 @@ /* * © Copyright 2016 Hewlett Packard Enterprise Development Company LP + * Copyright 2016 Cray Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -35,6 +36,43 @@ ctrl.basePath = basePath; ctrl.actions = actions; + /** + * Filtering - client-side MagicSearch + * all facets for node table + */ + ctrl.nodeFacets = [ + { + 'label': gettext('Name'), + 'name': 'name', + 'singleton': true + }, + { + 'label': gettext('UUID'), + 'name': 'uuid', + 'singleton': true + }, + { + 'label': gettext('Power State'), + 'name': 'power_state', + 'singleton': true + }, + { + 'label': gettext('Provisioning State'), + 'name': 'provision_state', + 'singleton': true + }, + { + 'label': gettext('Maintenance'), + 'name': 'maintenance', + 'singleton': true + }, + { + 'label': gettext('Driver'), + 'name': 'driver', + 'singleton': true + } + ]; + init(); // RETRIVE NODES AND PORTS @@ -65,3 +103,4 @@ } })(); + diff --git a/ironic_ui/static/dashboard/admin/ironic/node-list/node-list.html b/ironic_ui/static/dashboard/admin/ironic/node-list/node-list.html index 965cda4e..cad6b6af 100755 --- a/ironic_ui/static/dashboard/admin/ironic/node-list/node-list.html +++ b/ironic_ui/static/dashboard/admin/ironic/node-list/node-list.html @@ -7,6 +7,13 @@ class="table table-striped table-rsp table-detail"> + + + + + +