You are here

public static function QueryController::getAllEnabledQueries in Lightweight Directory Access Protocol (LDAP) 8.3

Returns all enabled LDAP query entities.

Return value

\Drupal\Core\Entity\EntityInterface[] Entity Queries.

1 call to QueryController::getAllEnabledQueries()
LdapUserAdminForm::buildForm in ldap_user/src/Form/LdapUserAdminForm.php
Form constructor.

File

ldap_query/src/Controller/QueryController.php, line 127

Class

QueryController
Controller class for LDAP queries, in assistance to the entity itself.

Namespace

Drupal\ldap_query\Controller

Code

public static function getAllEnabledQueries() {
  $query = \Drupal::entityQuery('ldap_query_entity')
    ->condition('status', 1);
  $ids = $query
    ->execute();
  return QueryEntity::loadMultiple($ids);
}