public function ForwardStatistics::query in Forward 8.2
Same name and namespace in other branches
- 8.3 src/Plugin/migrate/source/ForwardStatistics.php \Drupal\forward\Plugin\migrate\source\ForwardStatistics::query()
- 8 src/Plugin/migrate/source/ForwardStatistics.php \Drupal\forward\Plugin\migrate\source\ForwardStatistics::query()
- 4.x src/Plugin/migrate/source/ForwardStatistics.php \Drupal\forward\Plugin\migrate\source\ForwardStatistics::query()
- 4.0.x src/Plugin/migrate/source/ForwardStatistics.php \Drupal\forward\Plugin\migrate\source\ForwardStatistics::query()
Return value
\Drupal\Core\Database\Query\SelectInterface
Overrides SqlBase::query
File
- src/
Plugin/ migrate/ source/ ForwardStatistics.php, line 20
Class
- ForwardStatistics
- Forward statistics source.
Namespace
Drupal\forward\Plugin\migrate\sourceCode
public function query() {
$query = $this
->select('forward_statistics', 'f');
$query
->join('node', 'n', 'f.nid = n.nid');
$query = $query
->fields('f', [
'nid',
'last_forward_timestamp',
'forward_count',
'clickthrough_count',
])
->fields('n', [
'type',
])
->orderBy('nid');
return $query;
}