Bugzilla – Attachment 155842 Details for
Bug 6419
Add customizable areas to intranet home pages
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 6419: Add StaffCataloguingHome block to additional contents
Bug-6419-Add-StaffCataloguingHome-block-to-additio.patch (text/plain), 8.21 KB, created by
Lucas Gass (lukeg)
on 2023-09-18 16:14:15 UTC
(
hide
)
Description:
Bug 6419: Add StaffCataloguingHome block to additional contents
Filename:
MIME Type:
Creator:
Lucas Gass (lukeg)
Created:
2023-09-18 16:14:15 UTC
Size:
8.21 KB
patch
obsolete
>From b55fb8444087d6c202d880375e3a2d2d12c01774 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Tue, 15 Aug 2023 16:02:52 +0100 >Subject: [PATCH] Bug 6419: Add StaffCataloguingHome block to additional > contents > >This patch adds a new `StaffCataloguingHome` block to the HTML >Customisations options. This allows for the addition of a block of >content in a page-section at the bottom of the cataloguing home >page. > >Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> >Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> >--- > ...6419_Add_customizable_areas_to_module_start_pages.sql | 2 +- > installer/data/mysql/mandatory/sysprefs.sql | 1 - > .../en/modules/admin/preferences/staff_interface.pref | 6 ------ > .../prog/en/modules/cataloguing/addbooks.tt | 4 ---- > .../prog/en/modules/cataloguing/cataloging-home.tt | 9 +++++++++ > .../prog/en/modules/tools/additional-contents.tt | 2 +- > 6 files changed, 11 insertions(+), 13 deletions(-) > >diff --git a/installer/data/mysql/atomicupdate/bug_6419_Add_customizable_areas_to_module_start_pages.sql b/installer/data/mysql/atomicupdate/bug_6419_Add_customizable_areas_to_module_start_pages.sql >index e2a57a9036..259b6506e4 100644 >--- a/installer/data/mysql/atomicupdate/bug_6419_Add_customizable_areas_to_module_start_pages.sql >+++ b/installer/data/mysql/atomicupdate/bug_6419_Add_customizable_areas_to_module_start_pages.sql >@@ -2,7 +2,7 @@ $DBversion = 'XXX'; # will be replaced by the RM > if( CheckVersion( $DBversion ) ) { > # you can use $dbh here like: > $dbh->do(q{ >-INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES ('IntranetCatalogingHomeHTML', '', 'Show the following HTML in a div on the bottom of the cataloging home page', NULL, 'Free'), ('IntranetListsHomeHTML', '', 'Show the following HTML in a div on the bottom of the lists home page', NULL, 'Free'), ('IntranetPatronsHomeHTML', '', 'Show the following HTML in a div on the bottom of the patrons home page', NULL, 'Free'), ('IntranetPOSHomeHTML', '', 'Show the following HTML in a div on the bottom of the point of sale home page', NULL, 'Free'), ('IntranetSerialsHomeHTML', '', 'Show the following HTML in a div on the bottom of the serials home page', NULL, 'Free')}); >+INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES ('IntranetListsHomeHTML', '', 'Show the following HTML in a div on the bottom of the lists home page', NULL, 'Free'), ('IntranetPatronsHomeHTML', '', 'Show the following HTML in a div on the bottom of the patrons home page', NULL, 'Free'), ('IntranetPOSHomeHTML', '', 'Show the following HTML in a div on the bottom of the point of sale home page', NULL, 'Free'), ('IntranetSerialsHomeHTML', '', 'Show the following HTML in a div on the bottom of the serials home page', NULL, 'Free')}); > > SetVersion( $DBversion ); > print "Upgrade to $DBversion done (Bug 6419 - Add customizable areas to intranet start pages)\n"; >diff --git a/installer/data/mysql/mandatory/sysprefs.sql b/installer/data/mysql/mandatory/sysprefs.sql >index ab7fb3b605..76e19d7b3b 100644 >--- a/installer/data/mysql/mandatory/sysprefs.sql >+++ b/installer/data/mysql/mandatory/sysprefs.sql >@@ -305,7 +305,6 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` > ('IndependentBranchesPatronModifications','0', NULL, 'Show only modification request for the logged in branch','YesNo'), > ('IndependentBranchesTransfers','0', NULL, 'Allow non-superlibrarians to transfer items between libraries','YesNo'), > ('IntranetAddMastheadLibraryPulldown','0', NULL, 'Add a library select pulldown menu on the staff header search','YesNo'), >-('IntranetCatalogingHomeHTML', '', NULL, 'Show the following HTML in a div on the bottom of the cataloging home page', 'Free'), > ('IntranetCatalogSearchPulldown','0', NULL, 'Show a search field pulldown for \"Search the catalog\" boxes','YesNo'), > ('OnSiteCheckouts','0','','Enable/Disable the on-site checkouts feature','YesNo'), > ('OnSiteCheckoutsForce','0','','Enable/Disable the on-site for all cases (Even if a user is debarred, etc.)','YesNo'), >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_interface.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_interface.pref >index b9ee4ca208..9a238122d3 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_interface.pref >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_interface.pref >@@ -107,12 +107,6 @@ Staff interface: > - pref: SlipCSS > class: url > - on Issue and Hold Slips. (This should be a complete URL, starting with <code>http://</code>.) >- - >- - "Show the following HTML in its own div on the bottom of the home page of the cataloguing module:" >- - pref: IntranetCatalogingHomeHTML >- type: textarea >- syntax: text/html >- class: code > - > - "Show the following HTML in its own div on the bottom of the home page of the circulation module:" > - pref: IntranetCirculationHomeHTML >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbooks.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbooks.tt >index f7b75f90fb..1c68a871ac 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbooks.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbooks.tt >@@ -274,10 +274,6 @@ > </div> <!-- /.col-md-10.col-md-offset-1.col-lg-8.col-lg-offset-2 --> > </div> <!-- /.row --> > >- <div class="row" id="intranet-cataloging-home-html"> >- [% Koha.Preference('IntranetCatalogingHomeHTML') | $raw %] >- </div> >- > [% MACRO jsinclude BLOCK %] > [% INCLUDE 'datatables.inc' %] > [% INCLUDE 'columns_settings.inc' %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/cataloging-home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/cataloging-home.tt >index 9ba30c5aa1..57a3dcb41c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/cataloging-home.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/cataloging-home.tt >@@ -1,4 +1,5 @@ > [% USE raw %] >+[% USE AdditionalContents %] > [% USE Koha %] > [% USE Branches %] > [% PROCESS 'i18n.inc' %] >@@ -216,6 +217,14 @@ > > </div> > </div> >+ >+ [%- SET StaffCataloguingHome = AdditionalContents.get( location => "StaffCataloguingHome", lang => lang, library => logged_in_user.branchcode ) -%] >+ [%- FOREACH block IN StaffCataloguingHome.content -%] >+ <div class="page-section"> >+ [%- block.content | $raw -%] >+ </div> >+ [%- END -%] >+ > </div> > </div> > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/additional-contents.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/additional-contents.tt >index 94921b6777..8dd79e7cb8 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/additional-contents.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/additional-contents.tt >@@ -494,7 +494,7 @@ > [% END %] > [% END %] > [% ELSE %] >- [% SET available_options = [ 'OpacNavRight', 'opacheader', 'OpacCustomSearch', 'OpacMainUserBlock', 'opaccredits', 'OpacLoginInstructions', 'OpacNav', 'OpacNavBottom', 'OpacSuggestionInstructions', 'ArticleRequestsDisclaimerText', 'OpacMoreSearches', 'OpacMySummaryNote', 'OpacLibraryInfo', 'CatalogConcernHelp', 'CatalogConcernTemplate', 'CookieConsentBar', 'CookieConsentPopup', 'StaffAcquisitionsHome', 'StaffAuthoritiesHome' ] %] >+ [% SET available_options = [ 'OpacNavRight', 'opacheader', 'OpacCustomSearch', 'OpacMainUserBlock', 'opaccredits', 'OpacLoginInstructions', 'OpacNav', 'OpacNavBottom', 'OpacSuggestionInstructions', 'ArticleRequestsDisclaimerText', 'OpacMoreSearches', 'OpacMySummaryNote', 'OpacLibraryInfo', 'CatalogConcernHelp', 'CatalogConcernTemplate', 'CookieConsentBar', 'CookieConsentPopup', 'StaffAcquisitionsHome', 'StaffAuthoritiesHome', 'StaffCataloguingHome' ] %] > [% FOREACH l IN available_options.sort %] > [% IF l == location %] > <option value="[% l | html %]" selected="selected">[% l | html %]</option> >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 6419
:
105255
|
108633
|
137787
|
137822
|
139501
|
154433
|
154434
|
154435
|
154436
|
154437
|
154441
|
154442
|
154443
|
154444
|
154445
|
154446
|
154447
|
154448
|
154449
|
154450
|
154451
|
154452
|
154519
|
154520
|
154521
|
154522
|
154523
|
154524
|
154525
|
154526
|
154527
|
155808
|
155809
|
155810
|
155811
|
155812
|
155813
|
155814
|
155815
|
155816
|
155839
|
155840
|
155841
| 155842 |
155843
|
155844
|
155845
|
155846
|
155847