You are here

public static function LPManagedContent::loadByProperties in Opigno Learning path 3.x

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

Loads one or more LPManagedContent by the properties.

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

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

4 calls to LPManagedContent::loadByProperties()
LearningPathAccess::setLearningPathCourseMember in src/LearningPathAccess.php
Sets Learning Path content course member.
LearningPathManagerController::getItems in src/Controller/LearningPathManagerController.php
This method is called on learning path load.
LearningPathManagerController::getPositions in src/Controller/LearningPathManagerController.php
This function is called on learning path load.
LPManagedContent::loadByLearningPathId in src/Entity/LPManagedContent.php
Load the contents linked to a specific learning path.

File

src/Entity/LPManagedContent.php, line 310

Class

LPManagedContent
Defines the Learning Path Content entity.

Namespace

Drupal\opigno_learning_path\Entity

Code

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