diff --git a/app/controllers/store_controller.rb b/app/controllers/store_controller.rb index 5379ba9df..04ed30b1f 100644 --- a/app/controllers/store_controller.rb +++ b/app/controllers/store_controller.rb @@ -327,7 +327,6 @@ def referer_target redirect_target = case params[:referer].to_s when 'donate' then quick_donate_path(:account_code_string => params[:account_code_string]) # no @customer assumed - when 'donate_to_fund' then donate_to_fund_path(params[:account_code_id], @customer) when 'subscribe' then store_subscribe_path(@customer,promo_code_args) when 'index' then store_path(@customer, promo_code_args.merge(:what => params[:what], :showdate_id => params[:showdate_id])) else store_path(@customer,promo_code_args) diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 7925372aa..c331ccfd4 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -46,7 +46,7 @@ def display_customer_actions? :customers => [:show, :edit, :change_password_for, :change_secret_question], :vouchers => [:index], :orders => [:index], - :store => [:index, :subscribe, :donate, :donate_to_fund, :shipping_address, :checkout] + :store => [:index, :subscribe, :donate, :shipping_address, :checkout] } ! @customer.try(:new_record?) && (allowed_actions[controller.controller_name.to_sym] || {}).include?(action_name.to_sym) diff --git a/app/views/options/index.html.haml b/app/views/options/index.html.haml index 1d6baaf28..ec731cddc 100644 --- a/app/views/options/index.html.haml +++ b/app/views/options/index.html.haml @@ -36,8 +36,6 @@ default_retail_account_code | default_donation_account_code | default_donation_account_code_with_subscriptions | - quick_donation_banner | - quick_donation_explanation | quick_donation_redirect | donation_ack_from | ) | diff --git a/app/views/store/donate_to_fund.html.haml b/app/views/store/donate_to_fund.html.haml deleted file mode 100644 index a8d63a07d..000000000 --- a/app/views/store/donate_to_fund.html.haml +++ /dev/null @@ -1,29 +0,0 @@ -= set_active_tab '#t_store_donate' -#store - #donation_panel - = form_tag process_cart_path(@customer) do - - if @gAdminDisplay - %h1.text-center Record Donation - %label{:for => :account_code_id} Fund or Account: - = select_tag 'account_code_id', options_from_collection_for_select(AccountCode.all, :id, :name_with_code, @account_code.id) - - else - %h1.text-center Donation to #{@account_code.name} - - if @account_code.description - %p.text-center= @account_code.description - = hidden_field_tag 'account_code_id', @account_code.id - - - unless @account_code.donation_prompt.blank? - %label{:for => :donation_comments}= @account_code.donation_prompt - = text_field_tag 'donation_comments', '', :size => 40 - %br - %br - - %label{:for => :donation} Your tax-deductible donation - = text_field_tag 'donation', '', :size => 5, :class => 'currency' - \.00 - %br - %br - = hidden_field_tag 'referer', 'donate_to_fund' - = submit_tag 'CONTINUE >>', {:id => 'submit', :class => 'btn btn-success'} - %span#nextstep to Billing Information - diff --git a/config/locales/en.option_descriptions.yml b/config/locales/en.option_descriptions.yml index d5a5e0cd4..b569bb745 100644 --- a/config/locales/en.option_descriptions.yml +++ b/config/locales/en.option_descriptions.yml @@ -107,17 +107,6 @@ en: Auto-generated confirmation emails for online donations will appear to be signed by this person. Example: "Bob Jones, Development Chair" - quick_donation_banner: > - - The banner text that appears at the top of the "donate instantly" - (donate by credit card without logging in) page. - - quick_donation_explanation: > - - Explanatory text that appears on the "donate instantly" page. Basic - HTML is allowed. For example, you could direct patrons who wish to - donate by check to download a form or call the development office. - quick_donation_redirect: > If not blank, the absolute URL to which the patron is redirected after diff --git a/config/routes.rb b/config/routes.rb index 41122a906..fe8b2b212 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -112,7 +112,6 @@ get '/store/(:customer_id)' => 'store#index', :defaults => {:customer_id => nil}, :as => 'store' get '/subscribe/(:customer_id)' => 'store#subscribe', :defaults => {:customer_id => nil}, :as => 'store_subscribe' - # get '/donate_to_fund/:id/(:customer_id)' => 'store#donate_to_fund', :defaults => {:customer_id => nil}, :as => 'donate_to_fund' get '/donate_to_fund/(:id)/(:customer_id)', :defaults => {:customer_id => nil}, to: 'store#donate_to_fund_redirect' get '/store/cancel' => 'store#cancel', :as => 'store_cancel' diff --git a/db/migrate/20240417020007_remove_quick_donation_fields_from_options.rb b/db/migrate/20240417020007_remove_quick_donation_fields_from_options.rb new file mode 100644 index 000000000..f1827df35 --- /dev/null +++ b/db/migrate/20240417020007_remove_quick_donation_fields_from_options.rb @@ -0,0 +1,4 @@ +class RemoveQuickDonationFieldsFromOptions < ActiveRecord::Migration + def change + end +end diff --git a/spec/controllers/store_controller_spec.rb b/spec/controllers/store_controller_spec.rb index 14872ca19..70d576f2c 100644 --- a/spec/controllers/store_controller_spec.rb +++ b/spec/controllers/store_controller_spec.rb @@ -80,10 +80,6 @@ before :each do ; @action = :subscribe ; end it_should_behave_like 'initial visit' end - describe 'to :donate_to_fund' do - before :each do ; @action = :donate_to_fund ; @extras = { id: '2' }; end - it_should_behave_like 'initial visit' - end end describe "on InvalidAuthenticityToken exception" do