Problems with Event Views Arguments

jimdunntx - July 16, 2007 - 19:04
Project:Event Views
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active
Description

I am having considerable difficulties with event view arguments. While the filters seem to work fine without arguments, adding arguments produces unexpected results. For example, If you go to the view on my site at http://www.clubalbuquerque.com/event/selector3 you will get the view for the current date. However, this view has simple arguments (Start Year, Start Month and Start Day). If those are inserted, one will get a very different view.

This is the export of the view.

  $view = new stdClass();
  $view->name = 'event_js3';
  $view->description = 'Events table selector.';
  $view->access = array (
);
  $view->view_args_php = '';
  $view->page = TRUE;
  $view->page_title = 'event list';
  $view->page_header = '';
  $view->page_header_format = '1';
  $view->page_footer = '';
  $view->page_footer_format = '1';
  $view->page_empty = '';
  $view->page_empty_format = '1';
  $view->page_type = 'table';
  $view->url = 'event/selector3';
  $view->use_pager = TRUE;
  $view->nodes_per_page = '10';
  $view->sort = array (
  );
  $view->argument = array (
    array (
      'type' => 'event_year',
      'argdefault' => '2',
      'title' => 'Year',
      'options' => '',
      'wildcard' => '',
      'wildcard_substitution' => '',
    ),
    array (
      'type' => 'event_month',
      'argdefault' => '2',
      'title' => 'Month',
      'options' => '',
      'wildcard' => '',
      'wildcard_substitution' => '',
    ),
    array (
      'type' => 'event_day',
      'argdefault' => '2',
      'title' => 'Day',
      'options' => '',
      'wildcard' => '',
      'wildcard_substitution' => '',
    ),
  );
  $view->field = array (
    array (
      'tablename' => 'node',
      'field' => 'title',
      'label' => 'Title',
      'handler' => 'views_handler_field_nodelink',
      'sortable' => '1',
      'options' => 'link',
    ),
    array (
      'tablename' => 'term_node_4',
      'field' => 'name',
      'label' => 'Type',
      'options' => 'link',
    ),
    array (
      'tablename' => 'node_data_field_facility',
      'field' => 'field_facility_nid',
      'label' => 'Location',
      'handler' => 'content_views_field_handler_group',
      'options' => 'default',
    ),
    array (
      'tablename' => 'event',
      'field' => 'event_start',
      'label' => '',
      'handler' => 'views_handler_field_date_small',
    ),
  );
  $view->filter = array (
    array (
      'tablename' => 'node',
      'field' => 'status',
      'operator' => '=',
      'options' => '',
      'value' => '1',
    ),
    array (
      'tablename' => 'node',
      'field' => 'type',
      'operator' => 'OR',
      'options' => '',
      'value' => array (
  0 => 'event',
),
    ),
    array (
      'tablename' => 'event',
      'field' => 'year',
      'operator' => '=',
      'options' => '',
      'value' => '***CURRENT_TIME***',
    ),
    array (
      'tablename' => 'event',
      'field' => 'month',
      'operator' => '=',
      'options' => '',
      'value' => '***CURRENT_TIME***',
    ),
    array (
      'tablename' => 'event',
      'field' => 'day',
      'operator' => '=',
      'options' => '',
      'value' => '***CURRENT_TIME***',
    ),
  );
  $view->exposed_filter = array (
  );
  $view->requires = array(node, term_node_4, node_data_field_facility, event);
  $views[$view->name] = $view;

Sorry in advance if I have done anything wrong in this issue request. It is one of my first

#1

jimdunntx - July 16, 2007 - 20:00

Sorry, I should have mentioned that the filters for this are simple, consisting of the Event Start Year, Start Month and Start Day all being equal to "now"

 
 

Drupal is a registered trademark of Dries Buytaert.