All threads / User create Dynamic Role base

Ask A Question

Notifications

You’re not receiving notifications from this thread.

User create Dynamic Role base

Francisco Quinones asked in General

Hi! So my app uses CanCanCan and Devise for working with users. Now the app needs to have a feature where users can create role. How can I approach this new task.

Example:
Admin(User) can create Roles with a permission list (can and can't with on/off boolean) without redeploying the app.

Check out Rolify. It can handle pretty much anything you want to do with roles and permissions.

Francisco, Did you ever find a solution to this? I know its older but I'm having a heck of a time finding resources on dynamic roles.. 
I recently did this using Rolify. _Fairly_ straightforward. 
Join the discussion

Want to stay up-to-date with Ruby on Rails?

Join 39,609+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.

    logo Created with Sketch.

    Ruby on Rails tutorials, guides, and screencasts for web developers learning Ruby, Rails, Javascript, Turbolinks, Stimulus.js, Vue.js, and more. Icons by Icons8

    © 2020 GoRails, LLC. All rights reserved.