I ran into something similar, and what fixed it for me was double-checking how the payments were entered—turns out I missed assigning them to the actual invoice. Also, make sure you Integrate All Payment Providers you're using so payments get logged properly and nothing slips through. Once I synced everything up and reassigned a few payments, the totals started showing correctly on the invoices.