Method: PassTypesController#create
- Defined in:
- app/controllers/pass_types_controller.rb
#create ⇒ Object
22 23 24 25 26 27 28 29 30 |
# File 'app/controllers/pass_types_controller.rb', line 22 def create @pass_type = PassType.new(params[:pass_type]) @pass_type.organization = current_organization unless @pass_type.save flash[:error] = @pass_type.errors..to_sentence render "new" and return end redirect_to pass_types_path end |