PMCORE-2735

This commit is contained in:
Paula Quispe
2021-01-19 14:00:55 -04:00
parent c48d7a6c16
commit 91b80fe633

View File

@@ -114,7 +114,7 @@ class Participated extends AbstractCases
$filter = $this->getParticipatedStatus(); $filter = $this->getParticipatedStatus();
switch ($filter) { switch ($filter) {
case 'STARTED': case 'STARTED':
// Scope that search for the STARTED by user // Scope that search for the STARTED by user: DRAFT, TO_DO, CANCELED AND COMPLETED
$query->caseStarted(); $query->caseStarted();
break; break;
case 'IN_PROGRESS': case 'IN_PROGRESS':
@@ -136,8 +136,8 @@ class Participated extends AbstractCases
\']\' \']\'
) AS PENDING' ) AS PENDING'
); );
// Only cases in progress // Only cases in progress: TO_DO without DRAFT
$query->caseInProgress(); $query->caseTodo();
// Group by AppNumber // Group by AppNumber
$query->groupBy('APP_NUMBER'); $query->groupBy('APP_NUMBER');
break; break;
@@ -248,14 +248,14 @@ class Participated extends AbstractCases
$filter = $this->getParticipatedStatus(); $filter = $this->getParticipatedStatus();
switch ($filter) { switch ($filter) {
case 'STARTED': case 'STARTED':
// Scope that search for the STARTED by user // Scope that search for the STARTED by user: DRAFT, TO_DO, CANCELED AND COMPLETED
$query->caseStarted(); $query->caseStarted();
break; break;
case 'IN_PROGRESS': case 'IN_PROGRESS':
// Only distinct APP_NUMBER // Only distinct APP_NUMBER
$query->distinct(); $query->distinct();
// Scope for in progress cases // Scope for in progress: TO_DO without DRAFT
$query->statusIds([self::STATUS_DRAFT, self::STATUS_TODO]); $query->caseTodo();
break; break;
case 'COMPLETED': case 'COMPLETED':
// Scope that search for the COMPLETED // Scope that search for the COMPLETED
@@ -285,14 +285,14 @@ class Participated extends AbstractCases
$filter = $this->getParticipatedStatus(); $filter = $this->getParticipatedStatus();
switch ($filter) { switch ($filter) {
case 'STARTED': case 'STARTED':
// Scope that search for the STARTED by user // Scope that search for the STARTED by user: DRAFT, TO_DO, CANCELED AND COMPLETED
$query->caseStarted(); $query->caseStarted();
break; break;
case 'IN_PROGRESS': case 'IN_PROGRESS':
// Only distinct APP_NUMBER // Only distinct APP_NUMBER
$query->distinct(); $query->distinct();
// Scope for in progress cases // Scope for in progress: TO_DO without DRAFT
$query->statusIds([self::STATUS_DRAFT, self::STATUS_TODO]); $query->caseTodo();
break; break;
case 'COMPLETED': case 'COMPLETED':
// Scope that search for the COMPLETED // Scope that search for the COMPLETED