@@ -, +, @@ --- C4/Accounts.pm | 9 +++++---- .../prog/en/modules/members/boraccount.tt | 2 +- .../prog/en/modules/members/paycollect.tt | 1 + members/pay.pl | 4 +++- members/paycollect.pl | 7 ++++--- 5 files changed, 14 insertions(+), 9 deletions(-) --- a/C4/Accounts.pm +++ a/C4/Accounts.pm @@ -685,7 +685,7 @@ will be credited to the next one. =cut sub recordpayment_selectaccts { - my ( $borrowernumber, $amount, $accts ) = @_; + my ( $borrowernumber, $amount, $accts, $notes ) = @_; my $dbh = C4::Context->dbh; my $newamtos = 0; @@ -726,11 +726,12 @@ sub recordpayment_selectaccts { $sth->execute( $newamtos, $thisacct ); } + my $note = join( "\n", @$notes ); # create new line $sql = 'INSERT INTO accountlines ' . - '(borrowernumber, accountno,date,amount,description,accounttype,amountoutstanding,manager_id) ' . - q|VALUES (?,?,now(),?,'Payment,thanks','Pay',?,?)|; - $dbh->do($sql,{},$borrowernumber, $nextaccntno, 0 - $amount, 0 - $amountleft, $manager_id ); + '(borrowernumber, accountno,date,amount,description,accounttype,amountoutstanding,manager_id,note) ' . + q|VALUES (?,?,now(),?,'Payment,thanks','Pay',?,?,?)|; + $dbh->do($sql,{},$borrowernumber, $nextaccntno, 0 - $amount, 0 - $amountleft, $manager_id, $note ); UpdateStats( $branch, 'payment', $amount, '', '', '', $borrowernumber, $nextaccntno ); return; } --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt @@ -45,7 +45,7 @@ [% IF ( loop.odd ) %]