You are here

public function views_many_to_one_helper::get_field in Views (for Drupal 7) 7.3

Same name and namespace in other branches
  1. 6.3 includes/handlers.inc \views_many_to_one_helper::get_field()
  2. 6.2 includes/handlers.inc \views_many_to_one_helper::get_field()

Provide an option to use a formula.

If it wants us to do this, it must set $helper->formula = TRUE and implement handler->get_formula();.

1 call to views_many_to_one_helper::get_field()
views_many_to_one_helper::add_filter in includes/handlers.inc

File

includes/handlers.inc, line 852
Defines the various handler objects to help build and display views.

Class

views_many_to_one_helper
This many to one helper object is used on both arguments and filters.

Code

public function get_field() {
  if (!empty($this->formula)) {
    return $this->handler
      ->get_formula();
  }
  else {
    return $this->handler->table_alias . '.' . $this->handler->real_field;
  }
}