Skip to content

Instantly share code, notes, and snippets.

@kauffmanes
Created August 15, 2017 16:59
Show Gist options
  • Save kauffmanes/435efcbaa1b985ada920c61244bbec76 to your computer and use it in GitHub Desktop.
Save kauffmanes/435efcbaa1b985ada920c61244bbec76 to your computer and use it in GitHub Desktop.
Submit function
$scope.submit = function () {
//Validation/parsing of input could go here
//Make service call
$http({
method: 'POST',
url: '/forms',
data: $scope.formData
}).then(function (res) {
//success handler
})['function'](function (err) {
//error handler
}) ;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment