Rename 'notes/per_line_show' partial to 'notes/per_line_note'

This commit is contained in:
Riyad Preukschas 2012-09-14 05:21:58 +02:00
parent dd1b3177c9
commit c6d71b7b8e
3 changed files with 3 additions and 3 deletions

View file

@ -21,6 +21,6 @@
- comments = @line_notes.select { |n| n.line_code == line_code }.sort_by(&:created_at) - comments = @line_notes.select { |n| n.line_code == line_code }.sort_by(&:created_at)
- unless comments.empty? - unless comments.empty?
- comments.each_with_index do |note, i| - comments.each_with_index do |note, i|
= render "notes/per_line_show", note: note = render "notes/per_line_note", note: note
- @line_notes.reject!{ |n| n == note } - @line_notes.reject!{ |n| n == note }
= render "notes/per_line_reply_button", line_code: line_code = render "notes/per_line_reply_button", line_code: line_code

View file

@ -12,8 +12,8 @@
var trEl = $(".#{note.line_code}").parent(); var trEl = $(".#{note.line_code}").parent();
// ... and insert the note and the reply button after it // ... and insert the note and the reply button after it
trEl.after("#{escape_javascript(render "notes/per_line_reply_button", line_code: note.line_code)}"); trEl.after("#{escape_javascript(render "notes/per_line_reply_button", line_code: note.line_code)}");
trEl.after("#{escape_javascript(render "notes/per_line_show", note: note)}"); trEl.after("#{escape_javascript(render "notes/per_line_note", note: note)}");
} else { } else {
// instert new note before reply button // instert new note before reply button
trRpl.before("#{escape_javascript(render "notes/per_line_show", note: note)}"); trRpl.before("#{escape_javascript(render "notes/per_line_note", note: note)}");
} }