Class: ViewModel::AccessControl::ReadOnly

Inherits:
ViewModel::AccessControl show all
Defined in:
lib/view_model/access_control/read_only.rb

Constant Summary

Constants included from Callbacks

Callbacks::ALWAYS

Instance Method Summary collapse

Methods inherited from ViewModel::AccessControl

#editable!, #initialize, #visible!

Methods included from Callbacks

#ineligible, #run_callback, wrap_deserialize, wrap_serialize

Constructor Details

This class inherits a constructor from ViewModel::AccessControl

Instance Method Details

#editable_check(_traversal_env) ⇒ Object



8
9
10
# File 'lib/view_model/access_control/read_only.rb', line 8

def editable_check(_traversal_env)
  ViewModel::AccessControl::Result::DENY
end

#valid_edit_check(_traversal_env) ⇒ Object



12
13
14
# File 'lib/view_model/access_control/read_only.rb', line 12

def valid_edit_check(_traversal_env)
  ViewModel::AccessControl::Result::DENY
end

#visible_check(_traversal_env) ⇒ Object



4
5
6
# File 'lib/view_model/access_control/read_only.rb', line 4

def visible_check(_traversal_env)
  ViewModel::AccessControl::Result::PERMIT
end