View | Details | Raw Unified | Return to bug 7243
Collapse All | Expand All

(-)a/C4/Circulation.pm (-2 / +2 lines)
Lines 771-777 sub CanBookBeIssued { Link Here
771
    #
771
    #
772
772
773
    # DEBTS
773
    # DEBTS
774
    my ($ballance, $non_issue_charges, $other_charges) =
774
    my ($balance, $non_issue_charges, $other_charges) =
775
      C4::Members::GetMemberAccountBallance( $borrower->{'borrowernumber'} );
775
      C4::Members::GetMemberAccountBallance( $borrower->{'borrowernumber'} );
776
    my $amountlimit = C4::Context->preference("noissuescharge");
776
    my $amountlimit = C4::Context->preference("noissuescharge");
777
    my $allowfineoverride = C4::Context->preference("AllowFineOverride");
777
    my $allowfineoverride = C4::Context->preference("AllowFineOverride");
Lines 794-800 sub CanBookBeIssued { Link Here
794
            $needsconfirmation{DEBT} = sprintf( "%.2f", $non_issue_charges );
794
            $needsconfirmation{DEBT} = sprintf( "%.2f", $non_issue_charges );
795
        }
795
        }
796
    }
796
    }
797
    if ($ballance > 0 && $other_charges > 0) {
797
    if ($balance > 0 && $other_charges > 0) {
798
        $alerts{OTHER_CHARGES} = sprintf( "%.2f", $other_charges );
798
        $alerts{OTHER_CHARGES} = sprintf( "%.2f", $other_charges );
799
    }
799
    }
800
800
(-)a/C4/Members.pm (-6 / +5 lines)
Lines 430-436 sub patronflags { Link Here
430
    my %flags;
430
    my %flags;
431
    my ( $patroninformation) = @_;
431
    my ( $patroninformation) = @_;
432
    my $dbh=C4::Context->dbh;
432
    my $dbh=C4::Context->dbh;
433
    my ($ballance, $owing) = GetMemberAccountBallance( $patroninformation->{'borrowernumber'});
433
    my ($balance, $owing) = GetMemberAccountBallance( $patroninformation->{'borrowernumber'});
434
    if ( $owing > 0 ) {
434
    if ( $owing > 0 ) {
435
        my %flaginfo;
435
        my %flaginfo;
436
        my $noissuescharge = C4::Context->preference("noissuescharge") || 5;
436
        my $noissuescharge = C4::Context->preference("noissuescharge") || 5;
Lines 441-450 sub patronflags { Link Here
441
        }
441
        }
442
        $flags{'CHARGES'} = \%flaginfo;
442
        $flags{'CHARGES'} = \%flaginfo;
443
    }
443
    }
444
    elsif ( $ballance < 0 ) {
444
    elsif ( $balance < 0 ) {
445
        my %flaginfo;
445
        my %flaginfo;
446
        $flaginfo{'message'} = sprintf "Patron has credit of \$%.02f", -$ballance;
446
        $flaginfo{'message'} = sprintf "Patron has credit of \$%.02f", -$balance;
447
        $flaginfo{'amount'}  = sprintf "%.02f", $ballance;
447
        $flaginfo{'amount'}  = sprintf "%.02f", $balance;
448
        $flags{'CREDITS'} = \%flaginfo;
448
        $flags{'CREDITS'} = \%flaginfo;
449
    }
449
    }
450
    if (   $patroninformation->{'gonenoaddress'}
450
    if (   $patroninformation->{'gonenoaddress'}
Lines 1142-1148 sub GetMemberAccountRecords { Link Here
1142
1142
1143
=head2 GetMemberAccountBallance
1143
=head2 GetMemberAccountBallance
1144
1144
1145
  ($total_ballance, $non_issue_ballance, $other_charges) = &GetMemberAccountBallance($borrowernumber);
1145
  ($total_balance, $non_issue_balance, $other_charges) = &GetMemberAccountBallance($borrowernumber);
1146
1146
1147
Calculates amount immediately owing by the patron - non-issue charges.
1147
Calculates amount immediately owing by the patron - non-issue charges.
1148
Based on GetMemberAccountRecords.
1148
Based on GetMemberAccountRecords.
1149
- 

Return to bug 7243