Bug 10599: add option to unselect on loan items on the batch item modification tool
authorJonathan Druart <jonathan.druart@biblibre.com>
Tue, 16 Jul 2013 14:43:30 +0000 (16:43 +0200)
committerGalen Charlton <gmc@esilibrary.com>
Wed, 18 Sep 2013 16:45:24 +0000 (16:45 +0000)
commit5ed940b18eddca2e4cd823afce2e9558b074158d
treed2af07537aa6a81f2ebd377cd7da396664dcefe0
parent990eebf132fef94dfbac4d3e17fe7acd9ce7b2c6
Bug 10599: add option to unselect on loan items on the batch item modification tool

Sometimes when using the batch item modification tool, we would like to
automatically uncheck on loan items.

This patch also adds a new routine in C4::Circulation, IsItemIssued(),
which, when passed an itemnumber, returns whether the item is
currently on loan.

Test plan:
1/ Go to tools/batchMod.pl.
2/ Enter some barcode (at least 1 should be on loan).
3/ Click on the Continue button.
4/ Click on the "Clear on loan" link.
5/ Check that on loan items are unchecked.

Launch the unit test file:
prove t/db_dependent/Circulation/IsItemIssued.t

http://bugs.koha-community.org/show_bug.cgi?id=10572
Signed-off-by: Liz Rea <liz@catalyst.net.nz>
Works as expected, only modifies items that are checked (still). No regression noted.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Passes koha-qa.pl, works as advertised.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
C4/Circulation.pm
koha-tmpl/intranet-tmpl/prog/en/js/pages/batchMod.js
koha-tmpl/intranet-tmpl/prog/en/modules/tools/batchMod-edit.tt
t/db_dependent/Circulation/IsItemIssued.t [new file with mode: 0644]
tools/batchMod.pl