I’m looking at Ryan Bates’ Railscasts tutorial on integrating stripe (http://railscasts.com/episodes/288-billing-with-stripe), and I’m excited to try it out.
Before he starts the tutorial though, he already has an authorization system that has different roles. I’m assuming he has a role_id table in the database, and based on that, segments the users into different plans by calling plan_id= .
I’m not sure how to tackle that though, does anyone know of a good tutorial, or resource for creating plan_id type authorization systems, so I can continue with the tutorial?
The source code is great even for a noob like me :P.
He has two models — Plan, and User. Afterwards, he associates them together by saying Plan has_many users, and users belong_to Plan. The rest follows in the source code! Thanks to Apneadiving