When embedding a date browser based view into a panel page - either as default, block, or page -- the previous/next functionality does not work. It does work when accessing the view -> page directly -- but not when that view is enclosed in a panel page.

Comments

aww’s picture

Version: 6.x-2.x-dev » 6.x-2.4
Priority: Normal » Critical

Same problem. No matter what combination of views, date browser, attachment, etc., the calendar appears fine in the panel- including the before/next navigation; but clicking on them does not change the month. I cannot change year|month|week view. I cannot traverse to any of the dates.

d.sibaud’s picture

I've a block with a date browser attached to it, it display the current month but when I try to go to the next or previous month it get me to the front page.
maybe can be useful the exported view attached here:

$view = new view;
$view->name = 'offerte';
$view->description = 'offerte Hotel dei Priori';
$view->tag = 'Offerte';
$view->view_php = '';
$view->base_table = 'node';
$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', 'Predefinite', 'default');
$handler->override_option('fields', array(
'title' => array(
'id' => 'title',
'table' => 'node',
'field' => 'title',
),
));
$handler->override_option('sorts', array(
'field_inizio_value' => array(
'id' => 'field_inizio_value',
'table' => 'node_data_field_inizio',
'field' => 'field_inizio_value',
),
'random' => array(
'id' => 'random',
'table' => 'views',
'field' => 'random',
),
));
$handler->override_option('arguments', array(
'date_argument' => array(
'default_action' => 'ignore',
'style_plugin' => 'default_summary',
'style_options' => array(),
'wildcard' => 'all',
'wildcard_substitution' => 'Tutti',
'title' => '',
'breadcrumb' => '',
'default_argument_type' => 'date',
'default_argument' => '',
'validate_type' => 'node',
'validate_fail' => 'ignore',
'date_fields' => array(
'node_data_field_inizio.field_inizio_value' => 'node_data_field_inizio.field_inizio_value',
),
'year_range' => '-0:+1',
'date_method' => 'OR',
'granularity' => 'month',
'id' => 'date_argument',
'table' => 'node',
'field' => 'date_argument',
'validate_user_argument_type' => 'uid',
'validate_user_roles' => array(
'2' => 0,
'4' => 0,
'3' => 0,
),
'override' => array(
'button' => 'Sovrascrivi',
),
'relationship' => 'none',
'default_options_div_prefix' => '',
'default_argument_user' => 0,
'default_argument_fixed' => '',
'default_argument_image_size' => '_original',
'default_argument_php' => '',
'validate_argument_node_type' => array(
'promozione' => 'promozione',
'webform' => 0,
'aggregation_feed' => 0,
'aggregation_item' => 0,
'faq' => 0,
'image' => 0,
'evento' => 0,
'page' => 0,
),
'validate_argument_node_access' => 0,
'validate_argument_nid_type' => 'nid',
'validate_argument_vocabulary' => array(
'3' => 0,
'1' => 0,
),
'validate_argument_type' => 'tid',
'validate_argument_transform' => 0,
'validate_user_restrict_roles' => 0,
'image_size' => array(
'_original' => '_original',
'thumbnail' => 'thumbnail',
'preview' => 'preview',
),
'validate_argument_php' => '',
),
));
$handler->override_option('filters', array(
'status' => array(
'operator' => '=',
'value' => '1',
'group' => '0',
'exposed' => FALSE,
'expose' => array(
'operator' => FALSE,
'label' => '',
),
'id' => 'status',
'table' => 'node',
'field' => 'status',
'relationship' => 'none',
),
'type' => array(
'operator' => 'in',
'value' => array(
'promozione' => 'promozione',
),
'group' => '0',
'exposed' => FALSE,
'expose' => array(
'operator' => FALSE,
'label' => '',
),
'id' => 'type',
'table' => 'node',
'field' => 'type',
'relationship' => 'none',
),
'content_negotiation' => array(
'operator' => '',
'value' => '',
'group' => '0',
'exposed' => FALSE,
'expose' => array(
'operator' => FALSE,
'label' => '',
),
'id' => 'content_negotiation',
'table' => 'node',
'field' => 'content_negotiation',
'override' => array(
'button' => 'Override',
),
'relationship' => 'none',
),
));
$handler->override_option('access', array(
'type' => 'none',
));
$handler->override_option('cache', array(
'type' => 'none',
));
$handler->override_option('title', 'Offerte dell\'Hotel dei Priori');
$handler->override_option('use_ajax', TRUE);
$handler->override_option('items_per_page', 0);
$handler->override_option('use_pager', '1');
$handler->override_option('row_plugin', 'node');
$handler->override_option('row_options', array(
'relationship' => 'none',
'build_mode' => 'full',
'links' => 1,
'comments' => 0,
));
$handler = $view->new_display('date_nav', 'Date browser', 'date_nav_1');
$handler->override_option('arguments', array(
'date_argument' => array(
'default_action' => 'default',
'style_plugin' => 'default_summary',
'style_options' => array(),
'wildcard' => 'all',
'wildcard_substitution' => 'Tutti',
'title' => '',
'breadcrumb' => '',
'default_argument_type' => 'date',
'default_argument' => '',
'validate_type' => 'none',
'validate_fail' => 'empty',
'date_fields' => array(
'node_data_field_inizio.field_inizio_value' => 'node_data_field_inizio.field_inizio_value',
),
'year_range' => '-0:+1',
'date_method' => 'OR',
'granularity' => 'month',
'id' => 'date_argument',
'table' => 'node',
'field' => 'date_argument',
'validate_user_argument_type' => 'uid',
'validate_user_roles' => array(
'2' => 0,
'4' => 0,
'3' => 0,
),
'override' => array(
'button' => 'Usa predefinito',
),
'relationship' => 'none',
'default_options_div_prefix' => '',
'default_argument_user' => 0,
'default_argument_fixed' => '',
'default_argument_image_size' => '_original',
'default_argument_php' => '',
'validate_argument_node_type' => array(
'promozione' => 'promozione',
'webform' => 0,
'aggregation_feed' => 0,
'aggregation_item' => 0,
'faq' => 0,
'image' => 0,
'evento' => 0,
'page' => 0,
),
'validate_argument_node_access' => 0,
'validate_argument_nid_type' => 'nid',
'validate_argument_vocabulary' => array(
'3' => 0,
'1' => 0,
),
'validate_argument_type' => 'tid',
'validate_argument_transform' => 0,
'validate_user_restrict_roles' => 0,
'image_size' => array(
'_original' => '_original',
'thumbnail' => 'thumbnail',
'preview' => 'preview',
),
'validate_argument_php' => '',
),
));
$handler->override_option('empty', 'Non ci sono promozioni per il periodo scelto.');
$handler->override_option('empty_format', '2');
$handler->override_option('style_plugin', 'date_nav');
$handler->override_option('style_options', NULL);
$handler->override_option('attachment_position', 'before');
$handler->override_option('inherit_arguments', TRUE);
$handler->override_option('inherit_exposed_filters', FALSE);
$handler->override_option('displays', array(
'block_2' => 'block_2',
'default' => 0,
'block_1' => 0,
));
$handler = $view->new_display('block', 'Blocco', 'block_1');
$handler->override_option('fields', array(
'title' => array(
'label' => '',
'alter' => array(
'alter_text' => 0,
'text' => '',
'make_link' => 0,
'path' => '/offerte-hotel-assisi',
'link_class' => '',
'alt' => '',
'prefix' => '',
'suffix' => '',
'help' => '',
'trim' => 0,
'max_length' => '',
'word_boundary' => 1,
'ellipsis' => 1,
'strip_tags' => 0,
'html' => 0,
),
'link_to_node' => 1,
'exclude' => 0,
'id' => 'title',
'table' => 'node',
'field' => 'title',
'override' => array(
'button' => 'Usa predefinito',
),
'relationship' => 'none',
),
'field_inizio_value' => array(
'label' => '',
'alter' => array(
'alter_text' => 0,
'text' => '',
'make_link' => 0,
'path' => '',
'link_class' => '',
'alt' => '',
'prefix' => '',
'suffix' => '',
'help' => '',
'trim' => 0,
'max_length' => '',
'word_boundary' => 1,
'ellipsis' => 1,
'strip_tags' => 0,
'html' => 0,
),
'link_to_node' => 0,
'label_type' => 'none',
'format' => 'default',
'multiple' => array(
'multiple_number' => '',
'multiple_from' => '',
'multiple_to' => '',
'group' => TRUE,
),
'repeat' => array(
'show_repeat_rule' => '',
),
'fromto' => array(
'fromto' => 'both',
),
'exclude' => 0,
'id' => 'field_inizio_value',
'table' => 'node_data_field_inizio',
'field' => 'field_inizio_value',
'override' => array(
'button' => 'Usa predefinito',
),
'relationship' => 'none',
),
'teaser' => array(
'label' => '',
'alter' => array(
'alter_text' => 0,
'text' => '',
'make_link' => 0,
'path' => '',
'link_class' => '',
'alt' => '',
'prefix' => '',
'suffix' => '',
'help' => '',
'trim' => 1,
'max_length' => '180',
'word_boundary' => 1,
'ellipsis' => 1,
'strip_tags' => 1,
'html' => 1,
),
'exclude' => 0,
'id' => 'teaser',
'table' => 'node_revisions',
'field' => 'teaser',
'override' => array(
'button' => 'Usa predefinito',
),
'relationship' => 'none',
),
'view_node' => array(
'label' => '',
'alter' => array(
'alter_text' => 0,
'text' => '',
'make_link' => 0,
'path' => 'node/[nid]',
'link_class' => 'note',
'alt' => '[title]',
'prefix' => '',
'suffix' => '',
'help' => '',
'trim' => 0,
'max_length' => '',
'word_boundary' => 1,
'ellipsis' => 1,
'strip_tags' => 0,
'html' => 0,
),
'text' => 'Leggi',
'exclude' => 0,
'id' => 'view_node',
'table' => 'node',
'field' => 'view_node',
'override' => array(
'button' => 'Usa predefinito',
),
'relationship' => 'none',
),
));
$handler->override_option('sorts', array(
'random' => array(
'order' => 'ASC',
'id' => 'random',
'table' => 'views',
'field' => 'random',
'override' => array(
'button' => 'Usa predefinito',
),
'relationship' => 'none',
),
));
$handler->override_option('items_per_page', 1);
$handler->override_option('use_pager', '0');
$handler->override_option('row_plugin', 'fields');
$handler->override_option('row_options', array(
'inline' => array(),
'separator' => '',
));
$handler->override_option('block_description', '');
$handler->override_option('block_caching', -1);
$handler = $view->new_display('block', 'Blocco Pagina', 'block_2');
$handler->override_option('block_description', '');
$handler->override_option('block_caching', -1);

bfr’s picture

same here, this is really bad for me. Any ideas?

edit:
seems like the url that is being formed is not working.
As temporary solution i hardcoded the url in to the theme.inc of the dates module. Now of course
it's working only for one panel, luckily i only need one at this point.

modules/date/theme/theme.inc

//$vars['prev_url'] = date_real_url($view, NULL, $prev_arg);
//  $vars['next_url'] = date_real_url($view, NULL, $next_arg);
$vars['next_url'] = "worktime_sheet/$next_arg";
$vars['prev_url'] = "worktime_sheet/$prev_arg";

..where worktime_sheet is the name of my panel.

You also have to check "send arguments" from the settings of the panel so the argumet gets passed to the view.

osirisioux’s picture

Any news on this as of late?

Thanks!

mths’s picture

I have the same problem. I also have a view page defined, the sidebar block I created now links to that page when next or previous is clicked. My ideal situation would be I could just click through the months which load via ajax so I don't need a complete page refresh. Just loading the next month in the sidebar instead of in a page (or not at all) would be a good start.

If anyone know how I'd love to hear.

ivan73’s picture

I've the same type of issue, date_browser view integrated in node content is not working properly.
To integrate in the node content i've added "[view:date_browser=page]" in the page content.
The page is displayed correctly for the first month, clicking next button the page is called again with the parameter
"?=date-browser%2F2010-03". That is the correct next month but the view is not changed and display the same month.

How the page should pass the query parameter to the view ? Is needed to force that in some way ?

Any suggestion is welcome.

Thanks
Ivan

mths’s picture

Might be a silly remark, but I noticed I just stopped thinking and looking too quickly. I'm using calendar module and problems are solved. I'd still like it to use ajax, though.

bfr’s picture

@ivan73

If i understood correctly, check the end of my previous post.

bfr’s picture

Status: Active » Fixed

I updated everything - panels, views, date etc. and now it seems to be working, so -> fixed.

AaronELBorg’s picture

bfr,

What versions of date, views, and panels are you using?

The only module I'm using that's not the 'latest and greatest' is the [gulp] Views security update (and I think I heard that there was something about it that didn't play nice with the domain access module).

Anyway......

I'm using:

Date 6.x-2.4
Panels 6.x-3.3
Views 6.x-2.8

And if I understand your post correctly, you're saying that you are indeed getting the proper behavior from the date browser in a block (i.e. ajax happening, no page reload), correct?

Thanks!

bfr’s picture

Chaos tools 6.x-1.3
Panels 6.x-3.3
Calendar 6.x-2.2
Date 6.x-2.4
Views 6.x-2.x-dev (views.info has datestamp 1269347097 which converts to 23 / march / 2010)

Ofcourse i have bunch of other modules, and i did some disabling of modules and other things, and i'm not sure at which point
it started working.. so i guess we should compare ALL modules and their versions, is there any handy way that data(with versions numbers included)?

Anyway, i also dont think that the month changing is done via ajax at least in my configuration(it happens so fast it looks like no reload, but the target month is passed with url so i dont think i can be ajax).
Also i have all the stuff in normal panel page with bunch of views, no blocks.

However, i dont think these things have too much to do with this issue, since, at least for me, the problem was that the url was misformed before and now it's done correctly.
Maybe it's the dev-version of views? I remember i had some reason to update to dev, but dont remember what it was.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

whatsnewsisyphus’s picture

Still not working for me, tires to pass it as a sql query into the header where the content is expecting a /path

whatsnewsisyphus’s picture

Status: Closed (fixed) » Active

ajax doesnt work for me either

janetgot’s picture

I am having the same issue, where I have placed the Date-Browser in a Panel and the next / previous links don't work. It works fine as a separate page. I have just updated to all the latest modules:

Calendar 6.x-2.2
Chaos tool suite 6.x-1.4
Content Construction Kit (CCK) 6.x-2.6
Date 6.x-2.4
Panels 6.x-3.4
Views 6.x-2.10

Would love to get this fixed, as it is just what we need.

Apfel007’s picture

subscribe

baff’s picture

subscribe

willow315’s picture

We have a similar issue. We have a Date Browser in a right SideBar Block. When you click the Next and Prev buttons it does not change the month name in the block. It, instead, changes the page.

We are using:
Views 6.x-2.12
Date 6.x-2.6
Calendar 6.x-2.2

We tried to update the Date module to version 6.x-2.7 and that created more issues.

We are in the middle of building a site that REALLY needs to be completed, and MUST have a properly functioning calendar. Can you assist us? Thanks in advance.

selfuntitled’s picture

Exact same behavior for me - any thoughts? I get a page reload with no ajax. Firebug shows now javascript or ajax errors or warnings. All modules are up to date.

KarenS’s picture

Status: Active » Closed (duplicate)

Duplicate of #423492: Calender Navigation not working on Panels due to problem with date_real_url(). I don't use Panels, and don't have time to set it all up to test it right now, so it's hard to address this.

endiku’s picture

Subscribe

baff’s picture

not working for me (not using calendar module)

module used:
panels 6.x-3.x-dev
date 6.x-2.x-dev
views 6.x-2.12

dgastudio’s picture

subscribe