Example #1
0
 public function runConfigureProject(framework\Request $request)
 {
     try {
         // Build list of valid targets for the subproject dropdown
         // The following items are banned from the list: current project, children of the current project
         // Any further tests and things get silly, so we will trap it when building breadcrumbs
         $valid_subproject_targets = entities\Project::getValidSubprojects($this->selected_project);
         $content = $this->getComponentHTML('project/projectconfig', array('valid_subproject_targets' => $valid_subproject_targets, 'project' => $this->selected_project, 'access_level' => $this->access_level, 'section' => 'hierarchy'));
         return $this->renderJSON(array('content' => $content));
     } catch (\Exception $e) {
         $this->getResponse()->setHttpStatus(400);
         return $this->renderJSON(array('error' => $e->getMessage()));
     }
 }
Example #2
0
 public function componentProjectInfo()
 {
     $this->valid_subproject_targets = entities\Project::getValidSubprojects($this->project);
 }