Bug 10741: restore holdability of in-transit items on OPAC search results

In search results, one could not place a hold on an item in transit
and for loan (items.notforloan=0).  This appears when AllowOnShelfHolds
is allowed.

This patch repairs a regression introduced by the patch for bug 8975.

Test plan :
- Set AllowOnShelfHolds to on
- Create a record with a normal item : not lost, not withdrawn, not
  damaged, notforloan=0
- Index this record
- Perform a search on OPAC that returns this record (and others)
=> You see in actions "Place hold"
- Add this item in transit : /cgi-bin/koha/circ/branchtransfers.pl
- Re-perform the search on OPAC
=> You see in actions "Place hold" and item "in transit"

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10741: reformat test for displaying place hold link in OPAC search results

To test:

[1] Turn on the syspref for enabling OPAC holds.
[2] Create an item and bring it up on the OPAC search
    results.  Run through the following possibilities,
    by changing the item, and verify that the place hold
    link in OPAC search results appears only when the item is

    - not lost AND
    - not withdrawn AND
    - not damaged (or is damged and AllowHoldsOnDamagedItems is ON) AND
    - the item is not marked not-for-loan OR
      the item has a negative notforloan value (e.g., it is on order)

    Note that it is necessary to reindex the test bib after making
    each change to the test item.

[3] Also verify that whether or not in the item is in transit does
    NOT affect whether the place hold link appears.
[4] Verify that there is no regression on bug 8975 (i.e., if an
    item is on order, that status should be displayed in staff client
    search results).

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10741: (follow-up) add regression test

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10745: remove more ambiguity for translators for XSLT subfieldSelect parameters

As in Bug 6278, this patch replace ">at<" with ">a_t<"
so not to mislead translators. Found more cases that
initial description.

To test:

1) Check that problem exists and only on xslt files,
using your preferred language

egrep -B10 "^msgid \"at\"" misc/translator/po/xx-YY-i-staff-t*

2) Apply the patch

3) Update translation file
(cd misc/translator; perl translate update xx-YY)

4) Verify the problem is gone, repeat 1

5) If you like verify new entries in PO file

egrep -B15 "^msgid \"a_t\"" misc/translator/po/xx-YY-i-staff-t*

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Tested this with field 780 and running a Dutch translation.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10766: unbreak reservoir search when UseQueryParser is OFF

To test:

[1] Turn UseQueryParser off.
[2] Ensure that your database has records in the reservoir.  Performing
    a Z39.50 search will do this.
[3] Perform a broad cataloging (i.e., cataloguing/addbooks.pl search).
    Note that results are returned from the main catalog but that no
    reservoir results are returned.
[4] Apply the patch.
[5] Perform the search again.  This time, there should be both catalog
    and reservoir results.
[7] Enable QueryParser.  Perform the search again, and verify that the
    catalog and reservoir results are the same.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Patch works nicely, passes all tests, and the QA script.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>