2012-09-14 05:05:37 +02:00
|
|
|
- unless @notes.blank?
|
2012-10-30 21:55:51 +01:00
|
|
|
- new_note_ids = @notes.map(&:id)
|
2012-09-14 05:05:37 +02:00
|
|
|
- if loading_more_notes?
|
|
|
|
:plain
|
2012-10-30 21:55:51 +01:00
|
|
|
NoteList.appendMoreNotes(#{new_note_ids}, "#{escape_javascript(render 'notes/notes')}");
|
2012-09-14 05:05:37 +02:00
|
|
|
|
|
|
|
- elsif loading_new_notes?
|
|
|
|
:plain
|
2012-10-30 21:55:51 +01:00
|
|
|
NoteList.replaceNewNotes(#{new_note_ids}, "#{escape_javascript(render 'notes/notes')}");
|
2012-09-14 05:05:37 +02:00
|
|
|
|
|
|
|
- else
|
|
|
|
:plain
|
2012-10-30 21:55:51 +01:00
|
|
|
NoteList.setContent(#{new_note_ids}, "#{escape_javascript(render 'notes/notes')}");
|
2012-09-14 05:05:37 +02:00
|
|
|
|
|
|
|
- else
|
|
|
|
- if loading_more_notes?
|
|
|
|
:plain
|
|
|
|
NoteList.finishedLoadingMore();
|