static function countForProjet(PluginProjetProjet $item, $material = false)
 {
     $types = implode("','", PluginProjetProjet::getTypes());
     if (empty($types)) {
         return 0;
     }
     if ($material) {
         $select = "'User','Group','Supplier','Contract'";
         $in = "NOT IN";
     } else {
         $select = "'User','Group','Supplier'";
         $in = "IN";
     }
     return countElementsInTable('glpi_plugin_projet_projets_items', "`itemtype` IN ('{$types}')\n                                   AND `plugin_projet_projets_id` = '" . $item->getID() . "' \n                                   AND `itemtype` {$in} (" . $select . ")");
 }