From 49a95d8d726c9db6cdb6786ee0dc7f02ab12e17c Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 22 Oct 2021 11:35:13 +0000 Subject: [PATCH] Bug 22605: Preselect subtype limits and don't allow multiple Dropdowns moved to an include, checked and preseleced Signed-off-by: Katrin Fischer --- .../prog/en/includes/subtype_limits.inc | 303 +++++++++++++++++---- .../prog/en/modules/catalogue/advsearch.tt | 66 +---- 2 files changed, 257 insertions(+), 112 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/subtype_limits.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/subtype_limits.inc index 1ac57b4ff2..4ae3888ca8 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/subtype_limits.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/subtype_limits.inc @@ -1,49 +1,256 @@ -[%- BLOCK subtype_limits_description -%] - [%- SWITCH subtype_limit -%] - [%- CASE 'aud:a' -%]Preschool - [%- CASE 'aud:b' -%]Primary - [%- CASE 'aud:c' -%]Pre-adolescent - [%- CASE 'aud:d' -%]Adolescent - [%- CASE 'aud:e' -%]Adult - [%- CASE 'aud:f' -%]Specialized - [%- CASE 'aud:g' -%]General - [%- CASE 'aud:j' -%]Juvenile - [%- CASE 'fic:1' -%]Fiction - [%- CASE 'fic:0' -%]Non-fiction - [%- CASE 'bio:b' -%]Biography - [%- CASE 'mus:j' -%]Musical recording - [%- CASE 'mus:i' -%]Non-musical recording - [%- CASE 'l-format:ta' -%]Regular print - [%- CASE 'l-format:tb' -%]Large print - [%- CASE 'l-format:tc or l-format:fb' -%]Braille - [%- CASE '' -%]----------- - [%- CASE 'l-format:sd' -%]CD audio - [%- CASE 'l-format:ss' -%]Cassette recording - [%- CASE 'l-format:vf' -%]VHS tape / Videocassette - [%- CASE 'l-format:vd' -%]DVD video / Videodisc - [%- CASE 'l-format:co' -%]CD software - [%- CASE 'l-format:cr' -%]Website - [%- CASE 'ctype:a' -%]Abstracts / Summaries - [%- CASE 'ctype:b' -%]Bibliographies - [%- CASE 'ctype:c' -%]Catalogs - [%- CASE 'ctype:d' -%]Dictionaries - [%- CASE 'ctype:e' -%]Encyclopedias - [%- CASE 'ctype:f' -%]Handbooks - [%- CASE 'ctype:g' -%]Legal articles - [%- CASE 'ctype:i' -%]Indexes - [%- CASE 'ctype:j' -%]Patent document - [%- CASE 'ctype:k' -%]Discographies - [%- CASE 'ctype:l' -%]Legislation - [%- CASE 'ctype:m' -%]Theses - [%- CASE 'ctype:n' -%]Surveys - [%- CASE 'ctype:o' -%]Reviews - [%- CASE 'ctype:p' -%]Programmed texts - [%- CASE 'ctype:q' -%]Filmographies - [%- CASE 'ctype:r' -%]Directories - [%- CASE 'ctype:s' -%]Statistics - [%- CASE 'ctype:t' -%]Technical reports - [%- CASE 'ctype:v' -%]Legal cases and case notes - [%- CASE 'ctype:w' -%]Law reports and digests - [%- CASE 'ctype:z' -%]Treaties - [%- END -%] +[%- BLOCK subtype_dropdowns -%] + + + + + [% SET lformat = 'l-format' %] + + + [%- END -%] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt index 4a05878fc5..d1a294c6b9 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt @@ -251,13 +251,13 @@
Subtype limits

- + [% PROCESS subtype_dropdowns %]

Current subtype limits [% FOREACH subtype IN ['aud','fic','bio','ctype','l-format'] %] [% FOREACH limit IN limits.$subtype %] - + [% END %] @@ -265,68 +265,6 @@ [% END %]
- - - - - - - - -

[% END %] -- 2.11.0