Updated invoice model_report to reduce the number of queries for better performance (98% queries reduced)