Views:

This would be a journal entry. Where you set the Document type to payment, account type to customer, and select the customer number.
Then, click process, apply entries select the entry, Click process, Set applies-to Id. Click ok. 
Then, in the Bal. Account type select gl account and select the gl account to write off the amount.
Preview posting.  And if ok Post.