You are here

public function Shortcut::query in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/shortcut/src/Plugin/migrate/source/d7/Shortcut.php \Drupal\shortcut\Plugin\migrate\source\d7\Shortcut::query()
  2. 10 core/modules/shortcut/src/Plugin/migrate/source/d7/Shortcut.php \Drupal\shortcut\Plugin\migrate\source\d7\Shortcut::query()

Return value

\Drupal\Core\Database\Query\SelectInterface

Overrides SqlBase::query

File

core/modules/shortcut/src/Plugin/migrate/source/d7/Shortcut.php, line 20

Class

Shortcut
Drupal 7 shortcut links source from database.

Namespace

Drupal\shortcut\Plugin\migrate\source\d7

Code

public function query() {
  return $this
    ->select('menu_links', 'ml')
    ->fields('ml', [
    'mlid',
    'menu_name',
    'link_path',
    'link_title',
    'weight',
  ])
    ->condition('hidden', '0')
    ->condition('menu_name', 'shortcut-set-%', 'LIKE')
    ->orderBy('ml.mlid');
}