Class: Gaku::Admin::CommuteMethodTypesController

Inherits:
BaseController
  • Object
show all
Defined in:
app/controllers/gaku/admin/commute_method_types_controller.rb

Instance Method Summary collapse

Instance Method Details

#createObject



19
20
21
22
23
24
# File 'app/controllers/gaku/admin/commute_method_types_controller.rb', line 19

def create
  @commute_method_type = CommuteMethodType.new(commute_method_type_params)
  @commute_method_type.save
  set_count
  respond_with @commute_method_type
end

#destroyObject



34
35
36
37
38
# File 'app/controllers/gaku/admin/commute_method_types_controller.rb', line 34

def destroy
  @commute_method_type.destroy
  set_count
  respond_with @commute_method_type
end

#editObject



26
27
# File 'app/controllers/gaku/admin/commute_method_types_controller.rb', line 26

def edit
end

#indexObject



8
9
10
11
12
# File 'app/controllers/gaku/admin/commute_method_types_controller.rb', line 8

def index
  @commute_method_types = CommuteMethodType.all
  set_count
  respond_with @commute_method_types
end

#newObject



14
15
16
17
# File 'app/controllers/gaku/admin/commute_method_types_controller.rb', line 14

def new
  @commute_method_type = CommuteMethodType.new
  respond_with @commute_method_type
end

#updateObject



29
30
31
32
# File 'app/controllers/gaku/admin/commute_method_types_controller.rb', line 29

def update
  @commute_method_type.update(commute_method_type_params)
  respond_with @commute_method_type
end