[Koha-bugs] [Bug 9532] reserve rules with itemtype on biblio

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Jan 31 16:14:14 CET 2014


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9532

Kyle M Hall <kyle at bywatersolutions.com> changed:

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

--- Comment #16 from Kyle M Hall <kyle at bywatersolutions.com> ---
Created attachment 24949
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=24949&action=edit
Bug 9532: reserve rules with itemtype on biblio

When itemtype is defined on biblio (item-level_itypes syspref), the method
C4::Reserves::CanItemBeReserved uses item->{itemtype}. But item comes from
C4::Items::GetItem and it does not have a 'itemtype' key, in this method the
item type value is always in 'itype' key.

This patch corrects it.

Test plan:
You must have itemtype on biblio and 'item-level_itypes' syspref on biblio.
This test plan is with ReservesControlBranch on ItemHomeLibrary.
- Choose a branch, a borrower category and an item type, for example 'NYC',
'CHILD' and 'DVD'
- Set an issuing rule for 'NYC', CHILD' and 'DVD' with 'Holds allowed' on 10
- Set an issuing rule for 'NYC', CHILD' and all item types with 'Holds allowed'
on 0
- Choose an item of a biblio with itemtype 'DVD', that can be reserved, with
'NYC' as homebranch
- Choose a borrower with category 'CHILD'
- try to reverse the item for the borrower
=> without the patch, you can
=> with the patch, you can't
You may check reserve is allowed with 'Holds allowed' > 0 on issuing rule for
'DVD'.

Signed-off-by: Liz Rea <liz at catalyst.net.nz>
Great test plan - thanks!

Confirmed the bug, and the fix. Looks good to me.

Signed-off-by: Kyle M Hall <kyle at bywatersolutions.com>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list