1
|
<?php
|
2
|
|
3
|
/**
|
4
|
* @file
|
5
|
* Definition of views_handler_filter_system_type.
|
6
|
*/
|
7
|
|
8
|
/**
|
9
|
* Filter by system type.
|
10
|
*/
|
11
|
class views_handler_filter_system_type extends views_handler_filter_in_operator {
|
12
|
|
13
|
/**
|
14
|
* {@inheritdoc}
|
15
|
*/
|
16
|
public function get_value_options() {
|
17
|
if (!isset($this->value_options)) {
|
18
|
$this->value_title = t('Type');
|
19
|
// Enable filtering by type.
|
20
|
$types = array();
|
21
|
$types = db_query('SELECT DISTINCT(type) FROM {system} ORDER BY type')->fetchAllKeyed(0, 0);
|
22
|
$this->value_options = $types;
|
23
|
}
|
24
|
}
|
25
|
|
26
|
}
|