I solved the issue PM-1649 ./processmaker migrate-new-cases-lists

This commit is contained in:
Paula V. Quispe
2015-03-04 18:42:47 -04:00
parent f4a65aa184
commit 1f497cc6f6
10 changed files with 500 additions and 7 deletions

View File

@@ -149,6 +149,34 @@ class GroupUser extends BaseGroupUser
}
}
return $rows;
}
/**
* Get all users assigned to Group
*
* @param string $gprUid
* @return array $rows
*/
public function getAllGroupUser ($gprUid)
{
$oCriteria = new Criteria( 'workflow' );
$oCriteria->add( GroupUserPeer::GRP_UID, $gprUid );
$oDataset = GroupUserPeer::doSelectRS( $oCriteria );
$oDataset->setFetchmode( ResultSet::FETCHMODE_ASSOC );
$rows = Array ();
while ($oDataset->next()) {
$row = $oDataset->getRow();
$g = new Groupwf();
try {
$grpRow = $g->load( $row['GRP_UID'] );
$row = array_merge( $row, $grpRow );
$rows[] = $row;
} catch (Exception $e) {
continue;
}
}
return $rows;
}
}