You are here

public static function OpignoGroupManagedLink::loadByProperties in Opigno group manager 3.x

Same name and namespace in other branches
  1. 8 src/Entity/OpignoGroupManagedLink.php \Drupal\opigno_group_manager\Entity\OpignoGroupManagedLink::loadByProperties()

Load one or more LPManagedLink filtered by the properties given in param.

The available properties are the entity_keys specified in the header of this class.

Best is to avoid to use this method and create a specific method for your search, like the method LPManagedContent::loadByLearningPathId.

Parameters

array $properties: The properties to search for.

Return value

\Drupal\Core\Entity\EntityInterface[]|self[] LPManagedLink objects.

Throws

\Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException

\Drupal\Component\Plugin\Exception\PluginNotFoundException

See also

LPManagedContent::loadByLearningPathId()

5 calls to OpignoGroupManagedLink::loadByProperties()
OpignoGroupManagedContent::delete in src/Entity/OpignoGroupManagedContent.php
Deletes the content from database.
OpignoGroupManagedContent::getChildrenLinks in src/Entity/OpignoGroupManagedContent.php
Returns children links.
OpignoGroupManagedContent::getParentsLinks in src/Entity/OpignoGroupManagedContent.php
Returns parents links.
OpignoGroupManagerController::removeLink in src/Controller/OpignoGroupManagerController.php
Removes a link.
OpignoGroupManagerController::updateLink in src/Controller/OpignoGroupManagerController.php
Update a link minimum score to go to next step.

File

src/Entity/OpignoGroupManagedLink.php, line 308

Class

OpignoGroupManagedLink
Defines the Opigno Group Link entity.

Namespace

Drupal\opigno_group_manager\Entity

Code

public static function loadByProperties(array $properties) {
  return \Drupal::entityTypeManager()
    ->getStorage('opigno_group_link')
    ->loadByProperties($properties);
}