Class: Manage::StructuresController
- Inherits:
-
BaseController
- Object
- BaseController
- Manage::StructuresController
- Defined in:
- app/controllers/manage/structures_controller.rb
Instance Method Summary collapse
- #create ⇒ Object
- #destroy ⇒ Object
-
#move ⇒ Object
POST /manage/structures/1/move.
- #update ⇒ Object
Instance Method Details
#create ⇒ Object
11 12 13 |
# File 'app/controllers/manage/structures_controller.rb', line 11 def create create!{ manage_structures_path } end |
#destroy ⇒ Object
19 20 21 |
# File 'app/controllers/manage/structures_controller.rb', line 19 def destroy destroy!{ manage_structures_path } end |
#move ⇒ Object
POST /manage/structures/1/move
24 25 26 27 28 29 |
# File 'app/controllers/manage/structures_controller.rb', line 24 def move @structure = Structure.find(params[:id]) @structure.move_by_direction(params[:direction]) respond_with(@structure, :location => manage_structures_path) end |
#update ⇒ Object
15 16 17 |
# File 'app/controllers/manage/structures_controller.rb', line 15 def update update!{ manage_structures_path } end |