when including a set of tabs in another set of tabs via the "QTabs" type, the render method of QuickQtabsContent does not call drupal_alter like the regular tab build sequence does.

This means that any customizations done through hook_quicktabs_alter do not work as expected.

A simple fix could be merely calling the alter on line 49 of plugins/QuickQtabsContent.inc:

drupal_alter('quicktabs', $quicktabs);

in context:

    $output = array();
    if (isset($item['machine_name'])) {
      if ($quicktabs = quicktabs_load($item['machine_name'])) {
        drupal_alter('quicktabs', $quicktabs);
        $contents = $quicktabs->tabs;
        $name = $quicktabs->machine_name;
        unset($quicktabs->tabs, $quicktabs->machine_name);
        $options = (array) $quicktabs;
        if ($qt = QuickSet::QuickSetRendererFactory($name, $contents, $quicktabs->renderer, $options)) {
          $output = $qt->render();
        }
      }
    }
CommentFileSizeAuthor
#1 alter-subtabs-2190693-2.patch562 bytesiamfredrik
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

iamfredrik’s picture

FileSize
562 bytes

Made a patch for this.