Merge pull request #52 from gopesht/fix_supporter_page
fixed supporter page redirect after creation
This commit is contained in:
commit
8f222db0bb
2 changed files with 2 additions and 3 deletions
|
|
@ -11,7 +11,6 @@ class Admin::SupportersController < ApplicationController
|
||||||
def create
|
def create
|
||||||
params[:supporter_registration][:conference_id] = @conference.id
|
params[:supporter_registration][:conference_id] = @conference.id
|
||||||
supporter = SupporterRegistration.create!(params[:supporter_registration])
|
supporter = SupporterRegistration.create!(params[:supporter_registration])
|
||||||
flash[:notice] = "Supporter added"
|
redirect_to(admin_conference_supporters_path(:conference_id => @conference.short_title), :notice => "Supporter added")
|
||||||
render :json => {"status" => "ok"}
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
#new-supporter-dialog
|
#new-supporter-dialog
|
||||||
= semantic_form_for :supporter_registration, :remote => true, :html => {:id => "supporter-add-form"} do |f|
|
= semantic_form_for :supporter_registration, :html => {:id => "supporter-add-form"} do |f|
|
||||||
= f.input :name, :label => "Supporter Name"
|
= f.input :name, :label => "Supporter Name"
|
||||||
= f.input :email, :label => "Supporter Email"
|
= f.input :email, :label => "Supporter Email"
|
||||||
= f.input :supporter_level_id, :as => :select, :collection => @conference.supporter_levels
|
= f.input :supporter_level_id, :as => :select, :collection => @conference.supporter_levels
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue