* finish task #3009.

This commit is contained in:
wangyidong
2017-05-04 15:38:43 +08:00
parent eb059f46fa
commit 6c98c6cb82
2 changed files with 54 additions and 47 deletions
+9
View File
@@ -24,6 +24,15 @@ class testreportModel extends model
{
$this->loadModel('product')->setMenu($products, $productID, $branch);
$selectHtml = $this->product->select($products, $productID, 'testreport', 'browse', '', $branch);
/* Remove branch. */
if(strpos($selectHtml, 'currentBranch') !== false)
{
$selectHtml = substr($selectHtml, 0, strpos($selectHtml, 'currentBranch'));
$selectHtml = substr($selectHtml, 0, strrpos($selectHtml, '<'));
if(strpos($selectHtml, '</li>') !== false) $selectHtml = substr($selectHtml, 0, strrpos($selectHtml, '</li>'));
}
foreach($this->lang->testtask->menu as $key => $value)
{
$replace = ($key == 'product') ? $selectHtml : $productID;