Added total cases to actors

This commit is contained in:
2022-05-08 18:34:02 +01:00
parent b8c592104d
commit b9481d39d5
4 changed files with 49 additions and 0 deletions

View File

@ -10,6 +10,8 @@ use Drupal\Core\Entity\EntityChangedTrait;
use Drupal\Core\Entity\EntityPublishedTrait;
use Drupal\Core\Entity\EntityTypeInterface;
use Drupal\user\UserInterface;
use Drupal\opencase_entities\Entity\OCActor;
use Error;
/**
* Defines the Case Provision entity.
@ -201,6 +203,10 @@ class OCCaseProvision extends EditorialContentEntityBase implements OCCaseProvis
return $this;
}
public function getProvider():?OCActor {
return OCActor::load($this->oc_provider->target_id);
}
/**
* {@inheritdoc}
*/