Skip to content

Instantly share code, notes, and snippets.

@dgg
Created August 30, 2013 11:05
Show Gist options
  • Select an option

  • Save dgg/6388754 to your computer and use it in GitHub Desktop.

Select an option

Save dgg/6388754 to your computer and use it in GitHub Desktop.
Model binding dynamic collections. IV makeDeletable
DGON_DOTNET.ClientInteraction =
{
makeDeletable: function (tableSelector, options) {
options = optionsWithDefaults(options, {
deleteSelector: '.trash',
deletedSelector: '.data-delete',
});
$(tableSelector).delegate(
options.deleteSelector,
'click',
function (evt) {
deleteRow(evt.target, options);
});
},
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment