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
20e009a4
Commit
20e009a4
authored
Sep 14, 2012
by
Riyad Preukschas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update diff comments order and rendering
parent
e802d009
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
4 deletions
+4
-4
app/views/commits/_text_file.html.haml
app/views/commits/_text_file.html.haml
+2
-2
app/views/notes/_create_common.js.haml
app/views/notes/_create_common.js.haml
+1
-1
app/views/notes/_per_line_show.html.haml
app/views/notes/_per_line_show.html.haml
+1
-1
No files found.
app/views/commits/_text_file.html.haml
View file @
20e009a4
...
...
@@ -18,9 +18,9 @@
%td
.line_content
{
class:
"noteable_line #{type} #{line_code}"
,
"line_code"
=>
line_code
}=
raw
"
#{
line
}
"
-
if
@comments_allowed
-
comments
=
@line_notes
.
select
{
|
n
|
n
.
line_code
==
line_code
}.
sort_by
(
&
:created_at
)
.
reverse
-
comments
=
@line_notes
.
select
{
|
n
|
n
.
line_code
==
line_code
}.
sort_by
(
&
:created_at
)
-
unless
comments
.
empty?
-
comments
.
each_with_index
do
|
note
,
i
|
=
render
"notes/reply_button"
,
line_code:
line_code
if
i
.
zero?
=
render
"notes/per_line_show"
,
note:
note
-
@line_notes
.
reject!
{
|
n
|
n
==
note
}
=
render
"notes/reply_button"
,
line_code:
line_code
app/views/notes/_create_common.js.haml
View file @
20e009a4
...
...
@@ -9,5 +9,5 @@
-
else
:plain
$(".note-form-holder").replaceWith("
#{
escape_javascript
(
render
(
'form'
)
)
}
");
$(".note-form-holder").replaceWith("
#{
escape_javascript
(
render
'form'
)
}
");
app/views/notes/_per_line_show.html.haml
View file @
20e009a4
%tr
.line_notes_row
%td
{
colspan:
3
}
%ul
=
render
partial:
"notes/show"
,
locals:
{
note:
note
}
=
render
"notes/show"
,
note:
note
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