Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
32965ee4
Commit
32965ee4
authored
Jul 07, 2017
by
Nick Thomas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix merge conflicts in lib/api/projects.rb
parent
d7adcdc9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
27 deletions
+8
-27
lib/api/projects.rb
lib/api/projects.rb
+8
-27
No files found.
lib/api/projects.rb
View file @
32965ee4
...
@@ -71,7 +71,6 @@ module API
...
@@ -71,7 +71,6 @@ module API
optional
:with_merge_requests_enabled
,
type:
Boolean
,
default:
false
,
desc:
'Limit by enabled merge requests feature'
optional
:with_merge_requests_enabled
,
type:
Boolean
,
default:
false
,
desc:
'Limit by enabled merge requests feature'
end
end
<<<<<<<
HEAD
params
:create_params
do
params
:create_params
do
optional
:namespace_id
,
type:
Integer
,
desc:
'Namespace ID for the new project. Default to the user namespace.'
optional
:namespace_id
,
type:
Integer
,
desc:
'Namespace ID for the new project. Default to the user namespace.'
optional
:import_url
,
type:
String
,
desc:
'URL from which the project is imported'
optional
:import_url
,
type:
String
,
desc:
'URL from which the project is imported'
...
@@ -84,40 +83,22 @@ module API
...
@@ -84,40 +83,22 @@ module API
projects
=
projects
.
with_issues_enabled
if
params
[
:with_issues_enabled
]
projects
=
projects
.
with_issues_enabled
if
params
[
:with_issues_enabled
]
projects
=
projects
.
with_merge_requests_enabled
if
params
[
:with_merge_requests_enabled
]
projects
=
projects
.
with_merge_requests_enabled
if
params
[
:with_merge_requests_enabled
]
if
current_user
projects
=
projects
.
includes
(
:route
,
:taggings
,
namespace: :route
)
project_members
=
current_user
.
project_members
group_members
=
current_user
.
group_members
end
options
=
options
.
reverse_merge
(
options
=
options
.
reverse_merge
(
with:
current_user
?
Entities
::
ProjectWithAccess
:
Entities
::
BasicProjectDetails
,
with:
current_user
?
Entities
::
ProjectWithAccess
:
Entities
::
BasicProjectDetails
,
statistics:
params
[
:statistics
],
statistics:
params
[
:statistics
],
project_members:
project_members
,
group_members:
group_members
,
current_user:
current_user
current_user:
current_user
)
)
options
[
:with
]
=
Entities
::
BasicProjectDetails
if
params
[
:simple
]
options
[
:with
]
=
Entities
::
BasicProjectDetails
if
params
[
:simple
]
present
paginate
(
projects
),
options
present
paginate
(
projects
),
options
=======
def
present_projects
(
options
=
{})
projects
=
ProjectsFinder
.
new
(
current_user:
current_user
,
params:
project_finder_params
).
execute
projects
=
reorder_projects
(
projects
)
projects
=
projects
.
with_statistics
if
params
[
:statistics
]
projects
=
projects
.
with_issues_enabled
if
params
[
:with_issues_enabled
]
projects
=
projects
.
with_merge_requests_enabled
if
params
[
:with_merge_requests_enabled
]
if
current_user
projects
=
projects
.
includes
(
:route
,
:taggings
,
namespace: :route
)
project_members
=
current_user
.
project_members
group_members
=
current_user
.
group_members
end
options
=
options
.
reverse_merge
(
with:
current_user
?
Entities
::
ProjectWithAccess
:
Entities
::
BasicProjectDetails
,
statistics:
params
[
:statistics
],
project_members:
project_members
,
group_members:
group_members
,
current_user:
current_user
)
options
[
:with
]
=
Entities
::
BasicProjectDetails
if
params
[
:simple
]
present
paginate
(
projects
),
options
end
>>>>>>>
upstream
/
master
end
end
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment