diff --git a/module/execution/control.php b/module/execution/control.php index c754ee17fa..c3fcece2cf 100644 --- a/module/execution/control.php +++ b/module/execution/control.php @@ -42,7 +42,7 @@ class execution extends control if(defined('IN_UPGRADE') and IN_UPGRADE) return false; $this->executions = $this->execution->getPairs(0, 'all', 'nocode'); - $skipCreateStep = array('computeburn', 'ajaxgetdropmenu', 'executionkanban', 'ajaxgetteammembers'); + $skipCreateStep = array('computeburn', 'ajaxgetdropmenu', 'executionkanban', 'ajaxgetteammembers', 'all'); if(!in_array($this->methodName, $skipCreateStep) and $this->app->tab == 'execution') { if(!$this->executions and $this->methodName != 'index' and $this->methodName != 'create' and $this->app->getViewType() != 'mhtml') $this->locate($this->createLink('execution', 'create')); diff --git a/module/product/control.php b/module/product/control.php index 7f786e0f95..c874536119 100644 --- a/module/product/control.php +++ b/module/product/control.php @@ -30,8 +30,8 @@ class product extends control $this->loadModel('user'); /* Get all products, if no, goto the create page. */ - $this->products = $this->product->getPairs('nocode'); - if($this->app->viewType !== 'json' and empty($this->products) and strpos(',create,index,showerrornone,ajaxgetdropmenu,kanban', $this->methodName) === false and $this->app->getViewType() != 'mhtml') $this->locate($this->createLink('product', 'create')); + $this->products = $this->product->getPairs('nocode|all'); + if(empty($this->products) and strpos(',create,index,showerrornone,ajaxgetdropmenu,kanban,all', $this->methodName) === false and $this->app->getViewType() != 'mhtml') $this->locate($this->createLink('product', 'create')); $this->view->products = $this->products; } diff --git a/module/qa/model.php b/module/qa/model.php index c128e4d35f..f69a0797b7 100644 --- a/module/qa/model.php +++ b/module/qa/model.php @@ -33,7 +33,7 @@ class qaModel extends model setcookie('preBranch', $branch, $this->config->cookieLife, $this->config->webRoot, '', $this->config->cookieSecure, true); $product = $this->loadModel('product')->getById($productID); - if($product->type != 'normal') $this->lang->product->branch = sprintf($this->lang->product->branch, $this->lang->product->branchName[$product->type]); + if($product and $product->type != 'normal') $this->lang->product->branch = sprintf($this->lang->product->branch, $this->lang->product->branchName[$product->type]); if(!in_array($this->app->rawModule, $this->config->qa->noDropMenuModule)) $this->lang->switcherMenu = $this->product->getSwitcher($productID, $extra, $branch); if($this->app->rawModule == 'product' and $this->app->rawMethod == 'showerrornone') $this->lang->switcherMenu = '';