Class: Crowdblog::Admin::AssetsController
- Inherits:
-
BaseController
- Object
- ApplicationController
- Crowdblog::ApplicationController
- BaseController
- Crowdblog::Admin::AssetsController
- Defined in:
- app/controllers/crowdblog/admin/assets_controller.rb
Instance Method Summary collapse
Methods inherited from Crowdblog::ApplicationController
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Crowdblog::ApplicationController
Instance Method Details
#create ⇒ Object
9 10 11 12 13 14 15 16 |
# File 'app/controllers/crowdblog/admin/assets_controller.rb', line 9 def create @post = Post.find(params[:post_id]) asset = @post.assets.build asset. = params['attachment'] asset.save! render json: asset end |