Scott Seago
2008-May-19 13:31 UTC
[Ovirt-devel] [PATCH] Fixed up the system for listing LDAP users, filtered by uniqueness constraints on the pool.
Darryl L. Pierce wrote:> Signed-off-by: Darryl L. Pierce <dpierce at redhat.com> > --- > wui/src/app/models/permission.rb | 2 ++ > 1 files changed, 2 insertions(+), 0 deletions(-) > > diff --git a/wui/src/app/models/permission.rb b/wui/src/app/models/permission.rb > index 0aab16c..74c6c26 100644 > --- a/wui/src/app/models/permission.rb > +++ b/wui/src/app/models/permission.rb > @@ -20,6 +20,8 @@ > class Permission < ActiveRecord::Base > belongs_to :pool > > + validates_uniqueness_of :uid, :scope => "pool_id" > + > ROLE_SUPER_ADMIN = "Super Admin" > ROLE_ADMIN = "Administrator" > ROLE_USER = "User" >ACK