Say I purchsed $500 in Office Supplies on account, I return the office supplies, since I purchased them on account, the company I purchased them from will extend me a credit to my account decreasing...
When your customers pays you in advance, you'd:
Dr Cash xxx
Cr Unearned service revenue xxx (liability item in balance sheet)
When you've provided the service, you'd
Dr Unearned service revenue...