commit | author | age
|
48e9c1
|
1 |
/* |
T |
2 |
* vcard_attachments plugin script |
|
3 |
* @version @package_version@ |
|
4 |
*/ |
|
5 |
function plugin_vcard_save_contact(mime_id) |
|
6 |
{ |
|
7 |
var lock = rcmail.set_busy(true, 'loading'); |
3c32f3
|
8 |
rcmail.http_post('plugin.savevcard', { _uid: rcmail.env.uid, _mbox: rcmail.env.mailbox, _part: mime_id }, lock); |
A |
9 |
|
48e9c1
|
10 |
return false; |
T |
11 |
} |
|
12 |
|
|
13 |
function plugin_vcard_insertrow(data) |
|
14 |
{ |
|
15 |
var ctype = data.row.ctype; |
|
16 |
if (ctype == 'text/vcard' || ctype == 'text/x-vcard' || ctype == 'text/directory') { |
|
17 |
$('#rcmrow'+data.uid+' > td.attachment').html('<img src="'+rcmail.env.vcard_icon+'" alt="" />'); |
|
18 |
} |
|
19 |
} |
|
20 |
|
|
21 |
if (window.rcmail && rcmail.gui_objects.messagelist) { |
|
22 |
rcmail.addEventListener('insertrow', function(data, evt) { plugin_vcard_insertrow(data); }); |
|
23 |
} |