smartqueue_domain.views.inc in Smartqueue Domain 7
File
smartqueue_domain.views.inc
View source
<?php
function smartqueue_domain_views_data() {
$data = array();
$data['nodequeue_nodes']['in_domain'] = array(
'title' => t('In Domain'),
'help' => t('Filter to ensure a node IS or IS NOT in the current Domain'),
'filter' => array(
'handler' => 'smartqueue_domain_handler_filter_in_domain',
'label' => t('In Domain'),
),
);
return $data;
}
function smartqueue_domain_views_pre_view(&$view) {
$filters = $view->display_handler
->get_option('filters');
if (isset($filters['in_domian'])) {
$filters['in_domain'] = $filters['in_domian'];
$filters['in_domain']['id'] = 'in_domain';
$filters['in_domain']['field'] = 'in_domain';
unset($filters['in_domian']);
$view->display_handler
->set_option('filters', $filters);
}
}