|
But it isn't. No AJAX. No RJS. Nothing showing up in FireBug. Just a
silly _javascript_ bit that hides it and sets the value to "". It seems
that they intentionally used this alternative method
instead of instead of AJAX. Perhaps because it doesn't delete
the records until you update the list. The script: <script> function deleteItem(id) { document.getElementById('item_' + id + '_content').value = ''; document.getElementById('item_' + id).style.display = 'none'; } </script>Then something in the model or controller that does a bit o' magic to figure out if it has been deleted, then removes from the database. Something like: Item.update_or_delete(params....) I was just wondering if anybody knew if that existed. I tried a before_save callback to delete empty objects, but it wasn't working. -Nathan Patrick Crowley wrote: Yeah, exactly. |
_______________________________________________ Sdruby mailing list [email protected] http://lists.sdruby.com/mailman/listinfo/sdruby
