forked from phase2/oa_core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
oa_core.views.inc
38 lines (34 loc) · 1.24 KB
/
oa_core.views.inc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?php
/**
* @file
* Code for the OpenAtrium Core views alterations.
*/
/**
* Implements hook_views_data_alter
*/
function oa_core_views_data_alter(&$data) {
if (isset($data['og_membership']['og_group_ref_target_id']['filter']['handler'])) {
$data['og_membership']['og_group_ref_target_id']['filter']['handler'] = 'oa_core_og_group_ref_views_handler_filter_in_operator';
}
if (isset($data['og_membership']['oa_parent_space_target_id']['filter']['handler'])) {
$data['og_membership']['oa_parent_space_target_id']['filter']['handler'] = 'oa_core_og_group_ref_views_handler_filter_in_operator';
}
if (isset($data['field_data_oa_section_ref']['oa_section_ref_target_id']['filter']['handler'])) {
$data['field_data_oa_section_ref']['oa_section_ref_target_id']['filter']['handler'] = 'oa_core_oa_section_ref_views_handler_filter_in_operator';
}
}
/**
* Implements hook_views_plugins().
*/
function oa_core_views_plugins() {
return array(
'exposed_form' => array(
'oa_form' => array(
'title' => t('Open Atrium'),
'help' => t('Open Atrium exposed filter form adds some options that integrate with Bootstrap.'),
'handler' => 'oa_views_plugin_exposed_form',
'uses options' => TRUE,
),
),
);
}