/** * @return TroveCat */ private function getTroveCatWithChildrens(array $row) { $trove_cat_id = $row['trove_cat_id']; $trove_cat = $this->getInstanceFromRow($row); foreach ($this->dao->getCategoryChildrenToDisplayDuringProjectCreation($trove_cat_id) as $row_child) { $child = $this->getInstanceFromRow($row_child); $trove_cat->addChildren($child); } return $trove_cat; }
/** * @return TroveCat[] */ public function getMandatoryParentCategoriesUnderRoot() { $results = $this->dao->getMandatoryParentCategoriesUnderRoot(); $trove_cats = array(); foreach ($results as $row) { $trove_cat_id = $row['trove_cat_id']; $trove_cat = $this->getInstanceFromRow($row); foreach ($this->dao->getCategoryChildren($trove_cat_id) as $row_child) { $child = $this->getInstanceFromRow($row_child); $trove_cat->addChildren($child); } $trove_cats[] = $trove_cat; } return $trove_cats; }
$csv_exporter->buildDatas($dao->getPrivacyOfActiveProjectsBeforeEndDate(), "Public Project"); $csv_exporter->buildDatas($dao->getDescriptionOfActiveProjectsBeforeEndDate(), "Description"); $csv_exporter->buildDatas($dao->getRegisterTimeOfActiveProjectsBeforeEndDate(), "Creation date"); $csv_exporter->buildDatas($dao->getInfosFromTroveGroupLink(), "Organization"); $csv_exporter->buildDatas($dao->getAdministrators(), "Created by"); $csv_exporter->buildDatas($dao->getAdministratorsRealNames(), "Created by (Real name)"); $csv_exporter->buildDatas($dao->getAdministratorsEMails(), "Created by (Email)"); $csv_exporter->buildDatas($dao->getNumberOfUserAddedBetweenStartDateAndEndDate(), "Users added"); //Custom Descriptions $custom_description_factory = new Project_CustomDescription_CustomDescriptionFactory(new Project_CustomDescription_CustomDescriptionDao()); $custom_description_value_dao = new Project_CustomDescription_CustomDescriptionValueDao(); foreach ($custom_description_factory->getCustomDescriptions() as $custom_description) { $csv_exporter->buildDatas($custom_description_value_dao->getAllDescriptionValues($custom_description->getId()), $custom_description->getLabel()); } //Trove Cats $trove_cat_dao = new TroveCatDao(); $trove_cat_factory = new TroveCatFactory($trove_cat_dao); $mandatories_trove_cat = $trove_cat_factory->getMandatoryParentCategoriesUnderRoot(); foreach ($mandatories_trove_cat as $trove_cat) { $csv_exporter->buildDatas($trove_cat_dao->getMandatoryCategorySelectForAllProject($trove_cat->getId()), $trove_cat->getFullname()); } //CVS & SVN $csv_exporter->buildDatas($dao->getCVSActivities(), "CVS activities"); $csv_exporter->buildDatas($dao->getSVNActivities(), "SVN activities"); //GIT $p = $pluginManager->getPluginByName('git'); if ($p && $pluginManager->isPluginAvailable($p)) { $csv_exporter->buildDatas($dao->getGitActivities(), "GIT activities"); } //FRS $csv_exporter->buildDatas($dao->getFilesPublished(), "Files published");