mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-12 17:08:16 +01:00
Use readonly tag list for FROM as an example
This commit is contained in:
parent
49ef157e69
commit
35ce67f62b
@ -1616,6 +1616,25 @@ unset($query['actions']);
|
||||
$content['mail_displaybccaddress'] = self::emailAddressToHTML($envelope['BCC'],'',false,true,false);
|
||||
}
|
||||
|
||||
// Set up data for taglist widget(s)
|
||||
foreach(array('SENDER','FROM','TO','CC','BCC') as $field)
|
||||
{
|
||||
foreach($envelope[$field] as $field_data)
|
||||
{
|
||||
$content[$field][] = $field_data['EMAIL'];
|
||||
$sel_options[$field][] = array(
|
||||
// taglist requires these
|
||||
'id' => $field_data['EMAIL'],
|
||||
'label' => $field_data['PERSONAL_NAME'],
|
||||
// Optional
|
||||
'title' => $field_data['RFC822_EMAIL']
|
||||
)
|
||||
// Add all other data, will be preserved & passed to js onclick
|
||||
// Also available in widget.options.select_options
|
||||
+ $field_data;
|
||||
}
|
||||
}
|
||||
|
||||
if (empty($subject)) $subject = lang('no subject');
|
||||
$content['msg'] = (is_array($error_msg)?implode("<br>",$error_msg):$error_msg);
|
||||
$content['mail_displaydate'] = mail_bo::_strtotime($headers['DATE'],'ts',true);
|
||||
|
@ -739,6 +739,14 @@ app.mail = AppJS.extend(
|
||||
//window.open(url,'_blank','dependent=yes,width=100,height=100,scrollbars=yes,status=yes');
|
||||
document.location = url;
|
||||
},
|
||||
|
||||
/**
|
||||
* User clicked an address (FROM, TO, etc)
|
||||
*/
|
||||
address_click: function(DOMNode, tag_info, widget)
|
||||
{
|
||||
console.log(this, arguments);
|
||||
},
|
||||
|
||||
/**
|
||||
* Save a message to filemanager
|
||||
|
@ -6,7 +6,7 @@
|
||||
<vbox class="mailDisplay mailDisplayHeaderSection" width="100%">
|
||||
<hbox class="mailDisplayHeaders" width="100%">
|
||||
<description value="From"/>
|
||||
<html id="mail_displayfromaddress" readonly="true"/>
|
||||
<taglist id="FROM" readonly="true" onclick="app.mail.address_click"/>
|
||||
</hbox>
|
||||
<hbox class="mailDisplayHeaders" width="100%">
|
||||
<description value="on behalf of"/>
|
||||
|
Loading…
Reference in New Issue
Block a user