Changeset 4830


Ignore:
Timestamp:
07/19/11 17:44:12 (13 years ago)
Author:
airton
Message:

Ticket #2147 - Permitir ao usuario reportar problemas em mensagens de email

Location:
trunk/expressoMail1_2
Files:
1 added
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/expressoMail1_2/inc/class.imap_functions.inc.php

    r4824 r4830  
    1414                'get_folders_list'                              => True, 
    1515                'import_msgs'                                   => True, 
     16                'report_mail_error'             => True, 
    1617                'msgs_to_archive'                               => True 
    1718        ); 
     
    42674268        return $exporteml->download_all_attachments($params); 
    42684269    } 
     4270         
     4271        /**  
     4272         * Método que envia um email reportando um erro no email do usuário  
     4273         * @license http://www.gnu.org/copyleft/gpl.html GPL  
     4274         * @author Prognus Software Livre (http://www.prognus.com.br)  
     4275         */   
     4276        function report_mail_error($params)  
     4277        {         
     4278                $params = $params['params'];  
     4279                $array_params = explode(";;", $params);  
     4280                $id_msg   = $array_params[0];  
     4281                $msg_user = $array_params[1];  
     4282                 
     4283                if($msg_user == '')  
     4284                        $msg_user = "Sem mensagem!";  
     4285                          
     4286                $toaddresses = $_SESSION['phpgw_info']['expressomail']['server']['sugestoes_email_to'];   
     4287                $toaddress   = explode(",", $toaddresses);        
     4288                                  
     4289                for($i=0; $i<count($toaddress); $i++)  
     4290                        $toaddress[$i] = trim($toaddress[$i]);  
     4291                                  
     4292                $toname       = $_SESSION['phpgw_info']['expressomail']['user']['fullname'];  
     4293                  
     4294                $exporteml    = new ExportEml();  
     4295                $mail_content = $exporteml->export_msg_data($id_msg, $msg_folder);  
     4296                $this->open_mbox($msg_folder);   
     4297                $title = "Erro de email reportado";  
     4298                $body  = "<body>O usuário <strong>$toname</strong> reportou um erro na tentativa de acesso ao conteúdo do email.<br><br>Segue em anexo o fonte da mensagem" .                           " reportada.<br><br><hr><strong><u>Mensagem do usuário:</strong></u><br><br><br>" .  
     4299                                "$msg_user</body><br><br><hr>";  
     4300                              
     4301                $mailService = ServiceLocator::getService('mail');       
     4302                $mailService->addAttachment($mail_content, 'report.eml', 'application/text');  
     4303                $mailService->send($toaddress, $GLOBALS['phpgw_info']['user']['email'], $title, $body);  
     4304        }  
     4305         
     4306         
     4307         
    42694308    function get_quota_folders(){  
    42704309 
  • trunk/expressoMail1_2/js/draw_api.js

    r4826 r4830  
    18931893                        div_other_options.innerHTML += ' | <span class="message_options" onclick="spam(\''+info_msg.msg_folder+'\', '+info_msg.msg_number+',\'null\')";>'+get_lang("Mark as Spam")+'</span>'; 
    18941894        } 
     1895         
     1896        var report_error        = ' | <span onmouseover="this.className=\'message_options_active\'" onmouseout="this.className=\'message_options\'" class="message_options" onclick=reports_window("'+currentTab+'");>'+get_lang("Report error")+'</span> |';  
     1897                          
     1898        div_other_options.innerHTML += report_error; 
     1899         
    18951900        td_other_options.align = 'right'; 
    18961901        td_other_options.style.paddingTop = '3px'; 
  • trunk/expressoMail1_2/js/main.js

    r4825 r4830  
    27592759                return arrayInvalidEmails; 
    27602760} 
     2761 
     2762                /* Função que chama a tela para o usuário reportar um erro no email. */  
     2763                function reports_window(currentTab){  
     2764                        ID_msg = currentTab.substr(0,currentTab.indexOf("_"));  
     2765                        report_wind.make_report_window(ID_msg);  
     2766                }  
     2767 
  • trunk/expressoMail1_2/setup/phpgw_es-es.lang

    r4231 r4830  
    598598View the user name in the header of the messages printed?       expressoMail1_2 es-es   Ver el nombre de usuario en el encabezado de los mensajes impresos?      
    599599Displays the user name in the header print email        expressoMail1_2 es-es   Muestra el nombre de usuario en el correo electrónico imprimir el encabezado     
    600  
     600Report error    expressoMail1_2 es-es   Informe de error  
     601Describe the problem to report to technical support (optional)  expressoMail1_2 es-es   Describa el problema que le informe de apoyo técnico (opcional)  
     602Attention! The original message will be sent along with the original source of the email message        expressoMail1_2 es-es   ¡Atención! El mensaje original se enviará junto con la fuente original del mensaje de correo electrónico 
  • trunk/expressoMail1_2/setup/phpgw_pt-br.lang

    r4823 r4830  
    669669Error exporting messages, try again latter      expressoMail1_2 pt-br   Não foi possível exportar as mensagens selecionadas. 
    670670Exporting selected messages, this can take some time.   expressoMail1_2 pt-br   Exportando mensagens, isso pode levar algum tempo. 
     671Report error    expressoMail1_2 pt-br   Reportar erro  
     672Describe the problem to report to technical support (optional)  expressoMail1_2 pt-br   Descreva o problema para reportar para a equipe de suporte técnico (opcional)  
     673Attention! The original message will be sent along with the original source of the email message        expressoMail1_2 pt-br   Atenção! A mensagem original será enviado junto com a fonte original da mensagem de e-mail 
  • trunk/expressoMail1_2/templates/default/index.tpl

    r3685 r4830  
    11<!-- BEGIN list --> 
     2<script src="js/report_window.js"></script>  
    23<input type="hidden" value="{txt_loading}" id="txt_loading"> 
    34<input type="hidden" value="{txt_clear_trash}" id="txt_clear_trash"> 
Note: See TracChangeset for help on using the changeset viewer.