Bug 31028: Add configurable help text and templates
authorMartin Renvoize <martin.renvoize@ptfs-europe.com>
Tue, 25 Oct 2022 12:40:32 +0000 (13:40 +0100)
committerTomas Cohen Arazi <tomascohen@theke.io>
Mon, 6 Mar 2023 14:23:17 +0000 (11:23 -0300)
commit086f2b01006db5528ad7edfda01f246c2f89e7ef
tree570aac833fc8849489e0473d69aae96f60badc4c
parent015004d41873f338a3c4f83d09c8accdd4e976c5
Bug 31028: Add configurable help text and templates

This patch adds configurable help text and a template option to the
catalog concern report modal in the OPAC.

Test plan
1) Enable `OpacCatalogConcerns` preference
2) Build the CSS for the OPAC
3) Check that there is a 'CatalogConcernHelp' block listed in the HTML
   Customisations page.
4) On the OPAC navigate to a record and click the 'Report a concern'
   button.
5) Confirm that the content of 'CatalogConcernHelp' displays beneath the
   detail entry box and that it displays as expected.
6) Check that there is a 'CatalogConcernTemplate' block listed in the
   HTML customisations page.
7) On the OPAC 'Report a concern' modal, you should see the content of
   the 'CatalogConcernTemplate' block pre-filled in the details
textarea.

Note: There is a caveat to the template.. as textarea can only be used
to submit plaintext with this patch and as such the template needs to
not utilise the WYSIWYG editor else you will be faced with raw HTML
inside your textarea.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Helen Oliver <HOliver@tavi-port.ac.uk>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
installer/data/mysql/atomicupdate/bug_31028.pl
installer/data/mysql/en/optional/sample_news.yml
koha-tmpl/intranet-tmpl/prog/en/modules/tools/additional-contents.tt
koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss
koha-tmpl/opac-tmpl/bootstrap/en/includes/modals/catalog_concern.inc
koha-tmpl/opac-tmpl/bootstrap/js/modals/catalog_concern.js