diff --git a/module/bug/control.php b/module/bug/control.php index 6c4e7b16ed..4f13759f5d 100644 --- a/module/bug/control.php +++ b/module/bug/control.php @@ -59,7 +59,8 @@ class bug extends control } else { - $products = $this->product->getPairs('', 0, 'program_asc'); + $mode = ($this->app->methodName == 'create' and empty($this->config->CRProduct)) ? 'noclosed' : ''; + $products = $this->product->getPairs($mode, 0, 'program_asc'); } if(empty($products) and !helper::isAjaxRequest()) return print($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$tab&activeMenu=bug&objectID=$objectID"))); } diff --git a/module/common/model.php b/module/common/model.php index 123f2feb1d..06a592add3 100644 --- a/module/common/model.php +++ b/module/common/model.php @@ -399,7 +399,7 @@ class commonModel extends model { $noRole = (!empty($app->user->role) && isset($lang->user->roleList[$app->user->role])) ? '' : ' no-role'; echo '
  • '; - echo "'; + echo "'; echo html::avatar($app->user, '', 'avatar-circle', 'id="menu-avatar"'); echo ''; if(isset($lang->user->roleList[$app->user->role])) echo ''; @@ -407,7 +407,7 @@ class commonModel extends model $vision = $app->config->vision == 'lite' ? 'rnd' : 'lite'; - echo '
  • ' . html::a(helper::createLink('my', 'profile', '', '', true), " " . $lang->profile, '', "class='iframe' data-width='600'") . '
  • '; + echo '
  • ' . html::a(helper::createLink('my', 'profile', '', '', true), " " . $lang->profile, '', "class='iframe' data-width='700'") . '
  • '; if($app->config->vision === 'rnd') { @@ -484,7 +484,9 @@ class commonModel extends model /* The standalone lite version removes the lite interface button */ if(trim($config->visions, ',') == 'lite') return true; - + + if($app->config->systemMode != 'new') return print("
    {$lang->visionList['rnd']}
    "); + if(count($userVisions) < 2) return print("
    {$lang->visionList[$currentVision]}
    "); if(count($configVisions) < 2) return print("
    {$lang->visionList[$currentVision]}
    "); diff --git a/module/product/control.php b/module/product/control.php index 8e67b865b1..e796acf0da 100644 --- a/module/product/control.php +++ b/module/product/control.php @@ -989,7 +989,7 @@ class product extends control if($execution->type == 'kanban') $projectID = $execution->project; } - $executions = $this->product->getExecutionPairsByProduct($productID, $branch, 'id_desc', $projectID); + $executions = $this->product->getExecutionPairsByProduct($productID, $branch, 'id_desc', $projectID, empty($this->config->CRExecution) ? 'noclosed' : ''); if($this->app->getViewType() == 'json') return print(json_encode($executions)); if($number === '') diff --git a/module/product/model.php b/module/product/model.php index e6759d6894..bbe814b283 100644 --- a/module/product/model.php +++ b/module/product/model.php @@ -1184,6 +1184,7 @@ class productModel extends model ->andWhere('t2.project')->eq($projectID) ->beginIF($branch !== '')->andWhere('t1.branch')->in($branch)->fi() ->beginIF(!$this->app->user->admin)->andWhere('t2.id')->in($this->app->user->view->sprints)->fi() + ->beginIF(strpos($mode, 'noclosed') !== false)->andWhere('t2.status')->ne('closed')->fi() ->andWhere('t2.deleted')->eq('0') ->orderBy($orderBy) ->fetchAll('id'); diff --git a/module/testcase/control.php b/module/testcase/control.php index 4d43e1eada..e2572d65ef 100644 --- a/module/testcase/control.php +++ b/module/testcase/control.php @@ -59,7 +59,8 @@ class testcase extends control } else { - $products = $this->product->getPairs(); + $mode = ($this->app->methodName == 'create' and empty($this->config->CRProduct)) ? 'noclosed' : ''; + $products = $this->product->getPairs($mode); } if(empty($products) and !helper::isAjaxRequest()) return print($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$tab&activeMenu=testcase&objectID=$objectID"))); }