Lines 564-570
C<$issuingimpossible> and C<$needsconfirmation> are some hashref.
Link Here
|
564 |
|
564 |
|
565 |
=over 4 |
565 |
=over 4 |
566 |
|
566 |
|
567 |
=item C<$borrower> hash with borrower informations (from GetMember or GetMemberDetails) |
567 |
=item C<$borrower> hash with borrower informations (from GetMember) |
568 |
|
568 |
|
569 |
=item C<$barcode> is the bar code of the book being issued. |
569 |
=item C<$barcode> is the bar code of the book being issued. |
570 |
|
570 |
|
Lines 1224-1230
Issue a book. Does no check, they are done in CanBookBeIssued. If we reach this
Link Here
|
1224 |
|
1224 |
|
1225 |
=over 4 |
1225 |
=over 4 |
1226 |
|
1226 |
|
1227 |
=item C<$borrower> is a hash with borrower informations (from GetMember or GetMemberDetails). |
1227 |
=item C<$borrower> is a hash with borrower informations (from GetMember). |
1228 |
|
1228 |
|
1229 |
=item C<$barcode> is the barcode of the item being issued. |
1229 |
=item C<$barcode> is the barcode of the item being issued. |
1230 |
|
1230 |
|
Lines 1865-1871
sub AddReturn {
Link Here
|
1865 |
|
1865 |
|
1866 |
my $issue = GetItemIssue($itemnumber); |
1866 |
my $issue = GetItemIssue($itemnumber); |
1867 |
if ($issue and $issue->{borrowernumber}) { |
1867 |
if ($issue and $issue->{borrowernumber}) { |
1868 |
$borrower = C4::Members::GetMemberDetails($issue->{borrowernumber}) |
1868 |
$borrower = C4::Members::GetMember( borrowernumber => $issue->{borrowernumber} ) |
1869 |
or die "Data inconsistency: barcode $barcode (itemnumber:$itemnumber) claims to be issued to non-existent borrowernumber '$issue->{borrowernumber}'\n" |
1869 |
or die "Data inconsistency: barcode $barcode (itemnumber:$itemnumber) claims to be issued to non-existent borrowernumber '$issue->{borrowernumber}'\n" |
1870 |
. Dumper($issue) . "\n"; |
1870 |
. Dumper($issue) . "\n"; |
1871 |
} else { |
1871 |
} else { |
Lines 2814-2820
sub CanBookBeRenewed {
Link Here
|
2814 |
# by pushing all the elements onto an array and removing the duplicates. |
2814 |
# by pushing all the elements onto an array and removing the duplicates. |
2815 |
my @reservable; |
2815 |
my @reservable; |
2816 |
foreach my $b (@borrowernumbers) { |
2816 |
foreach my $b (@borrowernumbers) { |
2817 |
my ($borr) = C4::Members::GetMemberDetails($b); |
2817 |
my ($borr) = C4::Members::GetMember( borrowernumber => $b); |
2818 |
foreach my $i (@itemnumbers) { |
2818 |
foreach my $i (@itemnumbers) { |
2819 |
my $item = GetItem($i); |
2819 |
my $item = GetItem($i); |
2820 |
if ( IsAvailableForItemLevelRequest( $item, $borr ) |
2820 |
if ( IsAvailableForItemLevelRequest( $item, $borr ) |
Lines 3013-3019
sub AddRenewal {
Link Here
|
3013 |
|
3013 |
|
3014 |
# Send a renewal slip according to checkout alert preferencei |
3014 |
# Send a renewal slip according to checkout alert preferencei |
3015 |
if ( C4::Context->preference('RenewalSendNotice') eq '1' ) { |
3015 |
if ( C4::Context->preference('RenewalSendNotice') eq '1' ) { |
3016 |
$borrower = C4::Members::GetMemberDetails( $borrowernumber, 0 ); |
3016 |
$borrower = C4::Members::GetMember( borrowernumber => $borrowernumber ); |
3017 |
my $circulation_alert = 'C4::ItemCirculationAlertPreference'; |
3017 |
my $circulation_alert = 'C4::ItemCirculationAlertPreference'; |
3018 |
my %conditions = ( |
3018 |
my %conditions = ( |
3019 |
branchcode => $branch, |
3019 |
branchcode => $branch, |
Lines 3117-3123
sub GetSoonestRenewDate {
Link Here
|
3117 |
my $itemissue = GetItemIssue($itemnumber) or return; |
3117 |
my $itemissue = GetItemIssue($itemnumber) or return; |
3118 |
|
3118 |
|
3119 |
$borrowernumber ||= $itemissue->{borrowernumber}; |
3119 |
$borrowernumber ||= $itemissue->{borrowernumber}; |
3120 |
my $borrower = C4::Members::GetMemberDetails($borrowernumber) |
3120 |
my $borrower = C4::Members::GetMember( borrowernumber => $borrowernumber ) |
3121 |
or return; |
3121 |
or return; |
3122 |
|
3122 |
|
3123 |
my $branchcode = _GetCircControlBranch( $item, $borrower ); |
3123 |
my $branchcode = _GetCircControlBranch( $item, $borrower ); |
Lines 3773-3779
sub LostItem{
Link Here
|
3773 |
|
3773 |
|
3774 |
# If a borrower lost the item, add a replacement cost to the their record |
3774 |
# If a borrower lost the item, add a replacement cost to the their record |
3775 |
if ( my $borrowernumber = $issues->{borrowernumber} ){ |
3775 |
if ( my $borrowernumber = $issues->{borrowernumber} ){ |
3776 |
my $borrower = C4::Members::GetMemberDetails( $borrowernumber ); |
3776 |
my $borrower = C4::Members::GetMember( borrowernumber => $borrowernumber ); |
3777 |
|
3777 |
|
3778 |
if (C4::Context->preference('WhenLostForgiveFine')){ |
3778 |
if (C4::Context->preference('WhenLostForgiveFine')){ |
3779 |
my $fix = _FixOverduesOnReturn($borrowernumber, $itemnumber, 1, 0); # 1, 0 = exemptfine, no-dropbox |
3779 |
my $fix = _FixOverduesOnReturn($borrowernumber, $itemnumber, 1, 0); # 1, 0 = exemptfine, no-dropbox |
Lines 3869-3875
sub ProcessOfflineReturn {
Link Here
|
3869 |
sub ProcessOfflineIssue { |
3869 |
sub ProcessOfflineIssue { |
3870 |
my $operation = shift; |
3870 |
my $operation = shift; |
3871 |
|
3871 |
|
3872 |
my $borrower = C4::Members::GetMemberDetails( undef, $operation->{cardnumber} ); # Get borrower from operation cardnumber |
3872 |
my $borrower = C4::Members::GetMember( cardnumber => $operation->{cardnumber} ); |
3873 |
|
3873 |
|
3874 |
if ( $borrower->{borrowernumber} ) { |
3874 |
if ( $borrower->{borrowernumber} ) { |
3875 |
my $itemnumber = C4::Items::GetItemnumberFromBarcode( $operation->{barcode} ); |
3875 |
my $itemnumber = C4::Items::GetItemnumberFromBarcode( $operation->{barcode} ); |