From cc353dc8ded4af204bcd4aa5179cf8297cc050b8 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 26 Feb 2016 01:00:30 +0000 Subject: [PATCH] Bug 15008 - Add custom HTML areas to circulation and reports home pages MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit To test: 1 - Apply patch 2 - run updatedatabase.pl 3 - Add some html to the two new prefs IntranetReportsHomeHTML and IntranetCirculationHomeHTML 4 - View the reports and circulation homepages and confirm your changes show Sponsored by Northeast Kansas Library System, NEKLS (http://nekls.org/) Followed test plan, works as expected. Signed-off-by: Marc VĂ©ron Signed-off-by: Jonathan Druart --- ...ug_15008_add_custom_html_areas_to_circ_and_reports_home.sql | 2 ++ .../prog/en/modules/admin/preferences/staff_client.pref | 10 ++++++++++ .../intranet-tmpl/prog/en/modules/circ/circulation-home.tt | 4 ++++ .../intranet-tmpl/prog/en/modules/reports/reports-home.tt | 5 +++++ 4 files changed, 21 insertions(+) create mode 100644 installer/data/mysql/atomicupdate/bug_15008_add_custom_html_areas_to_circ_and_reports_home.sql diff --git a/installer/data/mysql/atomicupdate/bug_15008_add_custom_html_areas_to_circ_and_reports_home.sql b/installer/data/mysql/atomicupdate/bug_15008_add_custom_html_areas_to_circ_and_reports_home.sql new file mode 100644 index 0000000..89ae903 --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_15008_add_custom_html_areas_to_circ_and_reports_home.sql @@ -0,0 +1,2 @@ +INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES ('IntranetReportsHomeHTML', '', 'Show the following HTML in a div on the bottom of the reports home page', NULL, 'Free'); +INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES ('IntranetCirculationHomeHTML', '', 'Show the following HTML in a div on the bottom of the reports home page', NULL, 'Free'); diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_client.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_client.pref index 75dfe0e..736ee68 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_client.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_client.pref @@ -91,6 +91,16 @@ Staff Client: - pref: SlipCSS class: url - on Issue and Hold Slips. (This should be a complete URL, starting with http://.) + - + - "Show the following HTML in its own div on the bottom of the home page of the circulation module:" + - pref: IntranetCirculationHomeHTML + type: htmlarea + class: code + - + - "Show the following HTML in its own div on the bottom of the home page of the reports module:" + - pref: IntranetReportsHomeHTML + type: htmlarea + class: code Options: - - pref: viewMARC diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation-home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation-home.tt index 8676992..eb46e20 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation-home.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation-home.tt @@ -68,7 +68,11 @@ + +
+ [% Koha.Preference('IntranetCirculationHomeHTML') %] +
[% INCLUDE 'intranet-bottom.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/reports-home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/reports-home.tt index fde9ad3..39260c4 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/reports-home.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/reports-home.tt @@ -1,3 +1,4 @@ +[% USE Koha %] [% INCLUDE 'doc-head-open.inc' %] Koha › Reports [% INCLUDE 'doc-head-close.inc' %] @@ -69,6 +70,10 @@ + +
+ [% Koha.Preference('IntranetReportsHomeHTML') %] +
[% INCLUDE 'intranet-bottom.inc' %] -- 2.7.0