title: How to use Angular-Xeditable's onBeforeSave / onAfterSave methods with more than $data as parameter
body: <p>When first using Angular-Xeditable with my application, I ran into a problem trying to figure out how to save an x-editable change to an object that was accessed through an ng-repeat loop.</p>
  
  <p>The documentation primarily focuses on using onbeforesave and onaftersave for validation, and while it does show that it can be used to save things, the examples don't show how to pass anything more than $data (or $index) to your onbeforesave/onaftersave method.  The samples show saving something like $scope.person, which is fine if you have one item.</p>
  
  <p>But what if the 3rd person in a list of 30 was edited?  You certainly don't want to have to save them all.  How do you save just the object that was edited instead of everything in the array?</p>