Declarative Authorization - syntax

80 Views Asked by At

Is this the correct way of saying that the permission should allow read access if both attributes on the first line OR the second line attribute is true? Thank you

has_permission_on :grant do
      to => :read
      if_attribute { :grant_application_opens < Date.today :join_by => :and       :grant_application_closes > Date.today } 
      if_attribute :grant_application_enduring => true
      end
0

There are 0 best solutions below