Changeset 6323 for sandbox/webservice/restclient
- Timestamp:
- 05/25/12 18:17:54 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sandbox/webservice/restclient/index.html
r6316 r6323 199 199 $('#attachment_id').prop('disabled',false); 200 200 var attachments = a_response.result.messages[0].msgAttachments; 201 var idxFile = 0; 201 202 for (var j in attachments){ 202 $("#attachment_id").append("<option value='"+attachments[j].pid+"'>"+attachments[j].name+"</option>"); 203 var value = { ID: attachments[j].pid, 204 index: idxFile, 205 name:attachments[j].name, 206 encoding:attachments[j].encoding 207 }; 208 $("#attachment_id").append("<option value='"+$.toJSON(value)+"'>"+attachments[j].name+"</option>"); 209 idxFile++; 203 210 } 204 211 } … … 382 389 var form = document.createElement("form"); 383 390 $(form).attr({"action":_server+"Mail/Attachment","method":"POST"}); 384 391 var attachment = JSON.parse($('#attachment_id').val()); 385 392 var _params = { 386 393 auth: getCookie('auth') != null ? getCookie('auth') : "", 387 394 folderID: $('#folder_id').val(), 388 395 msgID: $('#message_id').val(), 389 attachmentID: $('#attachment_id').val() 396 attachmentID: attachment.ID, 397 attachmentName: attachment.name, 398 attachmentIndex: attachment.index, 399 attachmentEncoding: attachment.encoding 390 400 }; 391 401
Note: See TracChangeset
for help on using the changeset viewer.