Home Pass id to new create form (but not through URL) - rails
Reply: 0

Pass id to new create form (but not through URL) - rails

fragg3d
1#
fragg3d Published in 2018-01-12 17:00:33Z

I used the following advice to set up new_invoice_path in my app: https://stackoverflow.com/a/14570788

How can I (using the outlined scenario in the question/answer I linked to above) make it so that when a user clicks a link to create a new invoice for a specific account the account_id passes to the form but does not show up in the URL?

I view the current solution (pass account_id to form via URL) as problematic because...

  1. Someone could easily modify the URL and start creating invoices in different accounts.
  2. It looks sloppy (especially if you start trying to pass things other than just account_id)
You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.304348 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO