diff --git a/module/testcase/control.php b/module/testcase/control.php index f4d7f4dae4..e34a74d96c 100644 --- a/module/testcase/control.php +++ b/module/testcase/control.php @@ -875,6 +875,18 @@ class testcase extends control } } + if(!isset($moduleOptionMenu[$case->module])) + { + $caseModule = '/'; + $modulePath = $this->tree->getParents($case->module); + foreach($modulePath as $key => $module) + { + $caseModule .= $module->name; + if(isset($modulePath[$key + 1])) $caseModule .= '/'; + } + $moduleOptionMenu[$case->module] = $caseModule; + } + /* Get product and branches. */ $product = $this->product->getById($productID); if($this->app->tab == 'execution' or $this->app->tab == 'project') diff --git a/module/testcase/view/batchedit.html.php b/module/testcase/view/batchedit.html.php index 457ed17dd7..f94d9737ad 100644 --- a/module/testcase/view/batchedit.html.php +++ b/module/testcase/view/batchedit.html.php @@ -86,6 +86,19 @@ $modules[$caseProductID][$caseBranch] = $this->tree->getOptionMenu($cases[$caseID]->product, 'case', 0, $caseBranch); } + $caseProductID = isset($caseProductID) ? $caseProductID : $productID; + $moduleList = $modules[$caseProductID]; + if(!isset($moduleList[$caseBranch])) + { + $caseModule = '/'; + $modulePath = $this->tree->getParents($cases[$caseID]->module); + foreach($modulePath as $key => $module) + { + $caseModule .= $module->name; + if(isset($modulePath[$key + 1])) $caseModule .= '/'; + } + $moduleList[$caseBranch] = $modules[$caseProductID][0] + array($cases[$caseID]->module => $caseModule); + } ?>