声明性授权 - 语法

时间:2014-03-04 23:18:25

标签: ruby-on-rails declarative-authorization

如果第一行或第二行属性中的两个属性都为真,这是否正确说明权限应允许读取权限?谢谢

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 个答案:

没有答案