summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/notes.js
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-11-29 14:46:40 +0200
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-11-29 14:46:40 +0200
commit596e64e5d7a51dbd03bceeb3e6e626781ef34134 (patch)
treee1695669f07a8c87c402e8f60d8ecd1eb7ec7467 /app/assets/javascripts/notes.js
parent071de30f80ea471c48f52ff1f5d728089b75a8c0 (diff)
downloadgitlab-ce-596e64e5d7a51dbd03bceeb3e6e626781ef34134.tar.gz
Drop rjs from Notes#index
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/assets/javascripts/notes.js')
-rw-r--r--app/assets/javascripts/notes.js9
1 files changed, 6 insertions, 3 deletions
diff --git a/app/assets/javascripts/notes.js b/app/assets/javascripts/notes.js
index defbf81f580..e39bfc0f792 100644
--- a/app/assets/javascripts/notes.js
+++ b/app/assets/javascripts/notes.js
@@ -6,7 +6,7 @@ var NoteList = {
target_type: null,
init: function(tid, tt, path) {
- NoteList.notes_path = path + ".js";
+ NoteList.notes_path = path + ".json";
NoteList.target_id = tid;
NoteList.target_type = tt;
NoteList.target_params = "target_type=" + NoteList.target_type + "&target_id=" + NoteList.target_id;
@@ -411,7 +411,10 @@ var NoteList = {
data: NoteList.target_params,
complete: function(){ $('.js-notes-busy').removeClass("loading")},
beforeSend: function() { $('.js-notes-busy').addClass("loading") },
- dataType: "script"
+ success: function(data) {
+ NoteList.setContent(data.html);
+ },
+ dataType: "json"
});
},
@@ -419,7 +422,7 @@ var NoteList = {
* Called in response to getContent().
* Replaces the content of #notes-list with the given html.
*/
- setContent: function(newNoteIds, html) {
+ setContent: function(html) {
$("#notes-list").html(html);
},