diff options
author | Kushal Pandya <kushalspandya@gmail.com> | 2019-08-22 10:59:22 +0300 |
---|---|---|
committer | Kushal Pandya <kushalspandya@gmail.com> | 2019-08-22 10:59:22 +0300 |
commit | 7b5708d1d944547dfea9bc8b6b8e1c6c6e22901b (patch) | |
tree | 4ca58265c0f350e8e22f3c62e2cd85899dab169d /lib | |
parent | 11fd6bdf9972a9a890beb58ba48ebf2afe7d993c (diff) | |
parent | cf88f9dda13d15ab7f773f57c6e844691fd1a496 (diff) |
Merge branch 'ee-2502-refactor-ee-app-assets-javascripts-approvals-components-approvers_select-vue-to-remove-approverusers' into 'master'
Add a new method to `Api.js`: `projectUsers`
See merge request gitlab-org/gitlab-ce!31801
Diffstat (limited to 'lib')
-rw-r--r-- | lib/api/projects.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/api/projects.rb b/lib/api/projects.rb index 996205d4b7b..3073c14b341 100644 --- a/lib/api/projects.rb +++ b/lib/api/projects.rb @@ -489,11 +489,13 @@ module API end params do optional :search, type: String, desc: 'Return list of users matching the search criteria' + optional :skip_users, type: Array[Integer], desc: 'Filter out users with the specified IDs' use :pagination end get ':id/users' do users = DeclarativePolicy.subject_scope { user_project.team.users } users = users.search(params[:search]) if params[:search].present? + users = users.where_not_in(params[:skip_users]) if params[:skip_users].present? present paginate(users), with: Entities::UserBasic end |