[open-ils-commits] [GIT] Evergreen ILS branch master updated. 6e2cf57a7e039a1758d2ed219c935a555e7061d6

Evergreen Git git at git.evergreen-ils.org
Wed Feb 15 21:43:23 EST 2017


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".

The branch, master has been updated
       via  6e2cf57a7e039a1758d2ed219c935a555e7061d6 (commit)
       via  e95f48b665e998fbccc380b0c7031270840f2287 (commit)
      from  9e34ab959c120ed6b65b065704bc71ff34d676c1 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 6e2cf57a7e039a1758d2ed219c935a555e7061d6
Author: Mike Rylander <mrylander at gmail.com>
Date:   Thu Feb 9 15:29:52 2017 -0500

    LP#1663374: Release notes for metarecord search by default
    
    Signed-off-by: Mike Rylander <mrylander at gmail.com>
    Signed-off-by: Kathy Lussier <klussier at masslnc.org>

diff --git a/docs/RELEASE_NOTES_NEXT/OPAC/Metarecord_search_by_default.adoc b/docs/RELEASE_NOTES_NEXT/OPAC/Metarecord_search_by_default.adoc
new file mode 100644
index 0000000..e85efd6
--- /dev/null
+++ b/docs/RELEASE_NOTES_NEXT/OPAC/Metarecord_search_by_default.adoc
@@ -0,0 +1,12 @@
+Allow Metarecord Search by default
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+Before the TPAC, a site could configure the OPAC to use metarecord searching
+by default, via a configuration file.  Here we bring that back.
+
+A new setting called search.metarecord_default is present in
+templates/opac/parts/config.tt2 to enable this feature.  By setting this to
+a true value (normally 1) the TPAC will silently include the #metabib search
+modifier in the search form on any interfaces that do not have a UI component
+that allows the user to control the setting.
+
+

commit e95f48b665e998fbccc380b0c7031270840f2287
Author: Mike Rylander <mrylander at gmail.com>
Date:   Wed Dec 7 16:47:01 2016 -0500

    LP#1663374: Allow metarecord searching by default
    
    Before the TPAC, a site could configure the OPAC to use metarecord searching
    by default, via a configuration file.  Here we bring that back.
    
    A new setting is present in templates/opac/parts/config.tt2 to enable this
    feature.  By setting this to a true value (normally 1) the TPAC will silently
    include the #metabib search modifier in the search form on any interfaces that
    do not have a UI component that allows the user to control the setting.
    
    Signed-off-by: Mike Rylander <mrylander at gmail.com>
    Signed-off-by: Kathy Lussier <klussier at masslnc.org>

diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm
index c5b2840..3b1a661 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm
@@ -156,6 +156,8 @@ sub load {
     return $self->load_logout if $path =~ m|opac/logout|;
     return $self->load_patron_reg if $path =~ m|opac/register|;
 
+    $self->load_simple("myopac") if $path =~ m:opac/myopac:; # A default page for myopac parts
+
     if($path =~ m|opac/login|) {
         return $self->load_login unless $self->editor->requestor; # already logged in?
 
diff --git a/Open-ILS/src/templates/opac/parts/advanced/search.tt2 b/Open-ILS/src/templates/opac/parts/advanced/search.tt2
index dc650a1..5ea98bf 100644
--- a/Open-ILS/src/templates/opac/parts/advanced/search.tt2
+++ b/Open-ILS/src/templates/opac/parts/advanced/search.tt2
@@ -132,7 +132,7 @@
                             <input> (below) to drop down inline w/ its label -->
                         <div class="adv_search_available">
                             <input type='checkbox' name="modifier" value="metabib"
-                              [%- CGI.param('modifier').grep('metabib').size ?
+                              [%- CGI.param('modifier').grep('metabib').size || search.metarecord_default ?
                                     ' checked="checked"' : '' %]
                                 id='opac.result.ismetabib' />
                             <label for='opac.result.ismetabib'>
diff --git a/Open-ILS/src/templates/opac/parts/config.tt2 b/Open-ILS/src/templates/opac/parts/config.tt2
index 58d2c09..3585ba7 100644
--- a/Open-ILS/src/templates/opac/parts/config.tt2
+++ b/Open-ILS/src/templates/opac/parts/config.tt2
@@ -167,6 +167,9 @@ search.basic_config = {
     none_label => l("All Formats"),
 };
 
+# Make metarecord search the default.
+#search.metarecord_default = 1;
+
 ##############################################################################
 # Show Google Book Previews
 # Set to 1 or 'true' to enable
diff --git a/Open-ILS/src/templates/opac/parts/searchbar.tt2 b/Open-ILS/src/templates/opac/parts/searchbar.tt2
index 9d6a0dd..f807134 100644
--- a/Open-ILS/src/templates/opac/parts/searchbar.tt2
+++ b/Open-ILS/src/templates/opac/parts/searchbar.tt2
@@ -17,6 +17,12 @@ END;
     [% UNLESS took_care_of_form -%]
     <form action="[% ctx.opac_root %]/results" method="get">
     [%- END %]
+    [% IF ctx.page == 'rresult' && ctx.metarecord && search.metarecord_default %]
+    <input type="hidden" name="modifier" value="metabib"/>
+    [% END %]
+    [% IF (ctx.page == 'place_hold' || ctx.page == 'myopac' || ctx.page == 'home' || ctx.page == 'record') && search.metarecord_default %]
+    <input type="hidden" name="modifier" value="metabib"/>
+    [% END %]
     <div id="search-box">
         <span class="search_catalog_lbl mobile_hide">[% l('Search the Catalog') %]</span>
         <span class="adv_search_catalog_lbl"><a href="[% mkurl(ctx.opac_root _ '/advanced', {},  expert_search_parms.merge(browse_search_parms, facet_search_parms)) %]"

-----------------------------------------------------------------------

Summary of changes:
 .../src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm    |    2 ++
 .../src/templates/opac/parts/advanced/search.tt2   |    2 +-
 Open-ILS/src/templates/opac/parts/config.tt2       |    3 +++
 Open-ILS/src/templates/opac/parts/searchbar.tt2    |    6 ++++++
 .../OPAC/Metarecord_search_by_default.adoc         |   12 ++++++++++++
 5 files changed, 24 insertions(+), 1 deletions(-)
 create mode 100644 docs/RELEASE_NOTES_NEXT/OPAC/Metarecord_search_by_default.adoc


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list