1
0
mirror of https://github.com/Foltik/Shimapan synced 2024-11-10 23:53:31 -05:00
shimapan/public/js/components/RegisterComp.js
2017-10-11 12:55:46 -04:00

17 lines
498 B
JavaScript

function RegisterController($scope, AuthService) {
$scope.register = function() {
AuthService.register({
username: $scope.username,
password: $scope.password,
invite: $scope.invite
}).then(function() {
alert('Registered');
});
};
}
angular.module('RegisterComp', ['AuthSvc']).component('registerComponent', {
templateUrl: '/views/register-form.html',
controller: RegisterController,
controllerAs: 'vm'
});