diff --git a/mail/inc/class.mail_hooks.inc.php b/mail/inc/class.mail_hooks.inc.php index dc46401bed..fd8a131991 100644 --- a/mail/inc/class.mail_hooks.inc.php +++ b/mail/inc/class.mail_hooks.inc.php @@ -361,6 +361,20 @@ class mail_hooks 'admin' => False, 'default'=> 'always', ], + 'emailTag' => [ + 'type' => 'select', + 'label' => 'Information to show on email tag', + 'help' => 'You can select what info to be dispayed on email tag', + 'name' => 'emailTag', + 'values' => [ + 'onlyname' => lang('only name'), + 'fullemail' => lang('name and email'), + 'onlyemail' => lang('only email'), + ], + 'xmlrpc' => True, + 'admin' => False, + 'default'=> 'onlyname', + ], array( 'type' => 'section', 'title' => lang('Configuration settings'), diff --git a/mail/inc/class.mail_ui.inc.php b/mail/inc/class.mail_ui.inc.php index c0615f0160..8daa7e1165 100644 --- a/mail/inc/class.mail_ui.inc.php +++ b/mail/inc/class.mail_ui.inc.php @@ -591,6 +591,8 @@ class mail_ui { $content[self::$nm_index]['cat_id']=($content[self::$nm_index]['cat_id']?(!Mail::$supportsORinQuery[$this->mail_bo->profileID]&&($content[self::$nm_index]['cat_id']=='quick'||$content[self::$nm_index]['cat_id']=='quickwithcc')?'subject':$content[self::$nm_index]['cat_id']):(Mail::$supportsORinQuery[$this->mail_bo->profileID]?'quick':'subject')); } + + $content['emailTag'] = $GLOBALS['egw_info']['user']['preferences']['mail']['emailTag'] ?? 'onlyname'; $readonlys = $preserv = array(); if (Mail::$debugTimes) Mail::logRunTimes($starttime,null,'',__METHOD__.__LINE__); } @@ -2339,7 +2341,7 @@ $filter['before']= date("d-M-Y", $cutoffdate2); // send configured image proxy to client-side $content['image_proxy'] = self::image_proxy(); $content['avatar'] = Api\Mail\Avatar::getAvatar($content['from'][0]); - + $content['emailTag'] = $GLOBALS['egw_info']['user']['preferences']['mail']['emailTag'] ?? 'onlyname'; $etpl->exec('mail.mail_ui.displayMessage', $content, $sel_options, $readonlys, $preserv, 2); } diff --git a/mail/js/app.js b/mail/js/app.js index 05711182b2..efec5fe09f 100644 --- a/mail/js/app.js +++ b/mail/js/app.js @@ -1158,7 +1158,7 @@ app.classes.mail = AppJS.extend( { rowId = this.mail_fetchCurrentlyFocussed(selected); data = egw.dataGetUIDdata(rowId).data; - + data.emailTag = egw.preference('emailTag', 'mail') ?? 'onlyname'; // Try to resolve winmail.data attachment if (data && data.attachmentsBlock[0] && data.attachmentsBlock[0].winmailFlag diff --git a/mail/templates/default/display.xet b/mail/templates/default/display.xet index 3fcda9995b..70ea9eab99 100644 --- a/mail/templates/default/display.xet +++ b/mail/templates/default/display.xet @@ -78,24 +78,24 @@ - + - + - + - + - + diff --git a/mail/templates/default/index.xet b/mail/templates/default/index.xet index 5891c1969f..29b5411d68 100644 --- a/mail/templates/default/index.xet +++ b/mail/templates/default/index.xet @@ -30,19 +30,21 @@ - + diff --git a/mail/templates/mobile/view.xet b/mail/templates/mobile/view.xet index b477d3a52f..638a8139c6 100644 --- a/mail/templates/mobile/view.xet +++ b/mail/templates/mobile/view.xet @@ -21,18 +21,18 @@ - + - + - + - +