Is there a way to get breadcrumbs working with Storm? For example, when I'm looking at a task or ticket for a project, can there be a breadcrumb like so:

Home > Projects > My Specific Project > Tasks > My Specific Task

CommentFileSizeAuthor
#5 stormtask-6.x-dev-breadcrumb.patch1.94 KBYoran
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Roberto Gerola’s picture

Status: Active » Fixed

I've implemented this :
Storm > Projects > My Specific Project > Tasks

Status: Fixed » Closed (fixed)

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

Yoran’s picture

Component: User interface » Storm.module
Status: Closed (fixed) » Needs review

Sorry to re-open this but I still have issue with task breadcrumb.

When I'm viewing a task (or editing it), I just have :
Storm > tasks

When I had a look at the code, I found 2 issues :
1. a first trail is set in stormtask_form which is just using $_GET['project_nid'] which is only set when creating a new task.
2. there is no project part in the trail set in stormtask_view

I fixed this by adding this function :

function _storamtask_build_breadcrumb($node) {
  $breadcrumb = array();
  $breadcrumb[] = l(t('Storm'), 'storm');
  
  if (array_key_exists('project_nid', $_GET)) {
    $breadcrumb[] = l(t('Projects'), 'storm/projects');
    $project=node_load($_GET['project_nid']);
    $project_nid = $project->nid;
    $project_title = $project->title;
  } else {
    $project_nid = $node->project_nid;
    $project_title = $node->project_title;
  }
    
  $breadcrumb[] = l(t('Projects'), 'storm/projects');
  $breadcrumb[] = l(t('Project : !project', array('!project' => $project_title)), "node/{$project_nid}");
  $breadcrumb[] = l(t('Tasks'), "node/{$project_nid}/tasks");
  
  drupal_set_breadcrumb($breadcrumb);
}

And replacing both breadcrumb building by a call to it.

This way it works in every situation.

juliangb’s picture

Version: 6.x-1.17 » 6.x-1.x-dev

Please could you post this as a patch? (http://drupal.org/patch/create)

Also, it will need to be against the current -dev version.

Yoran’s picture

Here it is

Status: Needs review » Needs work

The last submitted patch, stormtask-6.x-dev-breadcrumb.patch, failed testing.

juliangb’s picture

Title: Breadcrumbs with Storm » More specific breadcrumbs with tasks
Category: support » feature
FuXXz’s picture

Status: Needs work » Needs review

#5: stormtask-6.x-dev-breadcrumb.patch queued for re-testing.

Status: Needs review » Needs work

The last submitted patch, stormtask-6.x-dev-breadcrumb.patch, failed testing.

rfay’s picture

Status: Needs work » Needs review

#5: stormtask-6.x-dev-breadcrumb.patch queued for re-testing.

Status: Needs review » Needs work

The last submitted patch, stormtask-6.x-dev-breadcrumb.patch, failed testing.

NancyDru’s picture

I'd love to see "Home" added to the breadcrumbs.