Projet

Général

Profil

Paste
Télécharger (624 octets) Statistiques
| Branche: | Révision:

root / drupal7 / sites / all / modules / views / modules / aggregator / views_handler_filter_aggregator_category_cid.inc @ 5d12d676

1
<?php
2

    
3
/**
4
 * @file
5
 * Definition of views_handler_filter_aggregator_category_cid.
6
 */
7

    
8
/**
9
 * Filter by aggregator category cid
10
 *
11
 * @ingroup views_filter_handlers
12
 */
13
class views_handler_filter_aggregator_category_cid extends views_handler_filter_in_operator {
14

    
15
  /**
16
   * {@inheritdoc}
17
   */
18
  public function get_value_options() {
19
    if (isset($this->value_options)) {
20
      return;
21
    }
22

    
23
    $this->value_options = array();
24

    
25
    $result = db_query('SELECT * FROM {aggregator_category} ORDER BY title');
26
    foreach ($result as $category) {
27
      $this->value_options[$category->cid] = $category->title;
28
    }
29
  }
30

    
31
}