Closed cokeito closed 5 years ago
You should use the callbacks documented here: https://github.com/nathanvda/cocoon#callbacks-upon-insert-and-remove-of-items
As a parameter you receive the part of html (the partial) that is about to be or was inserted, for you to manipulate, aka fill in the fields as you wish.
If you need code to explain this, please show us some example code so I can show you.
Closed due to inactivity.
Hello guys! i have an object that have the data that i need to fill on the "new added items" im triggering via jquery the click method to generate a new field with 4 fields, i have the data for the 4 fields already in an object, so how i can fill the data after insert if i dont have an id to fill where i can set the value of the fields.
The help is appreciated!