Hai appena sbagliato l'ordine per group by
e order by
;
...
ORDER BY
FIELD( t.type, 'initial', 'commision', 'overpay', 'penalty', 'penalty2' )
GROUP BY
t.type;
Dovrebbe essere:
...
GROUP BY
t.type
ORDER BY
FIELD( t.type, 'initial', 'commision', 'overpay', 'penalty', 'penalty2' );