diff --git a/workflow/engine/classes/class.applications.php b/workflow/engine/classes/class.applications.php index 4308c16e6..22a898018 100644 --- a/workflow/engine/classes/class.applications.php +++ b/workflow/engine/classes/class.applications.php @@ -3,7 +3,7 @@ class Applications { - public function getAll($userUid, $start=null, $limit=null, $action=null, $filter=null, $search=null, $process=null, $category=null, $user=null, $status=null, $type=null, $dateFrom=null, $dateTo=null, $callback=null, $dir=null, $sort='APP_CACHE_VIEW.APP_NUMBER') + public function getAll($userUid, $start=null, $limit=null, $action=null, $filter=null, $search=null, $process=null, $user=null, $status=null, $type=null, $dateFrom=null, $dateTo=null, $callback=null, $dir=null, $sort='APP_CACHE_VIEW.APP_NUMBER', $category=null) { $callback = isset($callback) ? $callback : 'stcCallback1001'; $dir = isset($dir) ? $dir : 'DESC'; @@ -130,19 +130,19 @@ class Applications // add the category filter if ($category != '') { $Criteria->addAlias('CP', 'PROCESS'); - $Criteria->add ('CP.PRO_CATEGORY', $category, Criteria::EQUAL ); + $Criteria->add('CP.PRO_CATEGORY', $category, Criteria::EQUAL ); $Criteria->addJoin(AppCacheViewPeer::PRO_UID, 'CP.PRO_UID', Criteria::LEFT_JOIN); $Criteria->addAsColumn('CATEGORY_UID', 'CP.PRO_CATEGORY'); } // add the user filter if ( $user != '' ) { - $Criteria->add (AppCacheViewPeer::USR_UID, $user, Criteria::EQUAL ); + $Criteria->add(AppCacheViewPeer::USR_UID, $user, Criteria::EQUAL ); $CriteriaCount->add (AppCacheViewPeer::USR_UID, $user, Criteria::EQUAL ); } if ( $status != '' ) { - $Criteria->add (AppCacheViewPeer::APP_STATUS, $status, Criteria::EQUAL ); + $Criteria->add(AppCacheViewPeer::APP_STATUS, $status, Criteria::EQUAL ); $CriteriaCount->add (AppCacheViewPeer::APP_STATUS, $status, Criteria::EQUAL ); } @@ -268,7 +268,7 @@ class Applications //case 1. when the SEARCH action is selected and none filter, search criteria is defined, //we need to count using the table APPLICATION, because APP_CACHE_VIEW takes 3 seconds - if ( $action == 'search' && $filter == '' && $search == '' && $process == '' && $category == '' && $status == '' && $dateFrom == '' && $dateTo == '') { + if ( $action == 'search' && $filter == '' && $search == '' && $process == '' && $status == '' && $dateFrom == '' && $dateTo == '' && $category == '') { $totalCount = $oAppCache->getSearchAllCount(); $doCountAlreadyExecuted = true; } diff --git a/workflow/engine/methods/cases/casesListExtJs.php b/workflow/engine/methods/cases/casesListExtJs.php index c71ecbd27..5fa9a4c3c 100755 --- a/workflow/engine/methods/cases/casesListExtJs.php +++ b/workflow/engine/methods/cases/casesListExtJs.php @@ -85,20 +85,20 @@ $users = getUserArray($action, $userUid ); $allUsers = getAllUsersArray($action); - $oHeadPublisher->assign( 'reassignReaderFields', $reassignReaderFields ); //sending the fields to get from proxy - $oHeadPublisher->addExtJsScript('cases/reassignList', false ); - $oHeadPublisher->assign( 'pageSize', $pageSize ); //sending the page size - $oHeadPublisher->assign( 'columns', $columns ); //sending the columns to display in grid - $oHeadPublisher->assign( 'readerFields', $readerFields ); //sending the fields to get from proxy - $oHeadPublisher->assign( 'reassignColumns', $reassignColumns ); //sending the columns to display in grid - $oHeadPublisher->assign( 'action', $action ); //sending the fields to get from proxy - $oHeadPublisher->assign( 'PMDateFormat', $dateFormat ); //sending the fields to get from proxy - $oHeadPublisher->assign( 'statusValues', $status ); //sending the columns to display in grid - $oHeadPublisher->assign( 'processValues', $processes); //sending the columns to display in grid - $oHeadPublisher->assign( 'solrConf', System::solrEnv()); //sending the columns to display in grid - $oHeadPublisher->assign( 'categoryValues', $category); //sending the columns to display in grid - $oHeadPublisher->assign( 'userValues', $users); //sending the columns to display in grid - $oHeadPublisher->assign( 'allUsersValues',$allUsers); //sending the columns to display in grid + $oHeadPublisher->assign('reassignReaderFields', $reassignReaderFields ); //sending the fields to get from proxy + $oHeadPublisher->addExtJsScript('cases/reassignList', false); + $oHeadPublisher->assign('pageSize', $pageSize); //sending the page size + $oHeadPublisher->assign('columns', $columns); //sending the columns to display in grid + $oHeadPublisher->assign('readerFields', $readerFields); //sending the fields to get from proxy + $oHeadPublisher->assign('reassignColumns', $reassignColumns); //sending the columns to display in grid + $oHeadPublisher->assign('action', $action); //sending the action to make + $oHeadPublisher->assign('PMDateFormat', $dateFormat); //sending the fields to get from proxy + $oHeadPublisher->assign('statusValues', $status); //Sending the listing of status + $oHeadPublisher->assign('processValues', $processes); //Sending the listing of processes + $oHeadPublisher->assign('solrConf', System::solrEnv()); //Sending the status of solar + $oHeadPublisher->assign('categoryValues', $category); //Sending the listing of categories + $oHeadPublisher->assign('userValues', $users); //Sending the listing of users + $oHeadPublisher->assign('allUsersValues',$allUsers); //Sending the listing of all users diff --git a/workflow/engine/methods/cases/casesList_Ajax.php b/workflow/engine/methods/cases/casesList_Ajax.php index cbd1b5c11..de1a81eca 100755 --- a/workflow/engine/methods/cases/casesList_Ajax.php +++ b/workflow/engine/methods/cases/casesList_Ajax.php @@ -118,7 +118,7 @@ $cProcess->setDistinct(AppCacheViewPeer::PRO_UID); if ($categoryUid) { $cProcess->addAlias('CP', 'PROCESS'); - $cProcess->add ('CP.PRO_CATEGORY', $categoryUid, Criteria::EQUAL ); + $cProcess->add('CP.PRO_CATEGORY', $categoryUid, Criteria::EQUAL ); $cProcess->addJoin(AppCacheViewPeer::PRO_UID, 'CP.PRO_UID', Criteria::LEFT_JOIN); $cProcess->addAsColumn('CATEGORY_UID', 'CP.PRO_CATEGORY'); } diff --git a/workflow/engine/methods/cases/proxyCasesList.php b/workflow/engine/methods/cases/proxyCasesList.php index ab220892a..501828b13 100755 --- a/workflow/engine/methods/cases/proxyCasesList.php +++ b/workflow/engine/methods/cases/proxyCasesList.php @@ -68,7 +68,6 @@ try { $filter, $search, $process, - $category, $user, $status, $type, @@ -76,7 +75,8 @@ try { $dateTo, $callback, $dir, - $sort + $sort, + $category ); $result = G::json_encode($data);