From: Thomas Berezansky Date: Mon, 15 Aug 2011 12:59:31 +0000 (-0400) Subject: Require permission or pref to debug in client X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=23fc0a16286766b76605822391feae6484511580;p=evergreen%2Ftadl.git Require permission or pref to debug in client Disables all debug functions I know of unless: 1 - You have new DEBUG_CLIENT permission (after login) This should work even on operator change. Once a given debug interface is open you can change operator back. 2 - You have a client with the debug preference enabled This causes the client in all places I touched to think you have DEBUG_CLIENT This also allows debugging *before* login, including in the Standalone interface. Debug functions I know of: Debug box on login page (already protected by pref) Debug items in Admin menu Venkman Javascript Shells Inspector Chrome List CTRL+SHIFT+F7 debug box in overlays Signed-off-by: Thomas Berezansky Signed-off-by: Jason Etheridge --- diff --git a/Open-ILS/src/sql/Pg/950.data.seed-values.sql b/Open-ILS/src/sql/Pg/950.data.seed-values.sql index 3751ba44aa..43c3892a0f 100644 --- a/Open-ILS/src/sql/Pg/950.data.seed-values.sql +++ b/Open-ILS/src/sql/Pg/950.data.seed-values.sql @@ -1431,7 +1431,9 @@ INSERT INTO permission.perm_list ( id, code, description ) VALUES ( 510, 'UPDATE_PATRON_COLLECTIONS_EXEMPT', oils_i18n_gettext(510, 'Allows a user to indicate that a patron is exempt from collections processing', 'ppl', 'description')), ( 512, 'ACQ_INVOICE_REOPEN', oils_i18n_gettext( 512, - 'Allows a user to reopen an Acquisitions invoice', 'ppl', 'description' )); + 'Allows a user to reopen an Acquisitions invoice', 'ppl', 'description' )), + ( 513, 'DEBUG_CLIENT', oils_i18n_gettext( 513, + 'Allows a user to use debug functions in the staff client', 'ppl', 'description' )); SELECT SETVAL('permission.perm_list_id_seq'::TEXT, 1000); diff --git a/Open-ILS/xul/staff_client/chrome/content/OpenILS/util_overlay_chrome.xul b/Open-ILS/xul/staff_client/chrome/content/OpenILS/util_overlay_chrome.xul index c635ab34ca..b0085d03a3 100644 --- a/Open-ILS/xul/staff_client/chrome/content/OpenILS/util_overlay_chrome.xul +++ b/Open-ILS/xul/staff_client/chrome/content/OpenILS/util_overlay_chrome.xul @@ -68,7 +68,7 @@