diff options
author | Stephen Beaver <sbeaver@netgate.com> | 2016-03-18 12:29:53 -0400 |
---|---|---|
committer | Stephen Beaver <sbeaver@netgate.com> | 2016-03-18 12:30:25 -0400 |
commit | cee365e65979d4602ec161066ed177449485fab0 (patch) | |
tree | f7d90d1307a425db038656fe61850ebbac79323a | |
parent | 7468ce30d455248c848cc1ef3f7c0a69009a258f (diff) | |
download | pfsense-cee365e65979d4602ec161066ed177449485fab0.zip pfsense-cee365e65979d4602ec161066ed177449485fab0.tar.gz |
Suppress dashboard save icon until needed.
-rw-r--r-- | src/usr/local/www/head.inc | 3 | ||||
-rw-r--r-- | src/usr/local/www/index.php | 12 |
2 files changed, 11 insertions, 4 deletions
diff --git a/src/usr/local/www/head.inc b/src/usr/local/www/head.inc index 3d7a159..badc788 100644 --- a/src/usr/local/www/head.inc +++ b/src/usr/local/www/head.inc @@ -509,8 +509,7 @@ if (($pagename === "index.php") && ($numColumns > 2)) { <?php if (isset($widgets)): ?> <li> - <!-- <a href="#" title="<?=gettext("Save dashboard layout")?>" id="btnstore" class="invisible"> --> - <a href="#" title="<?=gettext("Save dashboard layout")?>" id="btnstore"> + <a href="#" title="<?=gettext("Save dashboard layout")?>" id="btnstore" class="invisible"> <i class="fa fa-save icon-pointer"></i> </a> </li> diff --git a/src/usr/local/www/index.php b/src/usr/local/www/index.php index bb064af..31fd1ff 100644 --- a/src/usr/local/www/index.php +++ b/src/usr/local/www/index.php @@ -389,7 +389,7 @@ foreach ($widgets as $widgetname => $widgetconfig) { $columnWidth = 12 / $numColumns; for ($currentColumnNumber = 1; $currentColumnNumber <= $numColumns; $currentColumnNumber++) { - + //if col$currentColumnNumber exists if (isset($widgetColumns['col'.$currentColumnNumber])) { @@ -434,7 +434,7 @@ foreach ($widgets as $widgetname => $widgetconfig) { } else { echo '<div class="col-md-' . $columnWidth . '" id="widgets-col' . $currentColumnNumber . '"></div>'; } - + } ?> @@ -515,6 +515,14 @@ events.push(function() { return undefined; } }); + + // Show the fa-save icon in the breadcrumb bar if the user opens or closes a panel (In case he/she wants to save the new state) + // (Sometimes this will cause us to see the icon when we don't need it, but better that than the other way round) + $('.panel').on('hidden.bs.collapse shown.bs.collapse', function (e) { + if (e.currentTarget.id != 'widget-available') { + $('#btnstore').removeClass("invisible"); + } + }); }); //]]> </script> |