Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #9 from bigbangtechnology/terminating-agency-learn…

…ers-20

Added user find
  • Loading branch information...
commit 755095a6d2129197bf69c3569e9b1512e4c534de 2 parents 4ff8134 + 17496f7
Paul Kalupnieks authored
Showing with 7 additions and 1 deletion.
  1. +7 −1 lib/woopy/account.rb
View
8 lib/woopy/account.rb
@@ -19,6 +19,12 @@ def employments
end
end
+ def find_user(user_id)
+ user_json = Account.get("#{self.id}/users/#{user_id}")
+
+ User.new(user_json, true)
+ end
+
def find_employment(user)
employment_json = Account.get("#{self.id}/users/#{user.id}/employment")
@@ -31,7 +37,7 @@ def grant_role(user, roles)
end
private
-
+
def create_employment(json)
Employment.new(json, true)
end
Please sign in to comment.
Something went wrong with that request. Please try again.