From fd1e009c8230f34e7211df6a9cdfb2629768d69f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Barrag=C3=A1n=20Merino?= Date: Sun, 13 Jul 2014 16:26:02 +0200 Subject: [PATCH] Auth service now return invitations --- app/coffee/modules/auth.coffee | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/coffee/modules/auth.coffee b/app/coffee/modules/auth.coffee index 47036061..b01534ef 100644 --- a/app/coffee/modules/auth.coffee +++ b/app/coffee/modules/auth.coffee @@ -28,9 +28,9 @@ module = angular.module("taigaAuth", ["taigaResources"]) ############################################################################# class AuthService extends taiga.Service - @.$inject = ["$rootScope", "$tgStorage", "$tgModel", "$tgHttp", "$tgUrls"] + @.$inject = ["$rootScope", "$tgStorage", "$tgModel", "$tgResources", "$tgHttp", "$tgUrls"] - constructor: (@rootscope, @storage, @model, @http, @urls) -> + constructor: (@rootscope, @storage, @model, @rs, @http, @urls) -> super() getUser: -> @@ -108,6 +108,8 @@ class AuthService extends taiga.Service return @http.post(url, data) + getInvitation: (token) -> + return @rs.invitations.get(token) # acceptInvitiationWithNewUser: (username, email, password, token) -> # url = @urls.resolve("auth-register")