[Koha-patches] [PATCH] [SIGNED-OFF] Fix for Bug 5532 - sysprefs editor should show names of saved prefs

Chris Nighswonger cnighswonger at foundations.edu
Fri Feb 4 00:53:15 CET 2011


From: Owen Leonard <oleonard at myacpl.org>

Signed-off-by: Chris Nighswonger <cnighswonger at foundations.edu>
---
 .../intranet-tmpl/prog/en/css/preferences.css      |    5 +++++
 .../intranet-tmpl/prog/en/js/pages/preferences.js  |   11 +++++++++--
 2 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/koha-tmpl/intranet-tmpl/prog/en/css/preferences.css b/koha-tmpl/intranet-tmpl/prog/en/css/preferences.css
index 095b007..d9fde24 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/css/preferences.css
+++ b/koha-tmpl/intranet-tmpl/prog/en/css/preferences.css
@@ -61,3 +61,8 @@ h3.collapsed {
 	cursor : pointer;
 	padding-left : 12px;
 }
+
+.humanMsg strong {
+	display: block;
+	font-weight: normal;
+}
\ No newline at end of file
diff --git a/koha-tmpl/intranet-tmpl/prog/en/js/pages/preferences.js b/koha-tmpl/intranet-tmpl/prog/en/js/pages/preferences.js
index cbf98b8..06990b1 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/js/pages/preferences.js
+++ b/koha-tmpl/intranet-tmpl/prog/en/js/pages/preferences.js
@@ -9,7 +9,8 @@ $(document).ready(function() {
 
 KOHA.Preferences = {
     Save: function ( form ) {
-        data = $( form ).find( '.modified' ).serialize();
+        modified_prefs = $( form ).find( '.modified' );
+        data = modified_prefs.serialize();
         if ( !data ) {
             humanMsg.displayAlert( 'Nothing to save' );
             return;
@@ -23,7 +24,13 @@ KOHA.Preferences = {
         } );
     },
     Success: function ( form ) {
-        humanMsg.displayAlert( 'Saved' );
+        var msg = "";
+        modified_prefs.each(function(){
+            var modified_pref = $(this).attr("id");
+            modified_pref = modified_pref.replace("pref_","");
+            msg += '<strong>Saved preference '+modified_pref+'</strong>\n';
+        });
+        humanMsg.displayAlert(msg);
 
         $( form )
             .find( '.modified-warning' ).remove().end()
-- 
1.7.0.4



More information about the Koha-patches mailing list