SectionAssociationStorage.php in Workbench Access 8
File
src/SectionAssociationStorage.php
View source
<?php
namespace Drupal\workbench_access;
use Drupal\Core\Entity\Sql\SqlContentEntityStorage;
use Drupal\workbench_access\SectionAssociationStorageInterface;
class SectionAssociationStorage extends SqlContentEntityStorage implements SectionAssociationStorageInterface {
public function loadSection($access_scheme_id, $section_id) {
$section = $this
->loadByProperties([
'access_scheme' => $access_scheme_id,
'section_id' => $section_id,
]);
return current($section);
}
}