當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Tracker_ArtifactFactory::getArtifactsByTrackerId方法代碼示例

本文整理匯總了PHP中Tracker_ArtifactFactory::getArtifactsByTrackerId方法的典型用法代碼示例。如果您正苦於以下問題:PHP Tracker_ArtifactFactory::getArtifactsByTrackerId方法的具體用法?PHP Tracker_ArtifactFactory::getArtifactsByTrackerId怎麽用?PHP Tracker_ArtifactFactory::getArtifactsByTrackerId使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Tracker_ArtifactFactory的用法示例。


在下文中一共展示了Tracker_ArtifactFactory::getArtifactsByTrackerId方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: export

 public function export(Tracker $tracker, SimpleXMLElement $xml_content, PFUser $user, ZipArchive $archive)
 {
     $artifacts_node = $xml_content->addChild('artifacts');
     $all_artifacts = $this->artifact_factory->getArtifactsByTrackerId($tracker->getId());
     $this->checkThreshold(count($all_artifacts));
     foreach ($all_artifacts as $artifact) {
         $artifact->exportToXML($artifacts_node, $user, $archive);
     }
     $this->rng_validator->validate($artifacts_node, realpath(dirname(TRACKER_BASE_DIR) . self::ARTIFACTS_RNG_PATH));
 }
開發者ID:rinodung,項目名稱:tuleap,代碼行數:10,代碼來源:XMLExport.php

示例2: getTopSubMilestoneArtifacts

 private function getTopSubMilestoneArtifacts(PFUser $user, Planning_VirtualTopMilestone $top_milestone)
 {
     $artifacts = array();
     if (!$top_milestone->getPlanning()) {
         return $artifacts;
     }
     $milestone_planning_tracker_id = $top_milestone->getPlanning()->getPlanningTrackerId();
     if (!$milestone_planning_tracker_id) {
         return $artifacts;
     }
     return $this->artifact_factory->getArtifactsByTrackerId($milestone_planning_tracker_id);
 }
開發者ID:ansarbek,項目名稱:tuleap,代碼行數:12,代碼來源:MilestoneFactory.class.php

示例3: getTopSubMilestones

 /**
  * Return the list of top most milestones
  *
  * @param PFUser $user
  * @param Planning_VirtualTopMilestone $top_milestone
  *
  * @return Planning_ArtifactMilestone[]
  */
 private function getTopSubMilestones(PFUser $user, Planning_VirtualTopMilestone $top_milestone)
 {
     $milestones = array();
     if (!$top_milestone->getPlanning()) {
         return $milestones;
     }
     $root_planning = $this->planning_factory->getRootPlanning($user, $top_milestone->getProject()->getID());
     $milestone_planning_tracker_id = $top_milestone->getPlanning()->getPlanningTrackerId();
     $artifacts = $this->artifact_factory->getArtifactsByTrackerId($milestone_planning_tracker_id);
     if ($milestone_planning_tracker_id) {
         foreach ($artifacts as $artifact) {
             if ($artifact->getLastChangeset() && $artifact->userCanView($user)) {
                 $milestone = new Planning_ArtifactMilestone($top_milestone->getProject(), $root_planning, $artifact);
                 $this->addMilestoneAncestors($user, $milestone);
                 $this->updateMilestoneContextualInfo($user, $milestone);
                 $milestones[] = $milestone;
             }
         }
     }
     return $milestones;
 }
開發者ID:superlinger,項目名稱:tuleap,代碼行數:29,代碼來源:MilestoneFactory.class.php


注:本文中的Tracker_ArtifactFactory::getArtifactsByTrackerId方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。