Changeset 1747
- Timestamp:
- 12/04/09 11:47:00 (14 years ago)
- Location:
- trunk/expressoMail1_2
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/expressoMail1_2/inc/class.imap_functions.inc.php
r1740 r1747 1499 1499 $result[$i]['folder_name'] = array_pop($tmp_folder_parent); 1500 1500 $result[$i]['folder_name'] = $result[$i]['folder_name'] == 'INBOX' ? 'Inbox' : $result[$i]['folder_name']; 1501 if ( substr($folder_id,0,4) == 'user' && is_numeric($result[$i]['folder_name'])) {1501 if ($_SESSION['phpgw_info']['user']['preferences']['expressoMail']['uid2cn'] && substr($folder_id,0,4) == 'user') { 1502 1502 //$this->ldap = new ldap_functions(); 1503 1503 if ($cn = $this->ldap->uid2cn($result[$i]['folder_name'])){ … … 2232 2232 } 2233 2233 //Este bloco tem a finalidade de transformar o CPF das pastas compartilhadas em common name 2234 if (substr($new_folder_name,0,4) == 'user'){ 2235 $this->ldap = new ldap_functions(); 2236 $tmp_folder_name = explode($this->imap_delimiter, $new_folder_name); 2237 $return['new_folder_name'] = array_pop($tmp_folder_name); 2238 if (is_numeric($return['new_folder_name'])) 2239 if( $cn = $this->ldap->uid2cn($return['new_folder_name'])) 2240 $return['new_folder_name'] = $cn; 2234 if ($_SESSION['phpgw_info']['user']['preferences']['expressoMail']['uid2cn']){ 2235 if (substr($new_folder_name,0,4) == 'user'){ 2236 $this->ldap = new ldap_functions(); 2237 $tmp_folder_name = explode($this->imap_delimiter, $new_folder_name); 2238 $return['new_folder_name'] = array_pop($tmp_folder_name); 2239 if( $cn = $this->ldap->uid2cn($return['new_folder_name'])) 2240 { 2241 $return['new_folder_name'] = $cn; 2242 } 2243 } 2241 2244 } 2242 2245 … … 3085 3088 $filter = $this->remove_accents($filter); 3086 3089 //Este bloco tem a finalidade de transformar o login (quando numerico) das pastas compartilhadas em common name 3087 $folder_name = explode($this->imap_delimiter,$name_box); 3088 if (is_numeric($folder_name[1])) 3090 if ($_SESSION['phpgw_info']['user']['preferences']['expressoMail']['uid2cn'] && substr($name_box,0,4) == 'user') 3089 3091 { 3092 $folder_name = explode($this->imap_delimiter,$name_box); 3090 3093 $this->ldap = new ldap_functions(); 3091 3094 if ($cn = $this->ldap->uid2cn($folder_name[1])) … … 3093 3096 $folder_name[1] = $cn; 3094 3097 } 3098 $folder_name = implode($this->imap_delimiter,$folder_name); 3095 3099 } 3096 $folder_name = implode($this->imap_delimiter,$folder_name); 3100 else 3101 { 3102 $folder_name = mb_convert_encoding(utf8_decode($name_box), "UTF7-IMAP", "ISO_8859-1" ); 3103 } 3097 3104 3098 3105 if(!is_resource($mbox_stream)) -
trunk/expressoMail1_2/inc/hook_settings.inc.php
r1611 r1747 61 61 }'); 62 62 //} 63 $default = false; 64 create_check_box('Do you want to show common name instead of UID?','uid2cn',$default, 65 'Do you want to show common name instead of UID?'); 63 66 64 67 $default = array( -
trunk/expressoMail1_2/js/draw_api.js
r1723 r1747 19 19 var currentTab,numBox = 0; // Open Tab and num of mailboxes opened at context 20 20 21 // Objeto Map, talvez o ideal fosse adicionar este objeto à Api do egroupware, e carregá-lo 22 // aqui no expressoMail. 23 function Map() 24 { 25 this.keys = new Array(); 26 this.values = new Array(); 27 } 28 29 Map.prototype.add = function(key, value) 30 { 31 this.keys.push(key); 32 this.values.push(value); 33 } 34 35 Map.prototype.get = function(key) 36 { 37 result = new Array(); 38 for (i = 0; i < this.keys.length; i++) 39 { 40 if (this.keys[i] == key) 41 { 42 result.push(this.values[i]); 43 } 44 } 45 46 if (result.length == 0) 47 { 48 return null; 49 } 50 51 return result; 52 } 53 54 var translatedFolders = new Map(); 55 21 56 function draw_tree_folders(folders){ 22 57 // Check if the tree folders alredy exist. 58 translatedFolders = new Map(); 23 59 if (Element('dftree_tree_folders')){ 24 60 if (!expresso_offline) { … … 162 198 163 199 if (!tree_folders.getNodeById('user')){ 200 tmpFolderId = folders[i].folder_id.split(cyrus_delimiter).pop(); 201 if (tmpFolderId != folders[i].folder_name) 202 { 203 translatedFolders.add(tmpFolderId, folders[i].folder_name); 204 } 164 205 var n_root_shared_folders = new dNode({id:'user', caption:get_lang("Shared folders"), plusSign:true}); 165 206 tree_folders.add(n_root_shared_folders,'root'); -
trunk/expressoMail1_2/js/local_messages.js
r1666 r1747 779 779 } 780 780 sql += ") and ("; 781 for (var z=0;z<friendly_filters.length -1;z++) {781 for (var z=0;z<friendly_filters.length;z++) { 782 782 if (z != 0) { 783 783 if (sFilter.indexOf('ALL') != -1) … … 808 808 while(rs.isValidRow()) { 809 809 var header = connector.unserialize(rs.field(0)); 810 retorno+="##"+"local_"+rs.field(1)+"--"+ "local_"+rs.field(1)+"--"+header["from"]["name"]+"--"+header["subject"]+"--"+header["udate"]+"--"+this.aux_convert_size(rs.field(3))+"--"+header["Unseen"]+header["Recent"]+header["Flagged"]+header["Draft"]+"--"+rs.field(2)+"##";810 retorno+="##"+"local_"+rs.field(1)+"--"+header["from"]["name"]+"--"+header["subject"]+"--"+header["udate"]+"--"+this.aux_convert_size(rs.field(3))+"--"+header["Unseen"]+header["Recent"]+header["Flagged"]+header["Draft"]+"--"+rs.field(2)+"##"; 811 811 rs.next(); 812 812 } -
trunk/expressoMail1_2/js/search.js
r1631 r1747 482 482 483 483 var td1 = get_lang(td1).substr(get_lang(td1).length-1) == "*"?td1:get_lang(td1); 484 if ((tmp = translatedFolders.get(td1))) 485 { 486 td1 = tmp; 487 } 484 488 485 489 if(proxy_mensagens.is_local_folder(td1)) { -
trunk/expressoMail1_2/setup/phpgw_en.lang
r1622 r1747 82 82 Do you want to block this e-mail? expressoMail1_2 en Do you want to block this e-mail? 83 83 Do you want to log the sent messages? admin en Do you want to log the sent messages? 84 Do you want to show common name instead of UID? expressoMail1_2 en Do you want to show common name instead of UID? 84 85 Do you want to use the spam filter? admin en Do you want to use the spam filter? 85 86 Do you wish to exclude the folder expressoMail1_2 en Do you wish to exclude the folder
Note: See TracChangeset
for help on using the changeset viewer.