Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Fix to # polymorphic-association ajax request. #1229
Relating to the following issue
Which boils down to polymorphic-association not updating via ajax correctly.
The polymorphic-association junk of code in ra.widgets.coffee was calling on line 123
$(data).each (i, el) ->
on the returned ajax object, ie data. Only issue was that the data was not the array. Rather the array was at data.main. So the issue was fixed for me when i changed the above to
$(data.main).each (i, el) ->
which seems to solve the issue.
I hope this helps, and let me know if I didn't explain something properly.
I couldn't confirm the issue you're attempting to fix.
I've tested by using Chrome, Safari and Firefox, and verified that the content of
And if possible, next time you submit an issue, please precompose all the description so repo collabs won't get a bunch of notifications :)
Sorry I didn't know github sent notifications for edits. Sorry about that ;_;. Will be more careful in the future.
I tested it on the latest Chrome, Firefox, and Safari on Mac OSX 10.7.4. All showed the same issue.
What OS and browser did you use? If I know that then I can confirm if its browser related or some how related to my set up. The later seeming more likely now then ever unfortunately...
Once again here is my gemfile.lock for the record. Just in case someone else has run into some type of conflict out there.
At least I didn't do something stupid with the setup of my app that would have been causing it. Sorry again.