Contrib type:
Code/CSS SnippetStatus:
Awaiting moderationCompatibility:
Ubercart Beta 4Here is a pretty simple view setup that allows for a rotating slideshow block to be placed on your site. I imagine this would be great for showing off featured products, specials, etc. For the purposes of this demonstration, I overrode the default "products" page that Views installs. I also added a preset in imagecache called "slideshow_image" so that I could resize my product images to the correct dimensions. Please note that this code requires:
Views
Views_slideshow (plugin)
Imagecache
Here's the code from the export:
$view = new stdClass();
$view->name = 'products';
$view->description = 'products';
$view->access = array (
);
$view->view_args_php = '';
$view->page = FALSE;
$view->page_title = 'Products';
$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 = 'node';
$view->url = 'products';
$view->use_pager = TRUE;
$view->nodes_per_page = '10';
$view->menu = TRUE;
$view->menu_title = 'Products View';
$view->menu_tab = FALSE;
$view->menu_tab_weight = '0';
$view->menu_tab_default = FALSE;
$view->menu_tab_default_parent = NULL;
$view->menu_tab_default_parent_type = 'tab';
$view->menu_parent_tab_weight = '0';
$view->menu_parent_title = '';
$view->block = TRUE;
$view->block_title = 'Product Slideshow';
$view->block_header = '';
$view->block_header_format = '1';
$view->block_footer = '';
$view->block_footer_format = '1';
$view->block_empty = '';
$view->block_empty_format = '1';
$view->block_type = 'slideshow_list';
$view->nodes_per_block = '3';
$view->block_more = FALSE;
$view->block_use_page_header = FALSE;
$view->block_use_page_footer = FALSE;
$view->block_use_page_empty = FALSE;
$view->sort = array (
array (
'tablename' => 'uc_products',
'field' => 'ordering',
'sortorder' => 'ASC',
'options' => '',
),
array (
'tablename' => 'node',
'field' => 'title',
'sortorder' => 'ASC',
'options' => '',
),
);
$view->argument = array (
);
$view->field = array (
array (
'tablename' => 'node_data_field_image_cache',
'field' => 'field_image_cache_fid',
'label' => '',
'handler' => 'content_views_field_handler_ungroup',
'options' => 'slideshow_image_linked',
),
);
$view->filter = array (
array (
'tablename' => 'node',
'field' => 'status',
'operator' => '=',
'options' => '',
'value' => '1',
),
array (
'tablename' => 'uc_products',
'field' => 'is_product',
'operator' => '=',
'options' => '',
'value' => '1',
),
);
$view->exposed_filter = array (
);
$view->requires = array(uc_products, node, node_data_field_image_cache);
$views[$view->name] = $view;To use this, go to the "Import" function in views administration.
I'm new to UC and this is my first contribution so feedback is encouraged and appreciated.
-David


Re: Product Slideshow Block
Its a nice contribution. I was planning to use http://drupal.org/project/slideshow when I come across this contribution. Is it possible to see any demo ? is it compatible with RC4 ?
Re: Product Slideshow Block
I'm getting this problem in Ubercart 1.0
You don't seem to have the following requirements: node_data_field_image_cache