https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11677

Nick Clemens <n...@bywatersolutions.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #92144|0                           |1
        is obsolete|                            |

--- Comment #31 from Nick Clemens <n...@bywatersolutions.com> ---
Created attachment 92176
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=92176&action=edit
Bug 11677: Use zebra not-onloan-count index for availability limit

This uses the work from bug 18098 to use the count of not-onloan items to
determine availability.

It keeps the allrecords,AlwaysMatches='' portion of the query so it still
catches
records with the tested indexed missing.
These shouldn't exist except in the case of missing data, but kept for future
use as well as
it has no negative impact and minimizes the change made.

Note that availability in this sense means not check out and not lost.
Transfers, holds, and not for loan statuses
should probably have indexes built in the same way as bug 18098 (there are
related FIXMEs in the code)

This updates the export_records file used for testing - adding three records
with a not-onloan-count (999$x) of 1,
but marking the item on the third record lost to prevent its return

To test:
   1 - make sure SearchEngine pref is set to 'Zebra'
   2 - Do a search on the OPAC that returns some records
   3 - Find a record in those results with more than one 1 item, and checkout 1
leaving 1 (or more) available
   4 - Find another record with only 1 item, check that item out
   5 - Limit opac search to available items - both records disappear
   6 - Apply patch
   7 - Restart all the things
   8 - Repeat search
   9 - First record should show, but no second
  10 - Mark other items of first record as lost, return items on second record
  11 - Repeat search, first record should not be in results, second should
  12 - prove -v t/db_dependent/Search.t

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to