diff --git a/module/bug/model.php b/module/bug/model.php
index 0286b8e7c6..9fa20e91d3 100644
--- a/module/bug/model.php
+++ b/module/bug/model.php
@@ -1602,7 +1602,7 @@ class bugModel extends model
* @access public
* @return array
*/
- public function getProductLeftBugs($build, $productID, $branch = 0, $linkedBugs = '', $pager = null)
+ public function getProductLeftBugs($build, $productID, $branch = '', $linkedBugs = '', $pager = null)
{
$build = $this->dao->select('*')->from(TABLE_BUILD)->where('id')->eq($build)->fetch();
if(empty($build->execution)) return array();
@@ -1625,7 +1625,7 @@ class bugModel extends model
->andWhere("(status = 'active' OR resolvedDate > '{$execution->end}')")
->andWhere('openedBuild')->notin($beforeBuilds)
->beginIF($linkedBugs)->andWhere('id')->notIN($linkedBugs)->fi()
- ->beginIF($branch)->andWhere('branch')->in("0,$branch")->fi()
+ ->beginIF($branch !== '')->andWhere('branch')->in("0,$branch")->fi()
->page($pager)
->fetchAll();
diff --git a/module/execution/view/manageproducts.html.php b/module/execution/view/manageproducts.html.php
index d8a541e052..433deed8dd 100644
--- a/module/execution/view/manageproducts.html.php
+++ b/module/execution/view/manageproducts.html.php
@@ -38,7 +38,7 @@
";?>
-
+
diff --git a/module/project/view/manageproducts.html.php b/module/project/view/manageproducts.html.php
index 6611b6a6fe..e4b6ca5b82 100644
--- a/module/project/view/manageproducts.html.php
+++ b/module/project/view/manageproducts.html.php
@@ -37,7 +37,7 @@
";?>
-
+
diff --git a/module/release/control.php b/module/release/control.php
index cb129661fb..76bce38036 100644
--- a/module/release/control.php
+++ b/module/release/control.php
@@ -438,7 +438,7 @@ class release extends control
if($browseType == 'bySearch' or $build->execution == 0)
{
- $allStories = $this->story->getBySearch($release->product, $release->branch, $queryID, 'id', $build->execution ? $build->execution : '', 'story', $release->stories, $pager);
+ $allStories = $this->story->getBySearch($release->product, "0,{$release->branch}", $queryID, 'id', $build->execution ? $build->execution : '', 'story', $release->stories, $pager);
}
else
{
@@ -558,7 +558,7 @@ class release extends control
$allBugs = array();
$releaseBugs = $type == 'bug' ? $release->bugs : $release->leftBugs;
- if($browseType == 'bySearch')
+ if($browseType == 'bySearch' or $build->execution == 0)
{
$allBugs = $this->bug->getBySearch($release->product, $release->branch, $queryID, 'id_desc', $releaseBugs, $pager);
}