X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/29e70d36170f13f034474b9f5a831f727980a62f..d2bdf90e6aaf154f0cedd059bf41c60fb9a0e7db:/SL/RP.pm diff --git a/SL/RP.pm b/SL/RP.pm index ef93e73bb..80e83d569 100644 --- a/SL/RP.pm +++ b/SL/RP.pm @@ -1298,7 +1298,7 @@ sub aging { phone as customerphone, fax as customerfax, ${ct}number, "invnumber", "transdate", (amount - COALESCE((SELECT sum(amount)*$ml FROM acc_trans WHERE chart_link ilike '%paid%' AND acc_trans.trans_id=${arap}.id AND acc_trans.transdate <= (date $todate)),0)) as "open", "amount", - "duedate", invoice, ${arap}.id, date_part('days', now() - duedate) as overduedays, + "duedate", invoice, ${arap}.id, date_part('days', now() - duedate) as overduedays, datepaid, (amount - paid) as current_open, (SELECT $buysell FROM exchangerate WHERE (${arap}.currency_id = exchangerate.currency_id)