Révision 5d12d676
Ajouté par Assos Assos il y a environ 6 ans
drupal7/sites/all/modules/views/modules/taxonomy/views_handler_argument_term_node_tid.inc | ||
---|---|---|
11 | 11 |
* @ingroup views_argument_handlers |
12 | 12 |
*/ |
13 | 13 |
class views_handler_argument_term_node_tid extends views_handler_argument_many_to_one { |
14 |
function option_definition() { |
|
14 |
|
|
15 |
/** |
|
16 |
* {@inheritdoc} |
|
17 |
*/ |
|
18 |
public function option_definition() { |
|
15 | 19 |
$options = parent::option_definition(); |
16 | 20 |
$options['set_breadcrumb'] = array('default' => FALSE, 'bool' => TRUE); |
17 | 21 |
return $options; |
18 | 22 |
} |
19 | 23 |
|
20 |
function options_form(&$form, &$form_state) { |
|
24 |
/** |
|
25 |
* {@inheritdoc} |
|
26 |
*/ |
|
27 |
public function options_form(&$form, &$form_state) { |
|
21 | 28 |
parent::options_form($form, $form_state); |
22 | 29 |
$form['set_breadcrumb'] = array( |
23 | 30 |
'#type' => 'checkbox', |
... | ... | |
27 | 34 |
); |
28 | 35 |
} |
29 | 36 |
|
30 |
function set_breadcrumb(&$breadcrumb) { |
|
37 |
/** |
|
38 |
* {@inheritdoc} |
|
39 |
*/ |
|
40 |
public function set_breadcrumb(&$breadcrumb) { |
|
31 | 41 |
if (empty($this->options['set_breadcrumb']) || !is_numeric($this->argument)) { |
32 | 42 |
return; |
33 | 43 |
} |
... | ... | |
35 | 45 |
return views_taxonomy_set_breadcrumb($breadcrumb, $this); |
36 | 46 |
} |
37 | 47 |
|
38 |
function title_query() { |
|
48 |
/** |
|
49 |
* {@inheritdoc} |
|
50 |
*/ |
|
51 |
public function title_query() { |
|
39 | 52 |
$titles = array(); |
40 | 53 |
$result = db_select('taxonomy_term_data', 'td') |
41 | 54 |
->addTag('taxonomy_term_access') |
... | ... | |
47 | 60 |
} |
48 | 61 |
return $titles; |
49 | 62 |
} |
63 |
|
|
50 | 64 |
} |
Formats disponibles : Unified diff
Weekly update of contrib modules