Custom Customer Credit Balnce Report

I want to make custom report for customer credit balance report, the condition is if i submit sales order, the credit balance won’t decrease, instead if i submit sales invoice the credit balance will decrease. is there anyone can help?