diff --git a/module/tree/control.php b/module/tree/control.php index 656697ddfa..a265c4a961 100644 --- a/module/tree/control.php +++ b/module/tree/control.php @@ -90,6 +90,18 @@ class tree extends control $position[] = html::a($this->createLink('bug', 'browse', "product=$rootID"), $product->name); $position[] = $this->lang->tree->manageBug; } + elseif($viewType == 'feedback') + { + $this->lang->set('menugroup.tree', 'feedback'); + $this->app->loadLang('feedback'); + $this->lang->tree->menu = $this->lang->feedback->menu; + $root = new stdclass(); + $root->name = $this->lang->feedback->common; + $this->view->root = $root; + + $title = $this->lang->tree->manageFeedback; + $position[] = html::a($this->createLink('feedback', 'admin'), $this->lang->tree->manageFeedback); + } elseif($viewType == 'case') { $this->loadModel('testcase')->setMenu($this->product->getPairs(), $rootID); diff --git a/module/tree/model.php b/module/tree/model.php index c7e17caf12..c1d8e64f78 100644 --- a/module/tree/model.php +++ b/module/tree/model.php @@ -969,6 +969,19 @@ class treeModel extends model if($type == 'case') return html::a(helper::createLink('testcase', 'browse', "productID={$rootID}&branch=$branchID"), $branch, '_self', "id='branch{$branchID}'"); } + /** + * Create link of feedback. + * + * @param string $type + * @param object $module + * @access public + * @return string + */ + public function createFeedbackLink($type, $module) + { + return html::a(helper::createLink('feedback', 'admin', "type=byModule¶m={$module->id}"), $module->name, '_self', "id='module{$module->id}'"); + } + /** * Get sons of a module. *