Class: BookPolicy

Inherits:
ApplicationPolicy show all
Defined in:
app/policies/book_policy.rb

Defined Under Namespace

Classes: Scope

Instance Attribute Summary

Attributes inherited from ApplicationPolicy

#record, #user

Instance Method Summary collapse

Methods inherited from ApplicationPolicy

#edit?, #index?, #initialize, #new?, #scope, #show?

Constructor Details

This class inherits a constructor from ApplicationPolicy

Instance Method Details

#create?Boolean

Returns:

  • (Boolean)

3
# File 'app/policies/book_policy.rb', line 3

def create? ; editor?; end

#destroy?Boolean

Returns:

  • (Boolean)

5
# File 'app/policies/book_policy.rb', line 5

def destroy?; editor?; end

#showObject


6
# File 'app/policies/book_policy.rb', line 6

def show    ; true; end

#update?Boolean

Returns:

  • (Boolean)

4
# File 'app/policies/book_policy.rb', line 4

def update? ; editor?; end