+ Add qa, bug, testcase, testtask of project module.

This commit is contained in:
zhujinyong
2021-03-21 17:44:25 +08:00
parent 6582a700bb
commit 4ebd5e6cc1
10 changed files with 692 additions and 12 deletions
+22
View File
@@ -264,6 +264,28 @@ class testcaseModel extends model
->fetchAll('id');
}
/**
* Get project cases.
*
* @param int $projectID
* @param string $orderBy
* @param object $pager
* @param string $browseType
* @access public
* @return array
*/
public function getProjectCases($projectID, $orderBy = 'id_desc', $pager = null, $browseType = '')
{
return $this->dao->select('distinct t1.*, t2.*')->from(TABLE_PROJECTCASE)->alias('t1')
->leftJoin(TABLE_CASE)->alias('t2')->on('t1.case=t2.id')
->where('t1.project')->eq((int)$projectID)
->beginIF($browseType != 'all')->andWhere('t2.status')->eq($browseType)->fi()
->andWhere('t2.deleted')->eq('0')
->orderBy($orderBy)
->page($pager)
->fetchAll('id');
}
/**
* Get execution cases.
*