Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

readme updated to reflect better wiki

  • Loading branch information...
commit 7c50b23461faea02010f46a275d6f526f847199f 1 parent 8d73e1d
@kristianmandrup authored
Showing with 7 additions and 44 deletions.
  1. +7 −44 README.mdown
51 README.mdown
@@ -1,56 +1,17 @@
# CanTango Roles
-Roles and Role groups extension for [CanTango](
+Roles and Role groups extension for [cantango-permits](
-## Status: Dec 9, 2011
-Most specs except those for Permits have been completed and demonstrates that the functionality works as it should.
-## Ability helper
-* Ability::Helper
- * Role
- * RoleGroup
-These modules are typically included into an Ability in order to access the roles of the ability subject, typically a user (or in rare cases an account).
-The `Role` module has a `#roles` method which returns the role list of the subject.
-The `RoleGroup` module has a `#role_groups` method which returns the role group list of the subject.
-## Configuration Registry
-Roles and RoleGroups configuration via a Registry.
-Roles configuration:
-CanTango.config do |config|
- config.roles do |roles|
- roles.register :admin, :guest, :basic
- roles.system = :simple_roles
- roles.exclude :admin # filter
- end
-Role groups configuration:
-CanTango.config do |config|
- config.roles_groups do |role_groups|
- role_groups.register :editors, :publishers
- role_groups.system = :troles
- role_groups.only :editors # filter
- end
## Permits
-Role and RoleGroup Permits for the Permits engine Ability executor.
+This extension includes `Role` and `RoleGroup` Permits.
## Permit Generators
-Role and RoleGroup Permit Generators
+The gem includes `Role` and `RoleGroup` Permit generators
+### Using generators
`rails g cantango:role_permit admin`
@@ -62,6 +23,8 @@ Role and RoleGroup Permit Generators
Role and RoleGroup filters can be used to filter out specific Role and RoleGroup Permits.
+See [Roles configuration](
## Helpers
Role and RoleGroup helper methods which can be reused in various places, such as Ability executors, Permits etc.
Please sign in to comment.
Something went wrong with that request. Please try again.