/** * @return AgileDashboard_Milestone_Pane_Planning_PlanningSubMilestonePresenter */ public function getPlanningSubMilestonePresenter(PFUser $user, Planning_ArtifactMilestone $milestone, $redirect_to_self) { $this->milestone_factory->updateMilestoneContextualInfo($user, $milestone); return new AgileDashboard_Milestone_Pane_Planning_PlanningSubMilestonePresenter($milestone, $redirect_to_self, $user, $this->icon_factory->getIconLinkPresenterCollection($milestone)); }
private function getMilestoneLinkPresenters() { if (!$this->presenters) { $this->presenters = array(); $milestones = $this->milestone_factory->getLastOpenMilestones($this->user, $this->planning, $this->offset, self::NUMBER_TO_DISPLAY + 1); $icon_factory = new AgileDashboard_PaneIconLinkPresenterCollectionFactory($this->pane_info_factory); foreach ($milestones as $milestone) { $this->presenters[] = new Planning_ShortAccessMilestonePresenter($this, $milestone, $icon_factory->getIconLinkPresenterCollection($milestone), $this->milestone_factory, $this->user, $this->theme_path); } if (!empty($this->presenters)) { end($this->presenters)->setIsLatest(); } $this->presenters = array_reverse($this->presenters); } return $this->presenters; }