function social_post_views_data_alter in Open Social 8
Same name and namespace in other branches
- 8.9 modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 8.2 modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 8.3 modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 8.4 modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 8.5 modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 8.6 modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 8.7 modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 8.8 modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 10.3.x modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 10.0.x modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 10.1.x modules/social_features/social_post/social_post.module \social_post_views_data_alter()
- 10.2.x modules/social_features/social_post/social_post.module \social_post_views_data_alter()
Implements hook_views_data_alter().
File
- modules/
social_features/ social_post/ social_post.module, line 119 - The Social post module.
Code
function social_post_views_data_alter(array &$data) {
$data['post']['post_visibility_access_filter'] = [
'title' => t('Post visibility access'),
'filter' => [
'title' => t('Post visibility access'),
'help' => t('Enable post access for public and community posts.'),
'field' => 'field_visibility',
'id' => 'post_visibility_access',
],
];
$data['post']['post_account_stream_filter'] = [
'title' => t('Post account stream'),
'filter' => [
'title' => t('Post account stream'),
'help' => t('Enable post for the account stream.'),
'field' => 'field_visibility',
'id' => 'post_account_stream',
],
];
$data['post']['post_group_stream_filter'] = [
'title' => t('Post group stream'),
'filter' => [
'title' => t('Post group stream'),
'help' => t('Enable post for the group stream.'),
'field' => 'field_visibility',
'id' => 'post_group_stream',
],
];
}