Added method property to item so that PUT can be used as well as POST.
Updated status code check so that 201 (Created) status code is a success.
updated event listener to use passed in scope instead of root scope.