I’m having a problem wrangling nested routes and I’m not entirely sure how to use them in this particular scenario. The relationship I’m describing is that every User attaches a Proof to each PCI Requirement. I have a feeling that nesting Proof inside Requirement is the proper way to go. However, by going that route, we have to implement a hidden_field for user_id. But I feel using a hidden_field is wrong also. Then I thought, ok, what about nesting all the routes to do something like
form_for [@user, @proof, @requirement] but Rails guides says that’s a no no.
I’m not entirely sure of the best pattern to use for this. I’d really appreciate some advice!
Here’s the PR where I’m having issues wrangling this