Ignore:
Timestamp:
12/02/10 10:11:46 (13 years ago)
Author:
eduardoalex
Message:

Ticket #1423 - Envio das modificacoes no cabeçalho e rodape para o novo expressomini.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2/mobile/inc/class.mobiletemplate.inc.php

    r3499 r3554  
    11<?php  
    2 include_once(PHPGW_INCLUDE_ROOT.'/mobile/inc/class.ui_mobile.inc.php'); 
     2//include_once(PHPGW_INCLUDE_ROOT.'/mobile/inc/class.ui_mobile.inc.php'); 
    33        class mobiletemplate 
    44        { 
     
    1212                function mobiletemplate(){ 
    1313                        $this->template = CreateObject('phpgwapi.Template', PHPGW_SERVER_ROOT . '/mobile/templates/'.$GLOBALS['phpgw_info']['server']['template_set']); 
    14                         $this->template->set_file(Array('home_t' => 'home.tpl'));        
     14                        $this->template->set_file(Array('home_t' => 'template.tpl'));    
    1515                        $this->template->set_block('home_t', 'mobile_home');                     
    1616                } 
     
    3737                        include_once($filename);         
    3838                        $obj = new $class();             
    39                         $obj -> $method();               
     39                        $obj -> $method($_REQUEST); 
    4040                        $this->template->pfp('out', 'mobile_home'); 
    4141                } 
     
    4747                */ 
    4848                private function print_navbar(){ 
    49                         $ui_mobilemail = CreateObject('mobile.ui_mobilemail'); 
    5049                         
    51                         $this-> template->set_var('href_newmail', 'index.php?menuaction=mobile.ui_mobilemail.new_msg&clk=01'); 
    52                         $this-> template->set_var('lang_newmail', lang('Create mail')); 
    53                         $this-> template->set_var('href_email', "index.php?menuaction=mobile.ui_mobilemail.change_folder&folder=0"); 
     50                        $obj = createobject("expressoMail1_2.functions"); 
     51            // setting timezone preference 
     52            $zones = $obj->getTimezones(); 
     53            $_SESSION['phpgw_info']['user']['preferences']['expressoMail']['timezone'] = $GLOBALS['phpgw_info']['user']['preferences']['expressoMail']['timezone'] ? $GLOBALS['phpgw_info']['user']['preferences']['expressoMail']['timezone'] : sprintf("%s", array_search("America/Sao_Paulo", $zones)); 
     54 
     55                         
     56                        $this-> template->set_var('lang_back', lang('Back')); 
     57                        $this-> template->set_var('lang_home', lang('home')); 
    5458                        $this-> template->set_var('lang_email', lang('E-mail')); 
    55  
    56                         $obj = createobject("expressoMail1_2.functions"); 
    57                         // setting timezone preference 
    58                         $zones = $obj->getTimezones(); 
    59                         $_SESSION['phpgw_info']['user']['preferences']['expressoMail']['timezone'] = $GLOBALS['phpgw_info']['user']['preferences']['expressoMail']['timezone'] ? $GLOBALS['phpgw_info']['user']['preferences']['expressoMail']['timezone'] : sprintf("%s", array_search("America/Sao_Paulo", $zones)); 
    60  
    61                         $save_in_folder = $GLOBALS['phpgw_info']['user']['preferences']['expressoMail']['save_in_folder'] ? $GLOBALS['phpgw_info']['user']['preferences']['expressoMail']['save_in_folder'] : "-1"; 
    62                         $save_in_folder = @eregi_replace("INBOX/", "INBOX".$_SESSION['phpgw_info']['expressomail']['email_server']['imapDelimiter'], $save_in_folder); 
    63                         $save_in_folder = @eregi_replace("INBOX.", "INBOX".$_SESSION['phpgw_info']['expressomail']['email_server']['imapDelimiter'], $save_in_folder); 
    64                         $save_in_folder = $save_in_folder == '' ? 'INBOX/Sent':$save_in_folder;                  
    65                         $folder_number = $ui_mobilemail->get_folder_number($save_in_folder); 
    66                         $_SESSION['phpgw_info']['user']['preferences']['expressoMail']['save_in_folder'] = $save_in_folder; 
    67                                                  
    68                         $this-> template->set_var('href_sent', "index.php?menuaction=mobile.ui_mobilemail.change_folder&folder=".$folder_number); 
    69                         $this-> template->set_var('lang_sent', str_replace('*','',lang(str_replace('INBOX/','',$save_in_folder)))); 
    70                         $this-> template->set_var('href_more', 'index.php?menuaction=mobile.ui_mobilemail.list_folders'); 
    71                         $this-> template->set_var('lang_more_folders', lang('More folders...')); 
    72                         $this-> template->set_var('href_calendar', "index.php?menuaction=mobile.ui_mobilecalendar.index"); 
     59                        $this-> template->set_var('lang_contacts', lang('Contact Center')); 
    7360                        $this-> template->set_var('lang_calendar', lang('Calendar')); 
    7461                        $this-> template->set_var('href_cc', 'index.php?menuaction=mobile.ui_mobilecc.contacts_list'); 
    75                         $this-> template->set_var('lang_cc', lang('Contact Center'));            
     62                        $this-> template->set_var('href_email', "index.php?menuaction=mobile.ui_mobilemail.change_folder&folder=0"); 
     63                        $this-> template->set_var('href_calendar', "index.php?menuaction=mobile.ui_mobilecalendar.index"); 
     64                        $this-> template->set_var('href_home', "..."); 
     65 
    7666                } 
    7767 
     
    8474                        $GLOBALS['phpgw']->accounts->read_repository(); 
    8575                        $var  = Array( 
    86                                 'fullname'      => $GLOBALS['phpgw']->accounts->data['fullname'], 
    87                                 'account_lid'   => $GLOBALS['phpgw_info']['user']['account_lid'], 
    88                                 'lang_logout'   => lang('Logout'), 
    89                                 'template_set'  => $GLOBALS['phpgw_info']['server']['template_set'], 
    9076                                'css'   => $this->get_mobile_css(), 
    91                                 'lang_search'   => lang('Search')                                
    9277                        );               
    9378                        $this->template->set_var($var);          
Note: See TracChangeset for help on using the changeset viewer.