rails 4 using strong parameters with no controller -
rails 4: i'm coming rails 3.2.x , have question. how can use strong parameter no controller.
i have model:
track (the 1 has controller ) has_many :tracksegments, :dependent => :destroy has_many :points, :through => :tracksegments tracksegment belongs_to :track has_many :points, :dependent => :destroy points belongs_to :tracksegment
track 1 has controller has strong parameters.
i want know can put parameters belongs "tracksegment" , "points" in rails 3.x it's direct in model in rails 4 have no controller them.
you permit parameters whichever controller sending them through. sounds sending them through track controller, if add them there.
see question how permit nested params rails 4 - strong parameters - nested objects
Comments
Post a Comment