acl9

issue with acl9 plugin

I am trying to allow users with role "corporate" to access their own company. Currently a user with that role gets blocked. If i login as admin or change the access control to allow all, it works fine. The issue is pertaining to Corporate user role having a company. here is all the code http://pastie.org/672733 User controller class...

acl9 find just model object which satisfys object.accepts_role?(role_name, current_user)

Hello, I'm pretty new to rails and it's the first time I'm actually using authlogic + acl9. I followed the default installation steps for both plugins. So far everything works great, but I have trouble to find an elegant solution for this problem: Let's say I have a model class called Products. When creating a new Product object I ass...

acl9 roles deleted if no user

So for whatever reason this plugin will not maintain a role if there are no users added to it. A role whose last user is removed gets removed from the roles. Is there a workaround for this? ...

Rails | Cucumber | acl9 | AccessDenied

Hi guys, I am ramping up Cucumber, and I am having a issue getting one of my first tests to pass. The exception I am getting is: And I visit the new contract screen Acl9::AccessDenied (Acl9::AccessDenied) /usr/local/lib/ruby/1.8/benchmark.rb:308:in `realtime' (eval):2:in `visit' ./features/step_definitions/manage_contracts_ste...

Changing user roles through a form

I'm trying to create a Rails form that allows an admin user to change the assigned roles of other users. The form I've created registers changes to the user (such as password or login changes), but doesn't register changes to the user's role, which is a separate model. I'm using Acl9 for role-based authentication, which uses a User ...

get a list of objects with roles applied in be9 acl9

I think in something like this: def self.obj_list(opts = {:include => [] , :exclude => []}) # Returns an array with all objects with roles applied # +:exclude+:: (array,string) optional object type to exclude from list # +:include+:: (array,string) optional object type to include in list # Example: # Role.obj_list(...

acl9: Determine authorization in advance

I am using acl9 on top of authlogic on one of my projects. I like the approach acl9's approach but I guess I am trying to do something that is just not that simple (not to say impossible). For reasons of usability I would like to have an inline admin panel. So for example say I got a resource auction and a nested resource auction/bid. W...

Show or hide fields depending on the Acl9 role - Ruby on Rails

Hi, I am using Acl9 to manage the roles and I want to hide the checkbox usertype if the user has the role :customer and show it if the role is :manager. I want that just the :manager can edit all the fields and some for the :customer. Thank you for your help! <h1>Editing user</h1> <% form_for(@user) do |f| %> <%= f.error_messages %...

acl9 and devise don't seem to work well together

I have a user model which is access controlled by ACL9 in userscontroller: ACL9 related stuff before_filter :load_user, :only => [:show] access_control do allow :owner, :of => :user, :to => [:show] end def load_user user = User.find(params[:id]) end in ApplicaitonController I have a rescue_from 'Acl9::AccessDenied', :with => ...