changed CaseInvolvement to reference case provisions
This commit is contained in:
parent
240a55f54f
commit
6069ac0901
@ -10,8 +10,11 @@ class CaseInvolvement {
|
||||
|
||||
public static function userIsInvolved($account, $case) {
|
||||
$actorId = self::getLinkedActorId($account);
|
||||
$involvedIds = array_column($case->actors_involved->getValue(), 'target_id');
|
||||
return in_array($actorId, $involvedIds);
|
||||
$query = \Drupal::entityQuery('oc_case_provision')
|
||||
->condition('provider', $actorId)
|
||||
->condition('case', $case);
|
||||
$results = $query->execute();
|
||||
return !empty($results);
|
||||
}
|
||||
|
||||
public static function userIsInvolved_activity($account, $activity) {
|
||||
|
Reference in New Issue
Block a user