Bug 22880: (follow-up) Loose ends: Better DB update, global inclusion, etc.
authorOwen Leonard <oleonard@myacpl.org>
Wed, 11 Dec 2019 13:42:09 +0000 (13:42 +0000)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Mon, 24 Feb 2020 13:24:25 +0000 (13:24 +0000)
commit12074faff9686f6c25126e39fcf1954e5faba009
tree7fe3e54ed4abc73789b4183cd7a84c3369e2fde6
parent65a5d1298c2594ed948cdb9be95367e5c7f1b61f
Bug 22880: (follow-up) Loose ends: Better DB update, global inclusion, etc.

This patch makes a number of improvements and ties up some loose ends
where the old system preference usage wasn't getting replaced.

 - Removes news-specific code for defining the language of news
   items queried for the OPAC home page. An identical language variable
   is already defined globally.

   Previous to this patch an 'opacheader' news item would only appear on
   the OPAC home page. Now it should appear on all OPAC pages.

 - Changes the database update so that 'opacheader' news
   items will be inserted with a default title, matching the interface's
   requirement that the title field be populated.

 - The database update will also now insert the old opacheader system
   preference contents into the news item for all active languages as
   defined in the 'opaclanguages' system preference. This helps match
   the previous behavior in which the opacheader contents were the same
   for all languages.

 - Adds support for the new opacheader news item to the self checkout,
   self check-in, and OPAC maintenance pages.

 - Updates sysprefs.t which was using the opacheader preference to test
   on. I've changed it to use URLLinkText instead.

 - Removes the addition of the opacheader system preference from the
   installation SQL file.

Signed-off-by: Lisette Scheer <lisettes@latahlibrary.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
installer/data/mysql/atomicupdate/bug_22880-move-opacheader-to-news.perl
installer/data/mysql/sysprefs.sql
koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead-sco.inc
koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc
koha-tmpl/opac-tmpl/bootstrap/en/modules/maintenance.tt
koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt
koha-tmpl/opac-tmpl/bootstrap/en/modules/sci/sci-main.tt
opac/opac-main.pl
t/db_dependent/sysprefs.t