Skip to content
Snippets Groups Projects

Project users api

Merged gitlab-qa-bot requested to merge github/fork/miks/project_users_api into master

Created by: miks

Fix #1379 (closed)

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Unable to load the diff
  • Created by: rspeicher

    These don't go here. They should be in a before block, or better yet make them lets and lose the instance variables.

    This is why the spec/requests/api/users spec is failing.

    By Administrator on 2012-09-08T17:55:19 (imported from GitLab project)

    By Administrator on 2012-09-08T17:55:19 (imported from GitLab)

  • gitlab-qa-bot
  • Unable to load the diff
    • Created by: NARKOZ

      new project name

      ?

      By Administrator on 2012-09-08T17:55:19 (imported from GitLab project)

      By Administrator on 2012-09-08T17:55:19 (imported from GitLab)

  • Created by: AlexDenisov

    Maybe make sense to do this more RESTful? Like

    GET :id/users - list of users
    POST :id/users - add user(s)
    PUT :id/users - change access level for existed user(s)
    DELETE :id/users - remove user(s) from team

    What do you think about this? I think it would be more clean and RESTful.

    By Administrator on 2012-09-06T13:48:22 (imported from GitLab project)

    By Administrator on 2012-09-06T13:48:22 (imported from GitLab)

  • Created by: miks

    ok, I will make it.

    By Administrator on 2012-09-06T13:46:57 (imported from GitLab project)

    By Administrator on 2012-09-06T13:46:57 (imported from GitLab)

  • gitlab-qa-bot
  • 20 20
    21 21 delegate :name, :email, to: :user, prefix: true
    22 22
    23 def self.bulk_delete(project, user_ids)
    24 UsersProject.transaction do
    25 UsersProject.where(:user_id => user_ids, :project_id => project.id).each do |users_project|
    26 users_project.delete
    • Created by: dzaporozhets

      Delete will not trigger update repository callback. And user still have access to repo via ssh

      By Administrator on 2012-09-08T17:55:19 (imported from GitLab project)

      By Administrator on 2012-09-08T17:55:19 (imported from GitLab)

  • Created by: dzaporozhets

    Restful is much better :smile:

    By Administrator on 2012-09-07T06:00:44 (imported from GitLab project)

    By Administrator on 2012-09-07T06:00:44 (imported from GitLab)

  • Created by: miks

    Does permission check to update projects users happen in model or I need to implement it?

    By Administrator on 2012-09-07T06:46:43 (imported from GitLab project)

    By Administrator on 2012-09-07T06:46:43 (imported from GitLab)

  • Created by: dzaporozhets

    i think you need to call project.update_repository after succesfull transaction

    By Administrator on 2012-09-07T06:56:32 (imported from GitLab project)

    By Administrator on 2012-09-07T06:56:32 (imported from GitLab)

  • Created by: miks

    I need to check whether user has ability to manage users thought API, what is the best way to achieve it? Without permissions check user with "guest" access can change levels/delete/add other users. Also, for now guest user thought API can delete/modify snippets, there is no ability check.

    By Administrator on 2012-09-08T14:36:02 (imported from GitLab project)

    By Administrator on 2012-09-08T14:36:02 (imported from GitLab)

  • gitlab-qa-bot
  • 20 20
    21 21 delegate :name, :email, to: :user, prefix: true
    22 22
    23 def self.bulk_delete(project, user_ids)
    24 UsersProject.transaction do
    25 UsersProject.where(:user_id => user_ids, :project_id => project.id).each do |users_project|
    26 users_project.delete
    • Created by: miks

      Delete is called within delete_users_ids_from_team from roles/team.rb

      By Administrator on 2012-09-08T17:55:19 (imported from GitLab project)

      By Administrator on 2012-09-08T17:55:19 (imported from GitLab)

  • Created by: dzaporozhets

    Merged. Thank you

    By Administrator on 2012-09-09T08:19:12 (imported from GitLab project)

    By Administrator on 2012-09-09T08:19:12 (imported from GitLab)

  • Created by: miks

    Sorry for repeating, but what to do about permissions check?

    By Administrator on 2012-09-09T08:30:29 (imported from GitLab project)

    By Administrator on 2012-09-09T08:30:29 (imported from GitLab)

  • Created by: dzaporozhets

    Oh sorry. Missed you comment. I will handle it today

    By Administrator on 2012-09-10T05:41:40 (imported from GitLab project)

    By Administrator on 2012-09-10T05:41:40 (imported from GitLab)

  • Created by: dzaporozhets

    @miks b565f334

    By Administrator on 2012-09-10T06:07:02 (imported from GitLab project)

    By Administrator on 2012-09-10T06:07:02 (imported from GitLab)

  • Created by: miks

    :thumbsup:

    By Administrator on 2012-09-10T06:10:45 (imported from GitLab project)

    By Administrator on 2012-09-10T06:10:45 (imported from GitLab)

  • Created by: coveralls

    Coverage Status

    Changes Unknown when pulling ba584c7d on miks:project_users_api into * on gitlabhq:master*.

    By Administrator on 2013-11-20T23:13:03 (imported from GitLab project)

    By Administrator on 2013-11-20T23:13:03 (imported from GitLab)

  • Please register or sign in to reply
    Loading