Module: RubyLokaliseApi::Rest::TeamUserGroups
- Included in:
- Client
- Defined in:
- lib/ruby_lokalise_api/rest/team_user_groups.rb
Instance Method Summary collapse
-
#add_projects_to_group(team_id, group_id, project_ids) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Adds projects to the given group.
-
#add_users_to_group(team_id, group_id, users_ids) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Adds users to the given group.
-
#create_team_user_group(team_id, params) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Creates team user group.
-
#destroy_team_user_group(team_id, group_id) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Deletes team user group from the given team.
-
#remove_projects_from_group(team_id, group_id, project_ids) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Removes projects from the given group.
-
#remove_users_from_group(team_id, group_id, users_ids) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Removes users from the given group.
-
#team_user_group(team_id, group_id) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Returns team user from the given team.
-
#team_user_groups(team_id, params = {}) ⇒ RubyLokaliseApi::Collection::TeamUserGroup<RubyLokaliseApi::Resources::TeamUserGroup>
Returns all team user groups for the given team.
-
#update_team_user_group(team_id, group_id, params) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Updates team user group for the given team.
Instance Method Details
#add_projects_to_group(team_id, group_id, project_ids) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Adds projects to the given group
63 64 65 66 67 |
# File 'lib/ruby_lokalise_api/rest/team_user_groups.rb', line 63 def add_projects_to_group(team_id, group_id, project_ids) c_r RubyLokaliseApi::Resources::TeamUserGroup, :update, [team_id, group_id, 'projects', 'add'], project_ids, :projects, [team_id, group_id] end |
#add_users_to_group(team_id, group_id, users_ids) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Adds users to the given group
89 90 91 92 93 |
# File 'lib/ruby_lokalise_api/rest/team_user_groups.rb', line 89 def add_users_to_group(team_id, group_id, users_ids) c_r RubyLokaliseApi::Resources::TeamUserGroup, :update, [team_id, group_id, 'members', 'add'], users_ids, :users, [team_id, group_id] end |
#create_team_user_group(team_id, params) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Creates team user group
31 32 33 |
# File 'lib/ruby_lokalise_api/rest/team_user_groups.rb', line 31 def create_team_user_group(team_id, params) c_r RubyLokaliseApi::Resources::TeamUserGroup, :create, team_id, params end |
#destroy_team_user_group(team_id, group_id) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Deletes team user group from the given team
52 53 54 |
# File 'lib/ruby_lokalise_api/rest/team_user_groups.rb', line 52 def destroy_team_user_group(team_id, group_id) c_r RubyLokaliseApi::Resources::TeamUserGroup, :destroy, [team_id, group_id] end |
#remove_projects_from_group(team_id, group_id, project_ids) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Removes projects from the given group
76 77 78 79 80 |
# File 'lib/ruby_lokalise_api/rest/team_user_groups.rb', line 76 def remove_projects_from_group(team_id, group_id, project_ids) c_r RubyLokaliseApi::Resources::TeamUserGroup, :update, [team_id, group_id, 'projects', 'remove'], project_ids, :projects, [team_id, group_id] end |
#remove_users_from_group(team_id, group_id, users_ids) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Removes users from the given group
102 103 104 105 106 |
# File 'lib/ruby_lokalise_api/rest/team_user_groups.rb', line 102 def remove_users_from_group(team_id, group_id, users_ids) c_r RubyLokaliseApi::Resources::TeamUserGroup, :update, [team_id, group_id, 'members', 'remove'], users_ids, :users, [team_id, group_id] end |
#team_user_group(team_id, group_id) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Returns team user from the given team
22 23 24 |
# File 'lib/ruby_lokalise_api/rest/team_user_groups.rb', line 22 def team_user_group(team_id, group_id) c_r RubyLokaliseApi::Resources::TeamUserGroup, :find, [team_id, group_id] end |
#team_user_groups(team_id, params = {}) ⇒ RubyLokaliseApi::Collection::TeamUserGroup<RubyLokaliseApi::Resources::TeamUserGroup>
Returns all team user groups for the given team
12 13 14 |
# File 'lib/ruby_lokalise_api/rest/team_user_groups.rb', line 12 def team_user_groups(team_id, params = {}) c_r RubyLokaliseApi::Collections::TeamUserGroup, :all, team_id, params end |
#update_team_user_group(team_id, group_id, params) ⇒ RubyLokaliseApi::Resources::TeamUserGroup
Updates team user group for the given team
42 43 44 |
# File 'lib/ruby_lokalise_api/rest/team_user_groups.rb', line 42 def update_team_user_group(team_id, group_id, params) c_r RubyLokaliseApi::Resources::TeamUserGroup, :update, [team_id, group_id], params end |