diff --git a/module/bug/model.php b/module/bug/model.php index cd3323089e..8e8b91b1a1 100644 --- a/module/bug/model.php +++ b/module/bug/model.php @@ -2497,7 +2497,7 @@ class bugModel extends model } $allBranch = "`branch` = 'all'"; - if($branch !== 'all' and strpos($bugQuery, '`branch` =') === false) $bugQuery .= " AND `branch` in('0','$branch')"; + if($branch !== 'all' and strpos($bugQuery, '`branch` =') === false) $bugQuery .= " AND `branch` in('$branch')"; if(strpos($bugQuery, $allBranch) !== false) $bugQuery = str_replace($allBranch, '1', $bugQuery); $allProject = "`project` = 'all'"; diff --git a/module/product/model.php b/module/product/model.php index ea58225170..427af5550a 100644 --- a/module/product/model.php +++ b/module/product/model.php @@ -160,6 +160,7 @@ class productModel extends model $this->cookie->set('preBranch', 0); setcookie('preBranch', 0, $this->config->cookieLife, $this->config->webRoot, '', $this->config->cookieSecure, true); } + } return $this->session->product; } diff --git a/module/testcase/model.php b/module/testcase/model.php index d13f0ddbfe..ad374b9e53 100644 --- a/module/testcase/model.php +++ b/module/testcase/model.php @@ -510,7 +510,7 @@ class testcaseModel extends model } $allBranch = "`branch` = 'all'"; - if($branch !== 'all' and strpos($caseQuery, '`branch` =') === false) $caseQuery .= " AND `branch` in('0','$branch')"; + if($branch !== 'all' and strpos($caseQuery, '`branch` =') === false) $caseQuery .= " AND `branch` in('$branch')"; if(strpos($caseQuery, $allBranch) !== false) $caseQuery = str_replace($allBranch, '1', $caseQuery); $caseQuery .= ')'; $caseQuery = str_replace('`version`', 't1.`version`', $caseQuery);