django-user-roles icon indicating copy to clipboard operation
django-user-roles copied to clipboard

Support display names for roles

Open j4mie opened this issue 13 years ago • 0 comments

For displaying roles to users of the application. Example:

You have received a new message from {{ user.get_profile.full_name }}. This user is an {{ user.role.display_name }}.

(display_name might not be the best naming..)

Should work just like model choices. User role names can (optionally) be tuples:

USER_ROLES = (
    'manager',
    'moderator',
    'client',
    ('admin', 'administrator'),
)

j4mie avatar Apr 05 '12 08:04 j4mie