Build the info for the summary query.
This must:
The alias used to get the number of records (count) for this entry.
Overrides ArgumentPluginBase::summary_query
function summary_query() {
$field = $this->table . '.' . $this->field;
$join = $this
->getJoin();
if (!empty($this->options['require_value'])) {
$join->type = 'INNER';
}
if (empty($this->options['add_table']) || empty($this->view->many_to_one_tables[$field])) {
$this->tableAlias = $this->query
->ensure_table($this->table, $this->relationship, $join);
}
else {
$this->tableAlias = $this->helper
->summary_join();
}
// Add the field.
$this->base_alias = $this->query
->add_field($this->tableAlias, $this->realField);
$this
->summary_name_field();
return $this
->summary_basics();
}