Changeset 7655 for trunk/workflow/inc/class.so_userinterface.inc.php
- Timestamp:
- 12/14/12 14:30:35 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/workflow/inc/class.so_userinterface.inc.php
r6535 r7655 63 63 $octets = explode('.', $ip); 64 64 $output = array(); 65 for ($i = 0; $i < 4; $i++)65 for ($i = 0; $i < 4; ++$i) 66 66 { 67 67 if ($bits >= 8) … … 123 123 124 124 /* keep only associative elments and check if the user can access an intranet application */ 125 for ($i = 0; $i < count($preOutput); $i++)125 for ($i = 0; $i < count($preOutput); ++$i) 126 126 { 127 127 if (($preOutput[$i]['intranet_only'] == '1') && (!$showIntranetApplications)) 128 128 continue; 129 129 130 for ($j = 0; $j < $result->_numOfFields; $j++)130 for ($j = 0; $j < $result->_numOfFields; ++$j) 131 131 unset($preOutput[$i][$j]); 132 132 $output[] = $preOutput[$i]; … … 152 152 return false; 153 153 154 for ($i = 0; $i < $result->_numOfFields; $i++)154 for ($i = 0; $i < $result->_numOfFields; ++$i) 155 155 unset($output[$i]); 156 156 … … 169 169 170 170 $output = $result->GetArray(-1); 171 for ($i = 0; $i < count($output); $i++)172 for ($j = 0; $j < $result->_numOfFields; $j++)171 for ($i = 0; $i < count($output); ++$i) 172 for ($j = 0; $j < $result->_numOfFields; ++$j) 173 173 unset($output[$i][$j]); 174 174 … … 196 196 197 197 $output = $result->GetArray(-1); 198 for ($i = 0; $i < count($output); $i++)199 { 200 for ($j = 0; $j < $result->_numOfFields; $j++)198 for ($i = 0; $i < count($output); ++$i) 199 { 200 for ($j = 0; $j < $result->_numOfFields; ++$j) 201 201 unset($output[$i][$j]); 202 202 … … 218 218 219 219 $output = $result->GetArray(-1); 220 for ($i = 0; $i < count($output); $i++)221 for ($j = 0; $j < $result->_numOfFields; $j++)220 for ($i = 0; $i < count($output); ++$i) 221 for ($j = 0; $j < $result->_numOfFields; ++$j) 222 222 unset($output[$i][$j]); 223 223 … … 296 296 $cachedLDAP->setOperationMode($cachedLDAP->OPERATION_MODE_NORMAL); 297 297 $categoriesCount = array(); 298 for ($i = 0; $i < count($employees); $i++)298 for ($i = 0; $i < count($employees); ++$i) 299 299 { 300 300 /* remove numeric fields */ 301 for ($j = 0; $j < $result->_numOfFields; $j++)301 for ($j = 0; $j < $result->_numOfFields; ++$j) 302 302 unset($employees[$i][$j]); 303 303 if (!$this->authorized || !isset($employees[$i]['funcao'])) … … 396 396 $cachedLDAP = Factory::newInstance('CachedLDAP'); 397 397 $cachedLDAP->setOperationMode($cachedLDAP->OPERATION_MODE_NORMAL); 398 for ($i = 0; $i < count($employees); $i++)398 for ($i = 0; $i < count($employees); ++$i) 399 399 { 400 400 /* remove numeric fields */ 401 for ($j = 0; $j < $result->_numOfFields; $j++)401 for ($j = 0; $j < $result->_numOfFields; ++$j) 402 402 unset($employees[$i][$j]); 403 403 … … 434 434 435 435 if (count($searchTermExploded) > 0){ 436 for ($i=1; $i<count($searchTermExploded); $i++) {436 for ($i=1; $i<count($searchTermExploded); ++$i) { 437 437 if (strlen($searchTermExploded[$i]) > 2) { 438 438 $fullSearch = true; … … 454 454 $ldapResult = array(); 455 455 456 for ($i = 0; $i < $entries['count']; $i++)456 for ($i = 0; $i < $entries['count']; ++$i) 457 457 $ldapResult[$entries[$i]['uidnumber'][0]] = array('cn' => $entries[$i]['cn'][0], 'telephoneNumber' => $entries[$i]['telephonenumber'][0]); 458 458 … … 481 481 482 482 /* filling return array with employee's information */ 483 for ($i = 0; $i < count($result); $i++) {483 for ($i = 0; $i < count($result); ++$i) { 484 484 $employees []= array( 485 485 'area' => $result[$i]['area'], … … 536 536 /* creating the ldap query */ 537 537 $ldap_query = '(&(|'; 538 for ($i = 0; $i < count($result); $i++) {538 for ($i = 0; $i < count($result); ++$i) { 539 539 $ldap_query .= '(uidNumber=' . $result[$i]['funcionario_id'] . ')'; 540 540 } … … 547 547 /* parsing result */ 548 548 $ldapResult = array(); 549 for ($i = 0; $i < $entries['count']; $i++)549 for ($i = 0; $i < $entries['count']; ++$i) 550 550 $ldapResult[$entries[$i]['uidnumber'][0]] = array('cn' => $entries[$i]['cn'][0], 'telephoneNumber' => $entries[$i]['telephonenumber'][0]); 551 551 … … 556 556 /* filling return array with employee's information */ 557 557 $employees = array(); 558 for ($i = 0; $i < count($result); $i++) {558 for ($i = 0; $i < count($result); ++$i) { 559 559 560 560 $employee = array(); … … 615 615 $ldapResult = array(); 616 616 617 for ($i = 0; $i < $entries['count']; $i++)617 for ($i = 0; $i < $entries['count']; ++$i) 618 618 $ldapResult[$entries[$i]['uidnumber'][0]] = array('cn' => $entries[$i]['cn'][0], 'telephoneNumber' => $entries[$i]['telephonenumber'][0]); 619 619 … … 642 642 643 643 /* filling return array with employee's information */ 644 for ($i = 0; $i < count($result); $i++) {644 for ($i = 0; $i < count($result); ++$i) { 645 645 $employees []= array( 646 646 'area' => $result[$i]['area'], … … 707 707 708 708 $output = $result->GetArray(-1); 709 for ($i = 0; $i < count($output); $i++)710 for ($j = 0; $j < $result->_numOfFields; $j++)709 for ($i = 0; $i < count($output); ++$i) 710 for ($j = 0; $j < $result->_numOfFields; ++$j) 711 711 unset($output[$i][$j]); 712 712 … … 728 728 729 729 $output = $result->GetArray(-1); 730 for ( $i = 0; $i < count($output); $i++)731 { 732 for ($j = 0; $j < $result->_numOfFields; $j++)730 for ( $i = 0; $i < count($output); ++$i ) 731 { 732 for ($j = 0; $j < $result->_numOfFields; ++$j) 733 733 unset($output[$i][$j]); 734 734 … … 759 759 760 760 $output = $result->GetArray( -1 ); 761 for ( $i = 0; $i < count($output); $i++)762 for ($j = 0; $j < $result->_numOfFields; $j++)761 for ( $i = 0; $i < count($output); ++$i ) 762 for ($j = 0; $j < $result->_numOfFields; ++$j) 763 763 unset($output[$i][$j]); 764 764 … … 795 795 796 796 $categoriesCount = array( ); 797 for ( $i = 0; $i < count( $employees ); $i++)797 for ( $i = 0; $i < count( $employees ); ++$i ) 798 798 { 799 799 // remove numeric fields 800 for ( $j = 0; $j < $result -> _numOfFields; $j++)800 for ( $j = 0; $j < $result -> _numOfFields; ++$j ) 801 801 unset( $employees[ $i ][ $j ] ); 802 802 … … 867 867 868 868 $categoriesCount = array( ); 869 for ( $i = 0; $i < count( $employees ); $i++)869 for ( $i = 0; $i < count( $employees ); ++$i ) 870 870 { 871 871 // remove numeric fields 872 for ( $j = 0; $j < $result -> _numOfFields; $j++)872 for ( $j = 0; $j < $result -> _numOfFields; ++$j ) 873 873 unset( $employees[ $i ][ $j ] ); 874 874 … … 893 893 894 894 // count the number of employees in each category 895 for ( $i = 0; $i < count( $employees ); $i++)895 for ( $i = 0; $i < count( $employees ); ++$i ) 896 896 { 897 897 $categoryID = $employees[ $i ][ 'funcionario_categoria_id' ];
Note: See TracChangeset
for help on using the changeset viewer.