Skip to content

Instantly share code, notes, and snippets.

@shirazd
Last active Dec 14, 2015
Embed
What would you like to do?
display name: block
$view = new view();
$view->name = 'cis_communications';
$view->description = '';
$view->tag = 'default';
$view->base_table = 'node';
$view->human_name = 'CIS Communications';
$view->core = 7;
$view->api_version = '3.0';
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */
/* Display: Master */
$handler = $view->new_display('default', 'Master', 'default');
$handler->display->display_options['title'] = 'My Most Recent Communications';
$handler->display->display_options['use_ajax'] = TRUE;
$handler->display->display_options['use_more_always'] = FALSE;
$handler->display->display_options['access']['type'] = 'perm';
$handler->display->display_options['cache']['type'] = 'none';
$handler->display->display_options['query']['type'] = 'views_query';
$handler->display->display_options['query']['options']['query_comment'] = FALSE;
$handler->display->display_options['exposed_form']['type'] = 'basic';
$handler->display->display_options['pager']['type'] = 'mini';
$handler->display->display_options['pager']['options']['items_per_page'] = '20';
$handler->display->display_options['pager']['options']['offset'] = '0';
$handler->display->display_options['pager']['options']['id'] = '5';
$handler->display->display_options['pager']['options']['quantity'] = '9';
$handler->display->display_options['style_plugin'] = 'list';
$handler->display->display_options['row_plugin'] = 'node';
$handler->display->display_options['row_options']['links'] = FALSE;
/* Header: Global: Text area */
$handler->display->display_options['header']['area']['id'] = 'area';
$handler->display->display_options['header']['area']['table'] = 'views';
$handler->display->display_options['header']['area']['field'] = 'area';
$handler->display->display_options['header']['area']['empty'] = TRUE;
$handler->display->display_options['header']['area']['content'] = '<div class="to-block-title">
<a href="/consultation/communication-logs">View All</a>
</div>';
$handler->display->display_options['header']['area']['format'] = 'full_html';
/* No results behavior: Global: Text area */
$handler->display->display_options['empty']['area']['id'] = 'area';
$handler->display->display_options['empty']['area']['table'] = 'views';
$handler->display->display_options['empty']['area']['field'] = 'area';
$handler->display->display_options['empty']['area']['content'] = 'You have no associated Communication Logs';
$handler->display->display_options['empty']['area']['format'] = 'plain_text';
/* Field: Content: Date */
$handler->display->display_options['fields']['field_cis_comm_date']['id'] = 'field_cis_comm_date';
$handler->display->display_options['fields']['field_cis_comm_date']['table'] = 'field_data_field_cis_comm_date';
$handler->display->display_options['fields']['field_cis_comm_date']['field'] = 'field_cis_comm_date';
$handler->display->display_options['fields']['field_cis_comm_date']['settings'] = array(
'format_type' => 'shorter',
'fromto' => 'both',
'multiple_number' => '',
'multiple_from' => '',
'multiple_to' => '',
'show_repeat_rule' => 'show',
);
/* Field: Content: Title */
$handler->display->display_options['fields']['title']['id'] = 'title';
$handler->display->display_options['fields']['title']['table'] = 'node';
$handler->display->display_options['fields']['title']['field'] = 'title';
$handler->display->display_options['fields']['title']['label'] = 'Subject';
$handler->display->display_options['fields']['title']['alter']['word_boundary'] = FALSE;
$handler->display->display_options['fields']['title']['alter']['ellipsis'] = FALSE;
/* Field: Content: Edit link */
$handler->display->display_options['fields']['edit_node']['id'] = 'edit_node';
$handler->display->display_options['fields']['edit_node']['table'] = 'views_entity_node';
$handler->display->display_options['fields']['edit_node']['field'] = 'edit_node';
/* Field: Content: Related Consultation */
$handler->display->display_options['fields']['field_comm_related_project']['id'] = 'field_comm_related_project';
$handler->display->display_options['fields']['field_comm_related_project']['table'] = 'field_data_field_comm_related_project';
$handler->display->display_options['fields']['field_comm_related_project']['field'] = 'field_comm_related_project';
$handler->display->display_options['fields']['field_comm_related_project']['label'] = 'Consultation';
$handler->display->display_options['fields']['field_comm_related_project']['alter']['text'] = '[field_comm_related_project]';
$handler->display->display_options['fields']['field_comm_related_project']['element_default_classes'] = FALSE;
$handler->display->display_options['fields']['field_comm_related_project']['type'] = 'node_reference_plain';
$handler->display->display_options['fields']['field_comm_related_project']['settings'] = array(
'alias' => 1,
'absolute' => 0,
);
/* Field: Content: Type */
$handler->display->display_options['fields']['field_cis_comm_type']['id'] = 'field_cis_comm_type';
$handler->display->display_options['fields']['field_cis_comm_type']['table'] = 'field_data_field_cis_comm_type';
$handler->display->display_options['fields']['field_cis_comm_type']['field'] = 'field_cis_comm_type';
/* Field: Content: Direction */
$handler->display->display_options['fields']['field_cis_comm_dir']['id'] = 'field_cis_comm_dir';
$handler->display->display_options['fields']['field_cis_comm_dir']['table'] = 'field_data_field_cis_comm_dir';
$handler->display->display_options['fields']['field_cis_comm_dir']['field'] = 'field_cis_comm_dir';
/* Field: Content: Proponent Contacts */
$handler->display->display_options['fields']['field_comm_contacts_external']['id'] = 'field_comm_contacts_external';
$handler->display->display_options['fields']['field_comm_contacts_external']['table'] = 'field_data_field_comm_contacts_external';
$handler->display->display_options['fields']['field_comm_contacts_external']['field'] = 'field_comm_contacts_external';
$handler->display->display_options['fields']['field_comm_contacts_external']['label'] = 'Proponent Contact(s)';
$handler->display->display_options['fields']['field_comm_contacts_external']['delta_offset'] = '0';
$handler->display->display_options['fields']['field_comm_contacts_external']['separator'] = '<br/>';
/* Field: Content: FN Staff Contacts */
$handler->display->display_options['fields']['field_comm_contacts_internal']['id'] = 'field_comm_contacts_internal';
$handler->display->display_options['fields']['field_comm_contacts_internal']['table'] = 'field_data_field_comm_contacts_internal';
$handler->display->display_options['fields']['field_comm_contacts_internal']['field'] = 'field_comm_contacts_internal';
$handler->display->display_options['fields']['field_comm_contacts_internal']['label'] = 'FN Staff Contact(s)';
$handler->display->display_options['fields']['field_comm_contacts_internal']['delta_offset'] = '0';
$handler->display->display_options['fields']['field_comm_contacts_internal']['separator'] = '<br/>';
/* Sort criterion: Content: Date (field_cis_comm_date) */
$handler->display->display_options['sorts']['field_cis_comm_date_value']['id'] = 'field_cis_comm_date_value';
$handler->display->display_options['sorts']['field_cis_comm_date_value']['table'] = 'field_data_field_cis_comm_date';
$handler->display->display_options['sorts']['field_cis_comm_date_value']['field'] = 'field_cis_comm_date_value';
$handler->display->display_options['sorts']['field_cis_comm_date_value']['order'] = 'DESC';
/* Contextual filter: Content: FN Staff Contacts (field_comm_contacts_internal) */
$handler->display->display_options['arguments']['field_comm_contacts_internal_uid']['id'] = 'field_comm_contacts_internal_uid';
$handler->display->display_options['arguments']['field_comm_contacts_internal_uid']['table'] = 'field_data_field_comm_contacts_internal';
$handler->display->display_options['arguments']['field_comm_contacts_internal_uid']['field'] = 'field_comm_contacts_internal_uid';
$handler->display->display_options['arguments']['field_comm_contacts_internal_uid']['default_action'] = 'default';
$handler->display->display_options['arguments']['field_comm_contacts_internal_uid']['default_argument_type'] = 'current_user';
$handler->display->display_options['arguments']['field_comm_contacts_internal_uid']['summary']['number_of_records'] = '0';
$handler->display->display_options['arguments']['field_comm_contacts_internal_uid']['summary']['format'] = 'default_summary';
$handler->display->display_options['arguments']['field_comm_contacts_internal_uid']['summary_options']['items_per_page'] = '25';
/* Filter criterion: Content: Published */
$handler->display->display_options['filters']['status']['id'] = 'status';
$handler->display->display_options['filters']['status']['table'] = 'node';
$handler->display->display_options['filters']['status']['field'] = 'status';
$handler->display->display_options['filters']['status']['value'] = 1;
$handler->display->display_options['filters']['status']['group'] = 0;
$handler->display->display_options['filters']['status']['expose']['operator'] = FALSE;
/* Filter criterion: Content: Type */
$handler->display->display_options['filters']['type']['id'] = 'type';
$handler->display->display_options['filters']['type']['table'] = 'node';
$handler->display->display_options['filters']['type']['field'] = 'type';
$handler->display->display_options['filters']['type']['value'] = array(
'communications_log' => 'communications_log',
);
/* Display: Block */
$handler = $view->new_display('block', 'Block', 'block');
$handler->display->display_options['defaults']['hide_admin_links'] = FALSE;
$handler->display->display_options['defaults']['style_plugin'] = FALSE;
$handler->display->display_options['style_plugin'] = 'table';
$handler->display->display_options['style_options']['columns'] = array(
'field_cis_comm_date' => 'field_cis_comm_date',
'title' => 'title',
'edit_node' => 'title',
'field_comm_related_project' => 'field_comm_related_project',
'field_cis_comm_type' => 'field_cis_comm_type',
'field_cis_comm_dir' => 'field_cis_comm_type',
'field_comm_contacts_external' => 'field_comm_contacts_external',
'field_comm_contacts_internal' => 'field_comm_contacts_internal',
);
$handler->display->display_options['style_options']['default'] = '-1';
$handler->display->display_options['style_options']['info'] = array(
'field_cis_comm_date' => array(
'sortable' => 1,
'default_sort_order' => 'desc',
'align' => '',
'separator' => '',
'empty_column' => 0,
),
'title' => array(
'sortable' => 1,
'default_sort_order' => 'asc',
'align' => '',
'separator' => '<br/>',
'empty_column' => 0,
),
'edit_node' => array(
'align' => '',
'separator' => '',
'empty_column' => 0,
),
'field_comm_related_project' => array(
'sortable' => 1,
'default_sort_order' => 'asc',
'align' => '',
'separator' => '',
'empty_column' => 0,
),
'field_cis_comm_type' => array(
'sortable' => 1,
'default_sort_order' => 'asc',
'align' => '',
'separator' => '<br/>',
'empty_column' => 0,
),
'field_cis_comm_dir' => array(
'sortable' => 0,
'default_sort_order' => 'asc',
'align' => '',
'separator' => '',
'empty_column' => 0,
),
'field_comm_contacts_external' => array(
'align' => '',
'separator' => '',
'empty_column' => 0,
),
'field_comm_contacts_internal' => array(
'align' => '',
'separator' => '',
'empty_column' => 0,
),
);
$handler->display->display_options['style_options']['sticky'] = TRUE;
$handler->display->display_options['defaults']['style_options'] = FALSE;
$handler->display->display_options['defaults']['row_plugin'] = FALSE;
$handler->display->display_options['defaults']['row_options'] = FALSE;
$handler->display->display_options['block_description'] = 'Communications - My Communications';
/* Display: Block: For Consultations */
$handler = $view->new_display('block', 'Block: For Consultations', 'block_1');
$handler->display->display_options['display_description'] = 'Communication Logs related to Consultation nodes';
$handler->display->display_options['defaults']['hide_admin_links'] = FALSE;
$handler->display->display_options['defaults']['style_plugin'] = FALSE;
$handler->display->display_options['style_plugin'] = 'default';
$handler->display->display_options['defaults']['style_options'] = FALSE;
$handler->display->display_options['defaults']['row_plugin'] = FALSE;
$handler->display->display_options['row_plugin'] = 'fields';
$handler->display->display_options['defaults']['row_options'] = FALSE;
$handler->display->display_options['defaults']['header'] = FALSE;
$handler->display->display_options['defaults']['empty'] = FALSE;
$handler->display->display_options['defaults']['fields'] = FALSE;
/* Field: Content: Title */
$handler->display->display_options['fields']['title']['id'] = 'title';
$handler->display->display_options['fields']['title']['table'] = 'node';
$handler->display->display_options['fields']['title']['field'] = 'title';
$handler->display->display_options['fields']['title']['label'] = '';
$handler->display->display_options['fields']['title']['alter']['word_boundary'] = FALSE;
$handler->display->display_options['fields']['title']['alter']['ellipsis'] = FALSE;
$handler->display->display_options['fields']['title']['element_label_colon'] = FALSE;
/* Field: Content: Date */
$handler->display->display_options['fields']['field_cis_comm_date']['id'] = 'field_cis_comm_date';
$handler->display->display_options['fields']['field_cis_comm_date']['table'] = 'field_data_field_cis_comm_date';
$handler->display->display_options['fields']['field_cis_comm_date']['field'] = 'field_cis_comm_date';
$handler->display->display_options['fields']['field_cis_comm_date']['label'] = '';
$handler->display->display_options['fields']['field_cis_comm_date']['element_label_colon'] = FALSE;
$handler->display->display_options['fields']['field_cis_comm_date']['type'] = 'format_interval';
$handler->display->display_options['fields']['field_cis_comm_date']['settings'] = array(
'interval' => '2',
);
$handler->display->display_options['defaults']['arguments'] = FALSE;
/* Contextual filter: Content: Related Consultation (field_comm_related_project) */
$handler->display->display_options['arguments']['field_comm_related_project_nid']['id'] = 'field_comm_related_project_nid';
$handler->display->display_options['arguments']['field_comm_related_project_nid']['table'] = 'field_data_field_comm_related_project';
$handler->display->display_options['arguments']['field_comm_related_project_nid']['field'] = 'field_comm_related_project_nid';
$handler->display->display_options['arguments']['field_comm_related_project_nid']['default_action'] = 'default';
$handler->display->display_options['arguments']['field_comm_related_project_nid']['default_argument_type'] = 'node';
$handler->display->display_options['arguments']['field_comm_related_project_nid']['summary']['number_of_records'] = '0';
$handler->display->display_options['arguments']['field_comm_related_project_nid']['summary']['format'] = 'default_summary';
$handler->display->display_options['arguments']['field_comm_related_project_nid']['summary_options']['items_per_page'] = '25';
$handler->display->display_options['defaults']['filter_groups'] = FALSE;
$handler->display->display_options['defaults']['filters'] = FALSE;
/* Filter criterion: Content: Published */
$handler->display->display_options['filters']['status']['id'] = 'status';
$handler->display->display_options['filters']['status']['table'] = 'node';
$handler->display->display_options['filters']['status']['field'] = 'status';
$handler->display->display_options['filters']['status']['value'] = 1;
$handler->display->display_options['filters']['status']['group'] = 0;
$handler->display->display_options['filters']['status']['expose']['operator'] = FALSE;
/* Filter criterion: Content: Type */
$handler->display->display_options['filters']['type']['id'] = 'type';
$handler->display->display_options['filters']['type']['table'] = 'node';
$handler->display->display_options['filters']['type']['field'] = 'type';
$handler->display->display_options['filters']['type']['value'] = array(
'communications_log' => 'communications_log',
);
/* Filter criterion: Content: Title */
$handler->display->display_options['filters']['title']['id'] = 'title';
$handler->display->display_options['filters']['title']['table'] = 'node';
$handler->display->display_options['filters']['title']['field'] = 'title';
$handler->display->display_options['filters']['title']['operator'] = 'longerthan';
$handler->display->display_options['filters']['title']['value'] = '0';
$handler->display->display_options['block_description'] = 'Communications - From Consultations';
/* Display: Page */
$handler = $view->new_display('page', 'Page', 'page_1');
$handler->display->display_options['defaults']['hide_admin_links'] = FALSE;
$handler->display->display_options['path'] = 'testt';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment