def METHOD_NAME(
     loan, dbcommit=True, reindex=True, delete_pid=False):
    """Create a patron transaction for an overdue loan."""
    from ..loans.utils import sum_for_fees
    fees = loan.get_overdue_fees
    total_amount = sum_for_fees(fees)
    if total_amount > 0:
        data = {
            'loan': {
                '$ref': get_ref_for_pid('loans', loan.pid)
            },
            'patron': {
                '$ref': get_ref_for_pid('ptrn', loan.patron_pid)
            },
            'organisation': {
                '$ref': get_ref_for_pid('org', loan.organisation_pid)
            },
            'type': 'overdue',
            'status': 'open',
            'note': _('incremental overdue fees'),
            'total_amount': total_amount,
            'creation_date': datetime.now(timezone.utc).isoformat(),
            'steps': [
                {'timestamp': fee[1].isoformat(), 'amount': fee[0]}
                for fee in fees
            ]
        }
        return PatronTransaction.create(
            data,
            dbcommit=dbcommit,
            reindex=reindex,
            delete_pid=delete_pid
        )