summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--modules/og_views/og_views.module5
-rw-r--r--modules/og_views/views/og.og.view2
-rw-r--r--modules/og_views/views/og.og_my.view65
3 files changed, 62 insertions, 10 deletions
diff --git a/modules/og_views/og_views.module b/modules/og_views/og_views.module
index 36b2656..2ebbfd6 100644
--- a/modules/og_views/og_views.module
+++ b/modules/og_views/og_views.module
@@ -210,11 +210,6 @@ function og_views_view_group($node, $teaser, $page) {
*/
function og_views_views_pre_view(&$view, &$display_id, &$args) {
if ($view->name == 'og_my') {
- if (!$view->display_handler->get_option('header')) {
- $txt = t('You might be interested in an <a href="!url" rel="nofollow">OPML feed containing feeds from all your subscribed groups</a>.', array('!url' => url('og/opml')));
-
- $view->attachment_before = $txt;
- }
if (!$view->display_handler->get_option('footer')) {
$view->attachment_after = theme('opml_icon', url('og/opml'));
}
diff --git a/modules/og_views/views/og.og.view b/modules/og_views/views/og.og.view
index 8b7be67..c9c40ca 100644
--- a/modules/og_views/views/og.og.view
+++ b/modules/og_views/views/og.og.view
@@ -1,3 +1,5 @@
+<?php
+
$view = new view;
$view->name = 'og';
$view->description = 'Groups directory';
diff --git a/modules/og_views/views/og.og_my.view b/modules/og_views/views/og.og_my.view
index 811670a..4582e4f 100644
--- a/modules/og_views/views/og.og_my.view
+++ b/modules/og_views/views/og.og_my.view
@@ -7,7 +7,7 @@ $view->description = 'List user\'s subscribed groups and provide link to manage
$view->tag = 'og';
$view->view_php = '';
$view->base_table = 'node';
-$view->is_cacheable = '0';
+$view->is_cacheable = FALSE;
$view->api_version = 2;
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */
$handler = $view->new_display('default', 'Defaults', 'default');
@@ -37,6 +37,13 @@ $handler->override_option('fields', array(
'relationship' => 'none',
),
));
+$handler->override_option('sorts', array(
+ 'title' => array(
+ 'id' => 'title',
+ 'table' => 'node',
+ 'field' => 'title',
+ ),
+));
$handler->override_option('filters', array(
'status' => array(
'id' => 'status',
@@ -73,21 +80,24 @@ $handler->override_option('filters', array(
),
),
'uid' => array(
- 'id' => 'uid',
- 'table' => 'og_uid',
- 'field' => 'uid',
'operator' => '=',
- 'value' => 1,
+ 'value' => '1',
'group' => 0,
'exposed' => FALSE,
'expose' => array(
'operator' => FALSE,
'label' => '',
),
+ 'id' => 'uid',
+ 'table' => 'og_uid',
+ 'field' => 'uid',
'relationship' => 'none',
'expose_button' => array(
'button' => 'Expose',
),
+ 'override' => array(
+ 'button' => 'Override',
+ ),
),
));
$handler->override_option('access', array(
@@ -103,6 +113,7 @@ $handler->override_option('empty', 'Not a member of any groups.');
$handler->override_option('empty_format', '1');
$handler->override_option('items_per_page', 50);
$handler->override_option('use_pager', '1');
+$handler->override_option('use_more', 1);
$handler->override_option('style_plugin', 'table');
$handler->override_option('style_options', array(
'override' => 1,
@@ -133,9 +144,53 @@ $handler->override_option('menu', array(
'type' => 'tab',
'title' => 'My groups',
'weight' => '0',
+ 'name' => 'navigation',
));
$handler->override_option('tab_options', array(
'type' => 'none',
'title' => '',
'weight' => 0,
));
+$handler = $view->new_display('block', 'Block', 'block_1');
+$handler->override_option('fields', array(
+ 'title' => array(
+ 'id' => 'title',
+ 'table' => 'node',
+ 'field' => 'title',
+ 'label' => 'Group',
+ 'relationship' => 'none',
+ 'link_to_node' => 1,
+ ),
+ 'post_count_new' => array(
+ 'label' => 'New',
+ 'set_precision' => FALSE,
+ 'precision' => 0,
+ 'decimal' => '.',
+ 'separator' => ',',
+ 'prefix' => '',
+ 'suffix' => '',
+ 'exclude' => 0,
+ 'id' => 'post_count_new',
+ 'table' => 'og',
+ 'field' => 'post_count_new',
+ 'override' => array(
+ 'button' => 'Use default',
+ ),
+ 'relationship' => 'none',
+ ),
+));
+$handler->override_option('sorts', array(
+ 'title' => array(
+ 'order' => 'ASC',
+ 'id' => 'title',
+ 'table' => 'node',
+ 'field' => 'title',
+ 'override' => array(
+ 'button' => 'Use default',
+ ),
+ 'relationship' => 'none',
+ ),
+));
+$handler->override_option('use_pager', '0');
+$handler->override_option('block_description', 'My groups');
+$handler->override_option('block_caching', -1);