[ Index ]

Source Code Reference for V1.00

title

Body

[close]

/modules/tasks/ -> tasksperuser.php (source)

   1  <?php /* TASKS $Id: tasksperuser.php,v 1.5.6.2 2007/03/06 00:34:45 merlinyoda Exp $ */
   2  if (!defined('W2P_BASE_DIR')) {
   3      die('You should not access this file directly.');
   4  }
   5  
   6  $AppUI->savePlace();
   7  
   8  if (isset($_POST['company_id'])) {
   9      $AppUI->setState('CompanyIdxFilter', $_POST['company_id']);
  10  }
  11  $company_id = $AppUI->getState('CompanyIdxFilter') ? $AppUI->getState('CompanyIdxFilter') : 'all';
  12  
  13  $log_all_projects = true; // show tasks for all projects
  14  $df = $AppUI->getPref('SHDATEFORMAT'); // get the prefered date format
  15  
  16  // get CCompany() to filter tasks by company
  17  require_once ($AppUI->getModuleClass('companies'));
  18  $comp = new CCompany();
  19  $companies = $comp->getAllowedRecords($AppUI->user_id, 'company_id,company_name', 'company_name');
  20  $compFilter = arrayMerge(array('all' => $AppUI->_('All Companies')), $companies);
  21  
  22  // setup the title block
  23  $titleBlock = new CTitleBlock('Tasks per User', 'applet-48.png', $m, $m . '.' . $a);
  24  $titleBlock->addCell($AppUI->_('Company') . ':');
  25  $titleBlock->addCell(arraySelect($compFilter, 'company_id', 'size="1" class="text" onChange="document.companyFilter.submit();"', $company_id, false), '', '<form action="?m=tasks&a=tasksperuser" method="post" name="companyFilter">', '</form>');
  26  $titleBlock->addCrumb('?m=tasks', 'tasks list');
  27  $titleBlock->addCrumb('?m=tasks&a=todo&user_id=' . $user_id, 'my todo');
  28  $titleBlock->show();
  29  
  30  // include the re-usable sub view
  31  $min_view = false;
  32  include  (W2P_BASE_DIR . '/modules/tasks/tasksperuser_sub.php');
  33  ?>


Generated: Thu Jan 8 03:00:03 2009 Cross-referenced by PHPXref 0.7