Class: Omnom::PostsController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- ApplicationController
- Omnom::PostsController
- Defined in:
- app/controllers/omnom/posts_controller.rb
Instance Method Summary collapse
Methods inherited from ApplicationController
Instance Method Details
#update_all ⇒ Object
3 4 5 6 7 8 9 |
# File 'app/controllers/omnom/posts_controller.rb', line 3 def update_all if Post.where(id: params[:ids]).update_all(params[:post]) render json: {success: true} else render json: {success: false}, status: 500 end end |