For some reason after opening and saving the overdue payment file the maturity line no longer pulls the matured amount. Seems to be something wrong with this code
[[ time.strftime('%Y-%m-%d') > formatLang((line['date_maturity'])) and formatLang(line['debit'] - line['credit'],currency_obj=company.currency_id) ]]
Replacing this quote in open office designed does not fix the problem.