aboutsummaryrefslogtreecommitdiffstats
path: root/data/rhlib/addAttachmentRow.js
diff options
context:
space:
mode:
Diffstat (limited to 'data/rhlib/addAttachmentRow.js')
-rw-r--r--data/rhlib/addAttachmentRow.js15
1 files changed, 7 insertions, 8 deletions
diff --git a/data/rhlib/addAttachmentRow.js b/data/rhlib/addAttachmentRow.js
index 9baa373..850d417 100644
--- a/data/rhlib/addAttachmentRow.js
+++ b/data/rhlib/addAttachmentRow.js
@@ -5,7 +5,7 @@
// FIXME resp is JSON, not XML anymore
function addAttachmentCallback(resp) {
var newAttachID = parseInt(
- resp.params.param.value.array.data.value.int, 10);
+ resp.params.param.value.array.ids.value.int, 10);
// FIXME callback.call(param, newAttachID, data.length);
}
@@ -42,14 +42,13 @@ function addAttachment(data, callback, param) {
}
var params = {
- id : getBugNo(),
- description : titleParsedAttachment,
- filename : "parsed-backtrace.txt",
- contenttype : "text/plain",
- data : window.btoa(data),
- nomail : true
+ ids : [getBugNo()],
+ summary : titleParsedAttachment,
+ file_name : "parsed-backtrace.txt",
+ content_type : "text/plain",
+ data : window.btoa(data)
};
- makeJSONRPCCall("bugzilla.addAttachment", params, addAttachmentCallback);
+ makeJSONRPCCall("Bug.add_attachment", params, addAttachmentCallback);
reqCounter++;
}