NeutralPathAliasListBuilder.php in Language neutral aliases 8.2
File
src/NeutralPathAliasListBuilder.php
View source
<?php
namespace Drupal\language_neutral_aliases;
use Drupal\Core\Language\LanguageInterface;
use Drupal\path\PathAliasListBuilder;
class NeutralPathAliasListBuilder extends PathAliasListBuilder {
protected function getEntityIds() {
$query = $this
->getStorage()
->getQuery();
$search = $this->currentRequest->query
->get('search');
$query
->condition('langcode', LanguageInterface::LANGCODE_NOT_SPECIFIED);
if ($search) {
$query
->condition('alias', $search, 'CONTAINS');
}
if ($this->limit) {
$query
->pager($this->limit);
}
$header = $this
->buildHeader();
$query
->tableSort($header);
return $query
->execute();
}
}