* Modify data for execution list statistics.
This commit is contained in:
@@ -2591,10 +2591,12 @@ class execution extends control
|
||||
$executionID = $execution->id;
|
||||
}
|
||||
$this->session->set('executionList', $this->app->getURI(true));
|
||||
$projectID = 0;
|
||||
}
|
||||
elseif($from == 'project')
|
||||
{
|
||||
$this->lang->navGroup->execution = 'project';
|
||||
$projectID = $this->session->PRJ;
|
||||
}
|
||||
|
||||
/* Load pager and get tasks. */
|
||||
@@ -2604,7 +2606,7 @@ class execution extends control
|
||||
$this->view->title = $this->lang->execution->allExecutions;
|
||||
$this->view->position[] = $this->lang->execution->allExecutions;
|
||||
|
||||
$this->view->executionStats = $this->project->getStats($this->session->PRJ, $status, $productID, 0, 30, $orderBy, $pager);
|
||||
$this->view->executionStats = $this->project->getStats($projectID, $status, $productID, 0, 30, $orderBy, $pager);
|
||||
$this->view->products = array(0 => $this->lang->product->select) + $this->loadModel('product')->getProductPairsByProject($this->session->PRJ);
|
||||
$this->view->productID = $productID;
|
||||
$this->view->executionID = $executionID;
|
||||
|
||||
@@ -896,6 +896,8 @@ class executionModel extends model
|
||||
*/
|
||||
public function getSwitcher($executionID, $currentModule, $currentMethod)
|
||||
{
|
||||
if($currentMethod == 'index' or $currentMethod == 'all') return;
|
||||
|
||||
$this->session->set('moreExecutionLink', $this->app->getURI(true));
|
||||
|
||||
$currentExecutionName = $this->lang->execution->common;
|
||||
|
||||
@@ -1439,7 +1439,8 @@ class projectModel extends model
|
||||
if(empty($productID))
|
||||
{
|
||||
$executions = $this->dao->select('*')->from(TABLE_EXECUTION)
|
||||
->where('project')->eq($projectID)
|
||||
->where('type')->in('sprint,stage')
|
||||
->beginIF($projectID != 0)->andWhere('project')->eq($projectID)->fi()
|
||||
->beginIF($status == 'undone')->andWhere('status')->notIN('done,closed')->fi()
|
||||
->beginIF($status != 'all' and $status != 'undone')->andWhere('status')->eq($status)->fi()
|
||||
->beginIF(!$this->app->user->admin)->andWhere('id')->in($this->app->user->view->sprints)->fi()
|
||||
|
||||
Reference in New Issue
Block a user