* Change the configuration $config->datatable->{$module$method}->showModule to $config->$module->$method->showModule.
This commit is contained in:
+1
-1
@@ -1082,7 +1082,7 @@ class bugZen extends bug
|
||||
if($bug->toTask) $taskIdList[$bug->toTask] = $bug->toTask;
|
||||
}
|
||||
|
||||
$showModule = !empty($this->config->datatable->bugBrowse->showModule) ? $this->config->datatable->bugBrowse->showModule : '';
|
||||
$showModule = !empty($this->config->bug->browse->showModule) ? $this->config->bug->browse->showModule : '';
|
||||
|
||||
/* Set view. */
|
||||
$this->view->title = $product->name . $this->lang->colon . $this->lang->bug->common;
|
||||
|
||||
@@ -186,7 +186,7 @@ class caselib extends control
|
||||
|
||||
$this->loadModel('datatable');
|
||||
$this->loadModel('tree');
|
||||
$showModule = !empty($this->config->datatable->caselibBrowse->showModule) ? $this->config->datatable->caselibBrowse->showModule : '';
|
||||
$showModule = !empty($this->config->caselib->browse->showModule) ? $this->config->caselib->browse->showModule : '';
|
||||
$this->view->modulePairs = $showModule ? $this->tree->getModulePairs($libID, 'caselib', $showModule) : array();
|
||||
|
||||
$this->view->title = $this->lang->caselib->common . $this->lang->colon . $libraries[$libID];
|
||||
|
||||
@@ -59,11 +59,10 @@ class datatable extends control
|
||||
$account = $this->app->user->account;
|
||||
if($account == 'guest') return $this->send(array('result' => 'fail', 'target' => $target, 'message' => 'guest.'));
|
||||
|
||||
$name = 'datatable.' . $this->post->target . '.' . $this->post->name;
|
||||
$this->loadModel('setting')->setItem($account . '.' . $name, $this->post->value);
|
||||
$this->loadModel('setting')->setItem($account . '.' . $this->post->currentModule . '.' . $this->post->currentMethod . '.showModule', $this->post->value);
|
||||
if($this->post->allModule !== false) $this->setting->setItem("$account.execution.task.allModule", $this->post->allModule);
|
||||
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => 'dao error.'));
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
return $this->send(array('result' => 'success', 'closeModal' => true, 'load' => true));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -874,7 +874,7 @@ class execution extends control
|
||||
$productPairs = $this->loadModel('product')->getProductPairsByProject($executionID);
|
||||
|
||||
if(empty($productID)) $productID = (int)key($productPairs);
|
||||
$showModule = !empty($this->config->datatable->executionStory->showModule) ? $this->config->datatable->executionStory->showModule : '';
|
||||
$showModule = !empty($this->config->execution->story->showModule) ? $this->config->execution->story->showModule : '';
|
||||
$modulePairs = $showModule ? $this->tree->getModulePairs($type == 'byproduct' ? $param : 0, 'story', $showModule) : array();
|
||||
|
||||
$createModuleLink = $storyType == 'story' ? 'createStoryLink' : 'createRequirementLink';
|
||||
@@ -1061,7 +1061,7 @@ class execution extends control
|
||||
}
|
||||
$tree = $moduleID ? $this->tree->getByID($moduleID) : '';
|
||||
|
||||
$showModule = !empty($this->config->datatable->executionBug->showModule) ? $this->config->datatable->executionBug->showModule : '';
|
||||
$showModule = !empty($this->config->execution->bug->showModule) ? $this->config->execution->bug->showModule : '';
|
||||
|
||||
/* Assign. */
|
||||
$this->view->title = $execution->name . $this->lang->colon . $this->lang->execution->bug;
|
||||
|
||||
@@ -132,7 +132,7 @@ class product extends control
|
||||
$this->loadModel('tree');
|
||||
$isProjectStory = $this->app->rawModule == 'projectstory';
|
||||
$cookieOrderBy = zget($this->cookie, 'productStoryOrder', 'id_desc');
|
||||
$showModule = !empty($this->config->datatable->productBrowse->showModule) ? $this->config->datatable->productBrowse->showModule : ''; //config->datatable->productBrowse may be undefined.
|
||||
$showModule = !empty($this->config->product->browse->showModule) ? $this->config->product->browse->showModule : '';
|
||||
|
||||
/* Load pager. */
|
||||
$this->app->loadClass('pager', true);
|
||||
|
||||
@@ -936,10 +936,9 @@ class project extends control
|
||||
if($bug->task) $taskIdList[$bug->task] = $bug->task;
|
||||
if($bug->toTask) $taskIdList[$bug->toTask] = $bug->toTask;
|
||||
}
|
||||
$storyList = $storyIdList ? $this->loadModel('story')->getByList($storyIdList) : array();
|
||||
$taskList = $taskIdList ? $this->loadModel('task')->getByIdList($taskIdList) : array();
|
||||
|
||||
$showModule = !empty($this->config->datatable->projectBug->showModule) ? $this->config->datatable->projectBug->showModule : '';
|
||||
$storyList = $storyIdList ? $this->loadModel('story')->getByList($storyIdList) : array();
|
||||
$taskList = $taskIdList ? $this->loadModel('task')->getByIdList($taskIdList) : array();
|
||||
$showModule = !empty($this->config->project->bug->showModule) ? $this->config->project->bug->showModule : '';
|
||||
|
||||
/* Assign. */
|
||||
$this->view->title = $title;
|
||||
|
||||
@@ -217,7 +217,7 @@ class testcase extends control
|
||||
$searchProducts = $this->product->getPairs('', 0, '', 'all');
|
||||
$this->testcase->buildSearchForm($productID, $searchProducts, $queryID, $actionURL, $projectID);
|
||||
|
||||
$showModule = !empty($this->config->datatable->testcaseBrowse->showModule) ? $this->config->datatable->testcaseBrowse->showModule : '';
|
||||
$showModule = !empty($this->config->testcase->browse->showModule) ? $this->config->testcase->browse->showModule : '';
|
||||
|
||||
/* Get module tree.*/
|
||||
if($projectID and empty($productID))
|
||||
|
||||
Reference in New Issue
Block a user