* Adjust project qa menu.

This commit is contained in:
holan20180123
2021-03-22 15:44:19 +08:00
parent faec7af4d6
commit a65793f897
3 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -388,7 +388,7 @@ class bug extends control
$this->bug->setMenu($this->products, $productID, $branch);
/* Init vars. */
$projectID = $this->session->project ? $this->session->project : 0;
$projectID = 0;
$moduleID = 0;
$executionID = 0;
$taskID = 0;
+1 -1
View File
@@ -27,7 +27,7 @@ class bugModel extends model
*/
public function setMenu($products, $productID, $branch = 0, $moduleID = 0, $browseType = 'unclosed', $orderBy = '')
{
$this->loadModel('product')->setMenu($products, $productID, $branch, $moduleID, 'bug');
$this->loadModel('product')->setMenu($productID, $branch, $moduleID, 'bug');
if($this->lang->navGroup->testcase == 'project' and $this->app->methodName == 'browse') $products = array(0 => $this->lang->bug->allProduct) + $products;
$selectHtml = $this->product->select($products, $productID, 'bug', 'browse', '', $branch, $moduleID, 'bug');
+3 -3
View File
@@ -75,7 +75,7 @@ class productModel extends model
$this->app->loadLang('product');
if(!$isProjectBug and !$productID)
{
unset($this->lang->product->setMenu->branch);
unset($this->lang->product->menu->settings['subMenu']->branch);
return;
}
$isMobile = $this->app->viewType == 'mhtml';
@@ -99,11 +99,11 @@ class productModel extends model
$output .= "</div></div>";
if($isMobile) $output = "<a id='currentItem' href=\"javascript:showSearchMenu('product', '$productID', '$currentModule', '$currentMethod', '$extra')\"><span class='text'>{$currentProduct->name}</span> <span class='icon-caret-down'></span></a><div id='currentItemDropMenu' class='hidden affix enter-from-bottom layer'></div>";
if($currentProduct->type == 'normal') unset($this->lang->product->setMenu->branch);
if($currentProduct->type == 'normal') unset($this->lang->product->menu->settings['subMenu']->branch);
if($currentProduct->type != 'normal' && $currentModule != 'programplan')
{
$this->lang->product->branch = $this->lang->product->branchName[$currentProduct->type];
$this->lang->product->setMenu->branch = str_replace('@branch@', $this->lang->product->branch, $this->lang->product->setMenu->branch);
$this->lang->product->menu->settings['subMenu']->branch = str_replace('@branch@', $this->lang->product->branch, $this->lang->product->menu->settings['subMenu']->branch);
$branches = $this->loadModel('branch')->getPairs($productID);
$branchName = isset($branches[$branch]) ? $branches[$branch] : $branches[0];