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
c1583c6d
Commit
c1583c6d
authored
Aug 19, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Find issues and Mr by iid in controller
parent
2e5481b7
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
3 deletions
+3
-3
app/controllers/projects/issues_controller.rb
app/controllers/projects/issues_controller.rb
+1
-1
app/controllers/projects/merge_requests_controller.rb
app/controllers/projects/merge_requests_controller.rb
+1
-1
app/controllers/projects_controller.rb
app/controllers/projects_controller.rb
+1
-1
No files found.
app/controllers/projects/issues_controller.rb
View file @
c1583c6d
...
...
@@ -91,7 +91,7 @@ class Projects::IssuesController < Projects::ApplicationController
protected
def
issue
@issue
||=
@project
.
issues
.
find
(
params
[
:id
])
@issue
||=
@project
.
issues
.
find
_by_iid!
(
params
[
:id
])
end
def
authorize_modify_issue!
...
...
app/controllers/projects/merge_requests_controller.rb
View file @
c1583c6d
...
...
@@ -132,7 +132,7 @@ class Projects::MergeRequestsController < Projects::ApplicationController
end
def
merge_request
@merge_request
||=
@project
.
merge_requests
.
find
(
params
[
:id
])
@merge_request
||=
@project
.
merge_requests
.
find
_by_iid!
(
params
[
:id
])
end
def
authorize_modify_merge_request!
...
...
app/controllers/projects_controller.rb
View file @
c1583c6d
...
...
@@ -104,7 +104,7 @@ class ProjectsController < Projects::ApplicationController
def
autocomplete_sources
@suggestions
=
{
emojis:
Emoji
.
names
,
issues:
@project
.
issues
.
select
([
:id
,
:title
,
:description
]),
issues:
@project
.
issues
.
select
([
:i
i
d
,
:title
,
:description
]),
members:
@project
.
team
.
members
.
sort_by
(
&
:username
).
map
{
|
user
|
{
username:
user
.
username
,
name:
user
.
name
}
}
}
...
...
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