public function gmap_plugin_style_gmap::query in GMap Module 7.2
Same name and namespace in other branches
- 6.2 gmap_plugin_style_gmap.inc \gmap_plugin_style_gmap::query()
- 6 gmap_plugin_style_gmap.inc \gmap_plugin_style_gmap::query()
- 7 gmap_plugin_style_gmap.inc \gmap_plugin_style_gmap::query()
Query method.
Overrides views_plugin_style::query
File
- ./
gmap_plugin_style_gmap.inc, line 68 - GMap style plugin.
Class
Code
public function query() {
parent::query();
if ($this->options['datasource'] == 'location') {
$table = $this->view->query
->ensure_table('location');
$this->view->query
->add_field($table, 'latitude', 'gmap_lat');
$this->view->query
->add_field($table, 'longitude', 'gmap_lon');
}
if ($this->options['markers'] == 'nodetype') {
$this->view->query
->add_field('node', 'type', 'gmap_node_type');
}
elseif ($this->options['markers'] == 'taxonomy') {
$this->view->query
->add_field('gmap_taxonomy_node', 'marker', 'gmap_node_marker');
}
elseif ($this->options['markers'] == 'userrole') {
$this->view->query
->add_field('users_roles', 'rid', 'gmap_role_marker');
}
if (isset($this->row_plugin)) {
$this->row_plugin
->query();
}
}