public function __construct(Codendi_Request $request, ProjectManager $project_manager, Project_CustomDescription_CustomDescriptionFactory $custom_description_factory) { parent::__construct('project', $request); $this->project_manager = $project_manager; $this->required_custom_descriptions = $custom_description_factory->getRequiredCustomDescriptions(); $this->creation_request = new Project_OneStepCreation_OneStepCreationRequest($request, $project_manager); $this->presenter = new Project_OneStepCreation_OneStepCreationPresenter($this->creation_request, $GLOBALS['LICENSE'], $this->required_custom_descriptions, $project_manager); }
public function __construct(Codendi_Request $request, ProjectManager $project_manager, Project_CustomDescription_CustomDescriptionFactory $custom_description_factory, TroveCatFactory $trove_cat_factory) { parent::__construct('project', $request); $this->project_manager = $project_manager; $this->required_custom_descriptions = $custom_description_factory->getRequiredCustomDescriptions(); $this->trove_cats = $trove_cat_factory->getMandatoryParentCategoriesUnderRootOnlyWhenCategoryHasChildren(); $this->creation_request = new Project_OneStepCreation_OneStepCreationRequest($request, $project_manager); $this->presenter = new Project_OneStepCreation_OneStepCreationPresenter($this->creation_request, $this->required_custom_descriptions, $project_manager, $this->trove_cats); }
/** * Instanciates a new controller. * * TODO: * - pass $request to actions (e.g. show). * * @param Codendi_Request $request * @param PlanningFactory $planning_factory * @param Planning_MilestoneFactory $milestone_factory */ public function __construct(Codendi_Request $request, Planning_MilestoneFactory $milestone_factory, ProjectManager $project_manager) { parent::__construct('agiledashboard', $request); try { $this->milestone_factory = $milestone_factory; $project = $project_manager->getProject($request->get('group_id')); $this->milestone = $this->milestone_factory->getMilestoneWithPlannedArtifactsAndSubMilestones($this->getCurrentUser(), $project, $request->get('planning_id'), $request->get('aid')); } catch (Tracker_Hierarchy_MoreThanOneParentException $e) { $GLOBALS['Response']->addFeedback('error', $e->getMessage(), CODENDI_PURIFIER_LIGHT); } }
public function __construct(Codendi_Request $request) { parent::__construct('user', $request); }
public function __construct(Codendi_Request $request, FullTextSearch_ISearchDocuments $client) { parent::__construct('fulltextsearch', $request); $this->client = $client; }
/** * Renders the top banner + navigation for all Agile Dashboard pages. * * @param MVC2_Controller $controller The controller instance * @param Codendi_Request $request The request * @param string $title The page title */ private function displayHeader(MVC2_Controller $controller, Codendi_Request $request, $title, array $header_options = array()) { $service = $this->getService($request); if (!$service) { exit_error($GLOBALS['Language']->getText('global', 'error'), $GLOBALS['Language']->getText('project_service', 'service_not_used', $GLOBALS['Language']->getText('plugin_agiledashboard', 'service_lbl_key'))); } $toolbar = array(); $breadcrumbs = $controller->getBreadcrumbs($this->plugin->getPluginPath()); if ($this->userIsAdmin($request)) { $toolbar[] = array('title' => $GLOBALS['Language']->getText('global', 'Admin'), 'url' => AGILEDASHBOARD_BASE_URL . '/?' . http_build_query(array('group_id' => $request->get('group_id'), 'action' => 'admin'))); } $service->displayHeader($title, $breadcrumbs->getCrumbs(), $toolbar, $header_options); }
/** * Renders the top banner + navigation for all Agile Dashboard pages. * * @param MVC2_Controller $controller The controller instance * @param Codendi_Request $request The request * @param string $title The page title */ private function displayHeader(MVC2_Controller $controller, Codendi_Request $request, $title) { $breadcrumbs = $controller->getBreadcrumbs($this->plugin->getPluginPath()); $this->getService($request)->displayHeader($title, $breadcrumbs->getCrumbs(), array()); }
public function __construct(Codendi_Request $request, PlanningFactory $planning_factory) { parent::__construct('agiledashboard', $request); $this->group_id = $request->get('group_id'); $this->planning_factory = $planning_factory; }
public function __construct(PlanningFactory $planning_factory, Codendi_Request $request) { parent::__construct('agiledashboard', $request); $this->planning_factory = $planning_factory; }
public function __construct(Codendi_Request $request, Planning_MilestoneFactory $milestone_factory) { parent::__construct('agiledashboard', $request); $this->milestone_factory = $milestone_factory; }