And to be honest, I've already built the system (I don't use it for user upgrades, but everything else I do)... but it would be nice to have it as a core feature.
So in my case, I have payment handlers for the following types of content (just to give an idea of how it works):
- threads (someone pays for something listed as a thread)
- marketplace_domains (someone pays for a site or domain for via Buy It Now or winning bidder)
- marketplace_items (purchase of digital good)
- marketplace_articles (purchase of articles)
- advertising (advertiser funds their ad campaign with publisher)
Transactions are stored in a central transaction table like so:
...anyway, like I said... it's something I've already built and it makes payment handling super easy and flexible whenever you want to accept payments for some different type of content.
I'd be happy to donate my payment handler code, but it needs so much clean up, probably not even worth it. Either way, maybe an idea for XenForo 2.0 or something.