There are some JavaScript "onclicks" in header.inc which could be safely moved to staff-global.js since both are global.
Created attachment 14706 [details] [review] Bug 9424 - Move JavaScript out of header include This patch removes JavaScript "onlick" attributes from header.inc and moves the functionality to staff-global.js. This is in keeping with the idea of progressive enhancement. This patch also makes a couple of minor changes to staff-global.js to fix jsHint warnings. To test, be sure to clear your browser cache after applying the patch. Test the logout link under several conditions: - intranetbookbag enabled, virtualshelves enabled - intranetbookbag enabled, virtualshelves disabled - intranetbookbag disabled, virtualshelves enabled - intranetbookbag disabled, virtualshelves disabled Logout should be successful with no JavaScript errors. This array of tests is required because of the Cart-clearing action of logging out and the changes made in this patch to the way Car/Lists JavaScript is included.
Patch doesn't apply to master -- please rebase.
Created attachment 15101 [details] [review] Bug 9424 - Move JavaScript out of header include This patch removes JavaScript "onlick" attributes from header.inc and moves the functionality to staff-global.js. This is in keeping with the idea of progressive enhancement. This patch also makes a couple of minor changes to staff-global.js to fix jsHint warnings. To test, be sure to clear your browser cache after applying the patch. Test the logout link under several conditions: - intranetbookbag enabled, virtualshelves enabled - intranetbookbag enabled, virtualshelves disabled - intranetbookbag disabled, virtualshelves enabled - intranetbookbag disabled, virtualshelves disabled Logout should be successful with no JavaScript errors. This array of tests is required because of the Cart-clearing action of logging out and the changes made in this patch to the way Car/Lists JavaScript is included.
Created attachment 15191 [details] [review] Bug 9424 - Move JavaScript out of header include This patch removes JavaScript "onlick" attributes from header.inc and moves the functionality to staff-global.js. This is in keeping with the idea of progressive enhancement. This patch also makes a couple of minor changes to staff-global.js to fix jsHint warnings. To test, be sure to clear your browser cache after applying the patch. Test the logout link under several conditions: - intranetbookbag enabled, virtualshelves enabled - intranetbookbag enabled, virtualshelves disabled - intranetbookbag disabled, virtualshelves enabled - intranetbookbag disabled, virtualshelves disabled Logout should be successful with no JavaScript errors. This array of tests is required because of the Cart-clearing action of logging out and the changes made in this patch to the way Car/Lists JavaScript is included. Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This patch does not apply, could you rebase it please?
Created attachment 18062 [details] [review] Bug 9424 [Revised] Move JavaScript out of header include This patch removes JavaScript "onlick" attributes from header.inc and moves the functionality to staff-global.js. This is in keeping with the idea of progressive enhancement. To test, be sure to clear your browser cache after applying the patch. - Test the help link. - Test the logout link with the intranetbookbag preference on and off. - Open a patron's account and click "search to hold." Log out, and log in again. Koha should not remember the patron you chose before logging out (as seen from a search results page). Revised for current master.
Created attachment 18358 [details] [review] Bug 9424 [Revised] Move JavaScript out of header include This patch removes JavaScript "onlick" attributes from header.inc and moves the functionality to staff-global.js. This is in keeping with the idea of progressive enhancement. To test, be sure to clear your browser cache after applying the patch. - Test the help link. - Test the logout link with the intranetbookbag preference on and off. - Open a patron's account and click "search to hold." Log out, and log in again. Koha should not remember the patron you chose before logging out (as seen from a search results page). Revised for current master.
Created attachment 18391 [details] [review] Bug 9424: Move JavaScript out of header include This patch removes JavaScript "onlick" attributes from header.inc and moves the functionality to staff-global.js. This is in keeping with the idea of progressive enhancement. To test, be sure to clear your browser cache after applying the patch. - Test the help link. - Test the logout link with the intranetbookbag preference on and off. - Open a patron's account and click "search to hold." Log out, and log in again. Koha should not remember the patron you chose before logging out (as seen from a search results page). Signed-off-by: Galen Charlton <gmc@esilibrary.com>
QA comment: The 3 links do the same job as before, no regression found. Marked as Passed QA.
Created attachment 18408 [details] [review] Bug 9424: Move JavaScript out of header include This patch removes JavaScript "onlick" attributes from header.inc and moves the functionality to staff-global.js. This is in keeping with the idea of progressive enhancement. To test, be sure to clear your browser cache after applying the patch. - Test the help link. - Test the logout link with the intranetbookbag preference on and off. - Open a patron's account and click "search to hold." Log out, and log in again. Koha should not remember the patron you chose before logging out (as seen from a search results page). Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Pushed to master. Thanks, Owen!