Lines 278-287
is a reference-to-hash which may have any of the following keys:
Link Here
|
278 |
|
278 |
|
279 |
There is no item in the catalog with the given barcode. The value is C<$barcode>. |
279 |
There is no item in the catalog with the given barcode. The value is C<$barcode>. |
280 |
|
280 |
|
281 |
=item C<IsPermanent> |
|
|
282 |
|
283 |
The item's home branch is permanent. This doesn't prevent the item from being transferred, though. The value is the code of the item's home branch. |
284 |
|
285 |
=item C<DestinationEqualsHolding> |
281 |
=item C<DestinationEqualsHolding> |
286 |
|
282 |
|
287 |
The item is already at the branch to which it is being transferred. The transfer is nonetheless considered to have failed. The value should be ignored. |
283 |
The item is already at the branch to which it is being transferred. The transfer is nonetheless considered to have failed. The value should be ignored. |
Lines 336-350
sub transferbook {
Link Here
|
336 |
} |
332 |
} |
337 |
} |
333 |
} |
338 |
|
334 |
|
339 |
# if is permanent... |
|
|
340 |
# FIXME Is this still used by someone? |
341 |
# See other FIXME in AddReturn |
342 |
my $library = Koha::Libraries->find($hbr); |
343 |
if ( $library and $library->get_categories->search({'me.categorycode' => 'PE'})->count ) { |
344 |
$messages->{'IsPermanent'} = $hbr; |
345 |
$dotransfer = 0; |
346 |
} |
347 |
|
348 |
# can't transfer book if is already there.... |
335 |
# can't transfer book if is already there.... |
349 |
if ( $fbr eq $tbr ) { |
336 |
if ( $fbr eq $tbr ) { |
350 |
$messages->{'DestinationEqualsHolding'} = 1; |
337 |
$messages->{'DestinationEqualsHolding'} = 1; |
Lines 1766-1777
No item with this barcode exists. The value is C<$barcode>.
Link Here
|
1766 |
|
1753 |
|
1767 |
The book is not currently on loan. The value is C<$barcode>. |
1754 |
The book is not currently on loan. The value is C<$barcode>. |
1768 |
|
1755 |
|
1769 |
=item C<IsPermanent> |
|
|
1770 |
|
1771 |
The book's home branch is a permanent collection. If you have borrowed |
1772 |
this book, you are not allowed to return it. The value is the code for |
1773 |
the book's home branch. |
1774 |
|
1775 |
=item C<withdrawn> |
1756 |
=item C<withdrawn> |
1776 |
|
1757 |
|
1777 |
This book has been withdrawn/cancelled. The value should be ignored. |
1758 |
This book has been withdrawn/cancelled. The value should be ignored. |
Lines 1886-1901
sub AddReturn {
Link Here
|
1886 |
} |
1867 |
} |
1887 |
} |
1868 |
} |
1888 |
|
1869 |
|
1889 |
|
|
|
1890 |
# check if the book is in a permanent collection.... |
1891 |
# FIXME -- This 'PE' attribute is largely undocumented. afaict, there's no user interface that reflects this functionality. |
1892 |
if ( $returnbranch ) { |
1893 |
my $library = Koha::Libraries->find($returnbranch); |
1894 |
if ( $library and $library->get_categories->search({'me.categorycode' => 'PE'})->count ) { |
1895 |
$messages->{'IsPermanent'} = $returnbranch; |
1896 |
} |
1897 |
} |
1898 |
|
1899 |
# check if the return is allowed at this branch |
1870 |
# check if the return is allowed at this branch |
1900 |
my ($returnallowed, $message) = CanBookBeReturned($item, $branch); |
1871 |
my ($returnallowed, $message) = CanBookBeReturned($item, $branch); |
1901 |
unless ($returnallowed){ |
1872 |
unless ($returnallowed){ |