mercredi 15 avril 2015

How to modify cancan load and authorize resource to load resource using different id

How can I modify load and authorize resources to load resource using different id. for ex.


my routes is



http://localhost:3000/organization/user/12/event/20/edit


and in my event controller I am accessing event using :event_id and user using :id


Now in my event controller how can I modify load_and_authorize_resource use :event_id instead of :id for loading an event


Aucun commentaire:

Enregistrer un commentaire