Methods
C
D
I
S
U
Included Modules
Instance Public methods
create()
   # File rhino/rhino/app/controllers/rhino/crud_controller.rb
12 def create
13   @model = authorize klass.new(permit_and_transform(klass))
14   @model.save!
15 
16   permit_and_render
17 end
destroy()
   # File rhino/rhino/app/controllers/rhino/crud_controller.rb
42 def destroy
43   @model = authorize find_resource
44   @model.destroy!
45 
46   permit_and_render
47 end
index()
   # File rhino/rhino/app/controllers/rhino/crud_controller.rb
19 def index
20   authorize klass
21 
22   @models = klass.sieves.resolve(policy_scope(klass), params)
23   render json: {
24     results: @models.eager_load_refs.map { |m| permit_model(m) },
25     total: @models.unscope(:limit, :offset).reselect(:id).count
26   }
27 end
show()
   # File rhino/rhino/app/controllers/rhino/crud_controller.rb
29 def show
30   @model = authorize find_resource(policy_scope(klass).eager_load_refs)
31 
32   permit_and_render
33 end
update()
   # File rhino/rhino/app/controllers/rhino/crud_controller.rb
35 def update
36   @model = authorize find_resource
37   @model.update!(permit_and_transform)
38 
39   permit_and_render
40 end