Changeset 1310


Ignore:
Timestamp:
08/12/09 11:28:43 (15 years ago)
Author:
rodsouza
Message:

Ticket #589 - Modificado cache do LDAP (modo e tempo) e interface do usuario (cartao e barra de botoes)

Location:
trunk/workflow
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/workflow/inc/class.CachedLDAP.inc.php

    r1067 r1310  
    8383        * @access private 
    8484        */ 
    85         private $cacheDays = 5; 
     85        private $cacheDays = 2; 
    8686 
    8787        /** 
  • trunk/workflow/inc/class.so_userinterface.inc.php

    r1276 r1310  
    246246                $employees = $result->GetArray(-1); 
    247247                $cachedLDAP = $GLOBALS['workflow']['factory']->newInstance('CachedLDAP'); 
    248                 $cachedLDAP->setOperationMode($cachedLDAP->OPERATION_MODE_LDAP_DATABASE); 
     248                $cachedLDAP->setOperationMode($cachedLDAP->OPERATION_MODE_NORMAL); 
    249249                $categoriesCount = array(); 
    250250                for ($i = 0; $i < count($employees); $i++) 
     
    319319                $employees = $result->GetArray(-1); 
    320320                $cachedLDAP = $GLOBALS['workflow']['factory']->newInstance('CachedLDAP'); 
    321                 $cachedLDAP->setOperationMode($cachedLDAP->OPERATION_MODE_LDAP_DATABASE); 
     321                $cachedLDAP->setOperationMode($cachedLDAP->OPERATION_MODE_NORMAL); 
    322322                for ($i = 0; $i < count($employees); $i++) 
    323323                { 
     
    520520                $employees = $result -> GetArray( -1 ); 
    521521                $cachedLDAP = $GLOBALS[ 'workflow' ][ 'factory' ] -> newInstance( 'CachedLDAP' ); 
    522                 $cachedLDAP -> setOperationMode( $cachedLDAP -> OPERATION_MODE_LDAP_DATABASE ); 
     522                $cachedLDAP -> setOperationMode( $cachedLDAP -> OPERATION_MODE_NORMAL ); 
    523523 
    524524                $categoriesCount = array( ); 
     
    592592 
    593593                $cachedLDAP = $GLOBALS[ 'workflow' ][ 'factory' ] -> newInstance( 'CachedLDAP' ); 
    594                 $cachedLDAP -> setOperationMode( $cachedLDAP -> OPERATION_MODE_LDAP_DATABASE ); 
     594                $cachedLDAP -> setOperationMode( $cachedLDAP -> OPERATION_MODE_NORMAL ); 
    595595 
    596596                $categoriesCount = array( ); 
     
    617617                usort( $employees, create_function( '$a,$b', 'return strcasecmp($a[\'cn\'],$b[\'cn\']);' ) ); 
    618618 
    619                 $paging = $GLOBALS['workflow']['factory']->newInstance('Paging', 100, $_POST); 
     619                $paging = $GLOBALS['workflow']['factory']->newInstance('Paging', 50, $_POST); 
    620620                $employees = $paging->restrictItems( $employees ); 
    621621 
  • trunk/workflow/js/userinterface/orgchart.js

    r1305 r1310  
    3434 
    3535        var content = '<ul class="horizontalMenu">'; 
    36         content += '<li style="margin: 5px 5px 0 5px">Visualizar : <select>' 
     36        content += '<li style="margin: 5px 5px 0 5px">Visualizar : <select onclick="this.parentNode.parentNode.lastChild.style.display = (this.options[1].selected) ? \'block\' : \'none\' ">' 
    3737        content += '<option onclick="getAlphabeticalEmployees( )">Alfabética</option>' 
    3838        content += '<option onclick="getHierarchicalArea( );" selected="true">Áreas</option>' 
     
    4444        content += '</select></li>'; 
    4545        content += '<li><a href="#" onclick="window.open(\'' + enderecoImagem + '\', \'extwindow\'); return false;"><img src="templateFile.php?file=images/Process.gif">&nbsp;&nbsp;Gráfico</a></li>'; 
     46        content += '<li><a><input type="text" name="search_term" id="search_term" onkeypress="if (((event.which) ? event.which : event.keyCode) == 13) $(\'search_span\').onclick(); return true;" /><span id="search_span" style="cursor: pointer;" onclick="tmp = $$(\'div#orgchartAreas a.destaque\'); if (tmp[0]) tmp[0].removeClassName(\'destaque\'); orgchartSearchEmployee($F(\'search_term\')); return false;">&nbsp;busca</span></a></li>'; 
    4647        content += '<li><a href="#" onclick="printArea(); return false;"><img src="templateFile.php?file=images/imprimir.png" width="16">&nbsp;&nbsp;Imprimir</a></li>'; 
    47         content += '<li><a><input type="text" name="search_term" id="search_term" onkeypress="if (((event.which) ? event.which : event.keyCode) == 13) $(\'search_span\').onclick(); return true;" /><span id="search_span" style="cursor: pointer;" onclick="tmp = $$(\'div#orgchartAreas a.destaque\'); if (tmp[0]) tmp[0].removeClassName(\'destaque\'); orgchartSearchEmployee($F(\'search_term\')); return false;">&nbsp;busca</span></a></li>'; 
    4848        content += '</ul>'; 
    4949        content += '<br/>'; 
     
    201201function getUsefulPhones( ) 
    202202{ 
     203        workflowUserInterfaceCurrentAreaID = 0; 
     204 
    203205        cExecute("$this.bo_userinterface.getUsefulPhones", displayUsefulPhones, ""); 
    204206} 
     
    206208function getAreaWithSubtituteBoss( ) 
    207209{ 
     210        workflowUserInterfaceCurrentAreaID = 0; 
     211 
    208212        cExecute("$this.bo_userinterface.getAreaWithSubtituteBoss", displayAreaWithSubtituteBoss, ""); 
    209213} 
     
    211215function getCostCenters() 
    212216{ 
     217        workflowUserInterfaceCurrentAreaID = 0; 
     218 
    213219        cExecute("$this.bo_userinterface.getCostCenters", displayCostCenters, ""); 
    214220} 
     
    216222function getHierarchicalArea() 
    217223{ 
     224        workflowUserInterfaceCurrentAreaID = 0; 
     225 
    218226        cExecute("$this.bo_userinterface.getHierarchicalArea", displayHierarchicalAreas, ""); 
    219227} 
     
    226234function getCategoriesList() 
    227235{ 
     236        workflowUserInterfaceCurrentAreaID = 0; 
     237 
     238        var div = $('orgchartEmployees'); 
     239        div.innerHTML = ''; 
     240 
    228241        function resultGetCategoriesList(data) 
    229242        { 
     
    243256function getManning( ) 
    244257{ 
     258        workflowUserInterfaceCurrentAreaID = 0; 
     259 
     260        var div = $('orgchartEmployees'); 
     261        div.innerHTML = ''; 
     262 
    245263        function resultGetManning( data ) 
    246264        { 
     
    560578                } 
    561579 
     580                card.appendChild( document.createElement( 'br' ) ); 
     581 
    562582                if ( card_data[ 'sitio' ] ) 
    563583                { 
Note: See TracChangeset for help on using the changeset viewer.