You are here

function flag_handler_field_flagged::init in Flag 7.3

Init the handler with necessary data.

Parameters

view $view: The $view object this handler is attached to.

array $options: The item from the database; the actual contents of this will vary based upon the type of handler.

Overrides views_handler_field_boolean::init

File

includes/views/flag_handler_field_flagged.inc, line 15
Contains the boolean flagged field handler.

Class

flag_handler_field_flagged
Views field handler for the flagged field.

Code

function init(&$view, &$options) {
  parent::init($view, $options);

  // Add our boolean labels.
  $this->formats['flag'] = array(
    t('Flagged'),
    t('Not flagged'),
  );

  // TODO: We could probably lift the '(Un)Flagged message' strings from the
  // flag object, but a) we need to lift that from the relationship we're on
  // and b) they will not necessarily make sense in a static context.
}