Example #1
0
 /**
  * Display content for each users
  *
  * @static
  * @param CommonGLPI $item
  * @param int $tabnum
  * @param int $withtemplate
  * @return bool|true
  */
 static function displayTabContentForItem(CommonGLPI $item, $tabnum = 1, $withtemplate = 0)
 {
     $field = new self();
     if ($item->getType() == 'User') {
         $field->showForUser($item);
     }
     return true;
 }
Example #2
0
 /**
  * Display content for each users
  *
  * @static
  * @param CommonGLPI $item
  * @param int $tabnum
  * @param int $withtemplate
  * @return bool|true
  */
 static function displayTabContentForItem(CommonGLPI $item, $tabnum = 1, $withtemplate = 0)
 {
     $field = new self();
     if ($item->getType() == 'User' && self::canView()) {
         $field->showForUser($item);
     } else {
         if ($item->getType() == 'ConsumableItem' && self::canView()) {
             $field->showForConsumable($item);
         }
     }
     return true;
 }