http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=5010
M. Tompsett <mtomp...@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #27049|0 |1 is obsolete| | --- Comment #30 from M. Tompsett <mtomp...@hotmail.com> --- Created attachment 27072 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=27072&action=edit Bug 5010: Fix incomplete links in carts and lists sent from the staff client While the list email hardcoded http:// in front of the URL, the cart email was missing http(s)://. As there seems to be no reliable way to determine in staff if the OPAC is using SSL or not, this patch introduces a new OPAC system preference, OpacProtocol, in the Policy subsection. It defaults to "doesn't use" (http://), but can be changed to "uses" (https://). Both basket/sendbasket.pl and virtualshelves/sendshelf.pl were tweaked to always set OPACBaseURL. If OPACBaseURL is undef or not set, the URL is not given in the corresponding template files. opac/opac-sendshelf.pl was returned to previous state, because it affects doc-head-close.inc if OPACBaseURL is not passed. This should be fixed to use the OpacProtocol system preference in another bug fix. However, this is OPAC, not Staff, and outside of the bugs scope. Both basket/sendbasket.tt and virtualshelves/sendshelf.tt template files contain the suggested Koha.Preference logic recommended by Kyle in comment #21. TEST PLAN --------- 1) Back up your database 2) Drop your koha database and recreate it empty 3) In the mysql client: > SOURCE .../installer/data/mysql/sysprefs.sql; -- It should run without error. > SELECT variable,value from systempreferences WHERE variable='OpacProtocol'; -- It should have the value 'http://' 4) Restore your database 5) $ ./installer/data/mysql/updatedatabase.pl -- It should run the upgrade to insert OpacProtocol. 6) In the mysql client: > SELECT variable,value from systempreferences WHERE variable='OpacProtocol'; -- It should have the value 'http://' 7) Log into the staff client 8) Click 'Koha administration' 9) Click 'Global system preferences' 10) Click the 'OPAC' tab on the left side. 11) Scroll down to the Policy section, and find the OpacProtocol preference. -- It should have a value of "doesn't use" in the drop down. 12) Fill your cart with something(s). 13) Make sure you have a list filled with something(s). 14) Click 'Cart' in the top menu bar area. 15) Click 'Send', and send it to yourself. 16) Click 'Close window' 17) Click 'Hide window' 18) Click 'More' and click 'Lists' 19) Choose a list and 'Send list' to yourself. 20) Check your email -- both emails should have OPAC URLs which start with http:// 21) Change the OPAC system preference OpacProtocol to 'uses' (https://), log out and log in (to force refresh of cached system preferences), and repeat steps 14 through 19. 22) Check your email -- the two new emails should have OPAC URLS which start with https:// NOTE: Other URLs may be broken as well, this bug only fixes carts and lists sent from staff. -- You are receiving this mail because: You are the QA Contact for the bug. You are watching all bug changes. _______________________________________________ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/