0

This is weird! I have an html.erb form, and in this form I have a button that links the user to an action in another controller (finance_extensions) to print pdf. This is working great, but the thing is that I need my own action that I'm using in the current controller (parent_wise_fee_payments), so I added this same action + view file to my controller and I changed this in pay_all_fees.html.erb:

<%= link_to "► #{t('print_receipt')}",

                  {:controller => "finance_extensions", :action => "pay_all_fees_receipt_pdf", :id => student.id}, :target => '_blank', :class => 'user_button' %>

to this:

  <%= link_to "► #{t('print_receipt')}",

                      {:controller => "parent_wise_fee_payments", :action => "pay_all_fees_receipt_pdf", :id => student.id}, :target => '_blank', :class => 'user_button' %>

This causes the button to disapper. I also tried adding a test action and view in my controller, and tried removing " :controller" but it didn't solve my problem.

Is this weird or am I missing something here?!

1
  • Does the HTML for the button show up when you do a "view source" from your browser? Did anything else at all change in the code in areas that might be related to this change in line of code? Commented Aug 7, 2015 at 12:35

1 Answer 1

1

Did you add your new action to the auth file in the config??

Sign up to request clarification or add additional context in comments.

1 Comment

Omg I forgot!! It's working now, thank you soooooooo much!!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.