Class: Coalla::DefaultPolicy

Inherits:
Object
  • Object
show all
Defined in:
lib/coalla/builders/policy.rb

Instance Method Summary collapse

Constructor Details

#initialize(context) ⇒ DefaultPolicy

Returns a new instance of DefaultPolicy.



3
4
5
# File 'lib/coalla/builders/policy.rb', line 3

def initialize(context)
  @context = context
end

Instance Method Details

#action_enabled?(action, options = {}) ⇒ Boolean

Returns:

  • (Boolean)


7
8
9
# File 'lib/coalla/builders/policy.rb', line 7

def action_enabled?(action, options = {})
  return true
end

#field_enabled?(field, options = {}) ⇒ Boolean

Returns:

  • (Boolean)


11
12
13
# File 'lib/coalla/builders/policy.rb', line 11

def field_enabled?(field, options = {})
  return true
end

#sanitize_params(params, options = {}) ⇒ Object



19
20
21
# File 'lib/coalla/builders/policy.rb', line 19

def sanitize_params(params, options = {})
  return params
end

#section_enabled?(section, options = {}) ⇒ Boolean

Returns:

  • (Boolean)


15
16
17
# File 'lib/coalla/builders/policy.rb', line 15

def section_enabled?(section, options = {})
  return true
end