Hi
One of the sites I'm currently migrating from D6, got this simple view that ended up broken in 7.x. The only thing it does, is listing out all taxonomy terms in a specific vocab. Views correctly detect that it is broken and tag it accordingly. Editing the view show that it is missing, Fields, Filter criteria and Sort criteria but the rest seems to be OK. I'm not sure if migration was suppose to handle this type of upgrades or not, pls let me know, and if not I'll shut up and close the issue.

$view = new view;
$view->name = 'all_tags';
$view->description = 'view to list all tags';
$view->tag = '';
$view->view_php = '';
$view->base_table = 'term_data';
$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');
$handler->override_option('fields', array(
  'name' => array(
    'label' => '',
    'alter' => array(
      'alter_text' => 0,
      'text' => '',
      'make_link' => 0,
      'path' => '',
      'link_class' => '',
      'alt' => '',
      'prefix' => '',
      'suffix' => '',
      'target' => '',
      'help' => '',
      'trim' => 0,
      'max_length' => '',
      'word_boundary' => 1,
      'ellipsis' => 1,
      'html' => 0,
      'strip_tags' => 0,
    ),
    'empty' => '',
    'hide_empty' => 0,
    'empty_zero' => 0,
    'link_to_taxonomy' => 1,
    'exclude' => 0,
    'id' => 'name',
    'table' => 'term_data',
    'field' => 'name',
    'relationship' => 'none',
  ),
));
$handler->override_option('sorts', array(
  'name' => array(
    'order' => 'ASC',
    'id' => 'name',
    'table' => 'term_data',
    'field' => 'name',
    'relationship' => 'none',
  ),
));
$handler->override_option('filters', array(
  'vid' => array(
    'operator' => 'in',
    'value' => array(
      '1' => '1',
    ),
    'group' => '0',
    'exposed' => FALSE,
    'expose' => array(
      'operator' => FALSE,
      'label' => '',
    ),
    'id' => 'vid',
    'table' => 'term_data',
    'field' => 'vid',
    'relationship' => 'none',
  ),
));
$handler->override_option('access', array(
  'type' => 'none',
));
$handler->override_option('cache', array(
  'type' => 'time',
  'results_lifespan' => '300',
  'output_lifespan' => '300',
));
$handler->override_option('header', 'All Tags');
$handler->override_option('header_format', '1');
$handler->override_option('header_empty', 0);
$handler->override_option('items_per_page', 1000);
$handler->override_option('use_more', 1);
$handler->override_option('use_more_always', 0);
$handler->override_option('style_plugin', 'grid');
$handler->override_option('style_options', array(
  'grouping' => '',
  'columns' => '4',
  'alignment' => 'horizontal',
  'fill_single_line' => 1,
));
$handler = $view->new_display('page', 'Page', 'page_1');
$handler->override_option('path', 'knowledgebase/all_tags');
$handler->override_option('menu', array(
  'type' => 'none',
  'title' => '',
  'description' => '',
  'weight' => '0',
  'name' => 'navigation',
));
$handler->override_option('tab_options', array(
  'type' => 'none',
  'title' => '',
  'description' => '',
  'weight' => 0,
  'name' => 'navigation',
));

Comments

dawehner’s picture

In general views provides an api to automatically migrate views from drupal6 to drupal7.

This api works fine in general but it seems not to be on this case.

dawehner’s picture

Tryed to debug the problem some time: display->get_options('filters'); seems to not return something sometimes.

steinmb’s picture

Hi dereine
Thanks for testing this out, and verifying that this is an issue that should not brake during upgrade. Notice that I wrote in my init. bug rapport that, also taxonomy term fields in the view are broken, not only filters.

Cheers
Stein

dawehner’s picture

Yeah that was just a note for myself.

This one is definitive a tricky one and as always this will change one line after debugging a whole day.

Andreas Radloff’s picture

This might be related...

After upgrading from 7.x-3.0-beta3 to the dev from june 8th yesterday, my term-fields are broken as well (says Broken/missing handler). If I add a new term-field it works, only the ones present before latest update breaks.

Still broken in dev version from today.

Related to http://drupal.org/node/1122420 and http://drupal.org/node/1123936?

Edit: I thought I had solved it, turns out I didn't.

merlinofchaos’s picture

Status: Active » Needs review
StatusFileSize
new3.56 KB

Try this patch.

merlinofchaos’s picture

Status: Needs review » Fixed

Committed!

dawehner’s picture

Status: Fixed » Reviewed & tested by the community

This patch looks fine!

dawehner’s picture

Status: Reviewed & tested by the community » Fixed

This was already commited.

Status: Fixed » Closed (fixed)

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