* Fix create a bug navgation when the system don't have any product.
This commit is contained in:
@@ -73,7 +73,7 @@ class bug extends control
|
||||
$products = $this->product->getPairs($mode, 0, '', 'all');
|
||||
}
|
||||
|
||||
if(empty($products) and !helper::isAjaxRequest()) $this->locate($this->createLink('product', 'showErrorNone', "moduleName=$tab&activeMenu=bug&objectID=$objectID"));
|
||||
if(empty($products) and substr($this->app->rawMethod, 0, 4) != 'ajax') $this->locate($this->createLink('product', 'showErrorNone', "moduleName=$tab&activeMenu=bug&objectID=$objectID"));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -42,7 +42,7 @@ div
|
||||
(
|
||||
setClass('btn ghost text-primary'),
|
||||
set::href($link),
|
||||
set('data-app', $app->tab),
|
||||
setData('app', $tab),
|
||||
icon('plus'),
|
||||
$text
|
||||
)
|
||||
|
||||
@@ -530,10 +530,10 @@ class productZen extends product
|
||||
$moduleName = $tab == 'program' ? 'program' : $this->moduleName;
|
||||
$methodName = $tab == 'program' ? 'product' : 'browse';
|
||||
$param = $tab == 'program' ? "programID=$programID" : "productID=$productID";
|
||||
$location = isonlybody() ? 'true' : $this->createLink($moduleName, $methodName, $param);
|
||||
$location = isInModal() ? 'true' : $this->createLink($moduleName, $methodName, $param);
|
||||
if($tab == 'doc') $location = $this->createLink('doc', 'productSpace', "objectID=$productID");
|
||||
|
||||
return array('result' => 'success', 'message' => $this->lang->saveSuccess, 'load' => $location);
|
||||
return array('result' => 'success', 'message' => $this->lang->saveSuccess, 'load' => $location, 'closeModal' => true);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user