Index: project_issue.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/project_issue/project_issue.module,v
retrieving revision 1.111
diff -u -p -r1.111 project_issue.module
--- project_issue.module	26 Jan 2009 19:57:38 -0000	1.111
+++ project_issue.module	26 Jan 2009 22:27:53 -0000
@@ -67,7 +67,6 @@ function project_issue_menu() {
   $items['project/user'] = array(
     'title' => 'My projects',
     'page callback' => 'project_issue_user_page',
-    'page arguments' => array(2),
     'access callback' => 'project_issue_menu_access',
     'access arguments' => array('auth'),
     'type' => MENU_NORMAL_ITEM,
@@ -1097,7 +1096,11 @@ function project_issue_user_page($arg = 
   $output = theme('table', $header, $rows, array('class' => 'projects'));
   $output .= l('#', "project/user/$user->name");
 
-  /// @todo Embed a view here.
+  /// @todo Allow configuration of which view to embed here?
+  $view = views_get_view('project_issue_user_projects');
+  $view->override_path = 'project/user';
+  $view_args = array($user->name, arg(3));
+  $output .=  $view->preview('default', $view_args);
 
   return $output;
 }
Index: views/project_issue.views_default.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/project_issue/views/project_issue.views_default.inc,v
retrieving revision 1.1
diff -u -p -r1.1 project_issue.views_default.inc
--- views/project_issue.views_default.inc	16 Jan 2009 01:41:15 -0000	1.1
+++ views/project_issue.views_default.inc	26 Jan 2009 22:27:53 -0000
@@ -647,6 +647,357 @@ function project_issue_views_default_vie
 
   $views[$view->name] = $view;
 
+  // ------------------------------------------
+  // Issues across all projects owned by a user
+  // ------------------------------------------
+  $view = new view;
+  $view->name = 'project_issue_user_projects';
+  $view->description = "Project issues for a specific user's projects";
+  $view->tag = 'Project issue';
+  $view->view_php = '';
+  $view->base_table = 'node';
+  $view->is_cacheable = FALSE;
+  $view->api_version = 2;
+  $view->disabled = FALSE;
+  $handler = $view->new_display('default', 'Defaults', 'default');
+  $handler->override_option('relationships', array(
+    'assigned' => array(
+      'label' => 'Assigned user',
+      'required' => 0,
+      'id' => 'assigned',
+      'table' => 'project_issues',
+      'field' => 'assigned',
+      'relationship' => 'none',
+    ),
+    'rid' => array(
+      'label' => 'Version',
+      'required' => 0,
+      'id' => 'rid',
+      'table' => 'project_issues',
+      'field' => 'rid',
+      'relationship' => 'none',
+    ),
+    'pid' => array(
+      'id' => 'pid',
+      'table' => 'project_issues',
+      'field' => 'pid',
+    ),
+  ));
+  $handler->override_option('fields', array(
+    'project_issue_queue' => array(
+      'label' => 'Project',
+      'exclude' => 0,
+      'id' => 'project_issue_queue',
+      'table' => 'node',
+      'field' => 'project_issue_queue',
+      'relationship' => 'pid',
+    ),
+    'title' => array(
+      'label' => 'Summary',
+      'link_to_node' => 1,
+      'exclude' => 0,
+      'id' => 'title',
+      'table' => 'node',
+      'field' => 'title',
+      'relationship' => 'none',
+    ),
+    'comment_count' => array(
+      'label' => 'Replies',
+      'set_precision' => FALSE,
+      'precision' => 0,
+      'decimal' => '.',
+      'separator' => ',',
+      'prefix' => '',
+      'suffix' => '',
+      'exclude' => 0,
+      'id' => 'comment_count',
+      'table' => 'node_comment_statistics',
+      'field' => 'comment_count',
+      'relationship' => 'none',
+    ),
+    'new_comments' => array(
+      'label' => '',
+      'set_precision' => FALSE,
+      'precision' => 0,
+      'decimal' => '.',
+      'separator' => ',',
+      'prefix' => '',
+      'suffix' => ' new',
+      'link_to_comment' => 1,
+      'no_empty' => 1,
+      'exclude' => 0,
+      'id' => 'new_comments',
+      'table' => 'node',
+      'field' => 'new_comments',
+      'relationship' => 'none',
+    ),
+    'sid' => array(
+      'id' => 'sid',
+      'table' => 'project_issues',
+      'field' => 'sid',
+    ),
+    'priority' => array(
+      'id' => 'priority',
+      'table' => 'project_issues',
+      'field' => 'priority',
+    ),
+    'category' => array(
+      'label' => 'Category',
+      'link_to_node' => 0,
+      'exclude' => 0,
+      'id' => 'category',
+      'table' => 'project_issues',
+      'field' => 'category',
+      'relationship' => 'none',
+    ),
+    'version' => array(
+      'label' => 'Version',
+      'link_to_node' => 0,
+      'exclude' => 0,
+      'id' => 'version',
+      'table' => 'project_release_nodes',
+      'field' => 'version',
+      'relationship' => 'rid',
+    ),
+    'last_comment_timestamp' => array(
+      'label' => 'Last updated',
+      'date_format' => 'time ago',
+      'custom_date_format' => '',
+      'exclude' => 0,
+      'id' => 'last_comment_timestamp',
+      'table' => 'node_comment_statistics',
+      'field' => 'last_comment_timestamp',
+      'relationship' => 'none',
+    ),
+    'name' => array(
+      'label' => 'Assigned to',
+      'link_to_user' => 1,
+      'exclude' => 0,
+      'id' => 'name',
+      'table' => 'users',
+      'field' => 'name',
+      'relationship' => 'assigned',
+    ),
+  ));
+  $handler->override_option('arguments', array(
+    'name' => array(
+      'default_action' => 'not found',
+      'style_plugin' => 'default_summary',
+      'style_options' => array(),
+      'wildcard' => 'all',
+      'wildcard_substitution' => 'All',
+      'title' => 'Projects by %1',
+      'default_argument_type' => 'current_user',
+      'default_argument' => '',
+      'validate_type' => 'none',
+      'validate_fail' => 'not found',
+      'glossary' => 0,
+      'limit' => '0',
+      'case' => 'none',
+      'path_case' => 'none',
+      'transform_dash' => 0,
+      'id' => 'name',
+      'table' => 'users',
+      'field' => 'name',
+      'relationship' => 'pid',
+      'default_options_div_prefix' => '',
+      'default_argument_user' => 0,
+      'default_argument_fixed' => '',
+      'default_argument_php' => '',
+      'validate_argument_node_type' => array(),
+      'validate_argument_node_access' => 0,
+      'validate_argument_nid_type' => 'nid',
+      'validate_argument_vocabulary' => array(),
+      'validate_argument_type' => 'tid',
+      'validate_argument_project_term_vocabulary' => array(),
+      'validate_argument_project_term_argument_type' => 'tid',
+      'validate_argument_project_term_argument_action_top_without' => 'pass',
+      'validate_argument_project_term_argument_action_top_with' => 'pass',
+      'validate_argument_project_term_argument_action_child' => 'pass',
+      'validate_argument_php' => '',
+    ),
+  ));
+  $handler->override_option('filters', array(
+    'type' => array(
+      'operator' => 'in',
+      'value' => array(
+        'project_issue' => 'project_issue',
+      ),
+      'group' => '0',
+      'exposed' => FALSE,
+      'expose' => array(
+        'operator' => FALSE,
+        'label' => '',
+      ),
+      'id' => 'type',
+      'table' => 'node',
+      'field' => 'type',
+      'relationship' => 'none',
+    ),
+    'status_extra' => array(
+      'operator' => '=',
+      'value' => '',
+      'group' => '0',
+      'exposed' => FALSE,
+      'expose' => array(
+        'operator' => FALSE,
+        'label' => '',
+      ),
+      'id' => 'status_extra',
+      'table' => 'node',
+      'field' => 'status_extra',
+      'relationship' => 'none',
+    ),
+    'title' => array(
+      'operator' => '=',
+      'value' => '',
+      'group' => '0',
+      'exposed' => TRUE,
+      'expose' => array(
+        'use_operator' => 0,
+        'operator' => 'title_op',
+        'identifier' => 'title',
+        'label' => 'Project',
+        'optional' => 1,
+        'remember' => 0,
+      ),
+      'case' => 0,
+      'id' => 'title',
+      'table' => 'node',
+      'field' => 'title',
+      'relationship' => 'pid',
+    ),
+    'category' => array(
+      'operator' => 'in',
+      'value' => array(),
+      'group' => '0',
+      'exposed' => TRUE,
+      'expose' => array(
+        'use_operator' => 0,
+        'operator' => 'category_op',
+        'identifier' => 'category',
+        'label' => 'Category',
+        'optional' => 1,
+        'single' => 1,
+        'remember' => 0,
+        'reduce' => 0,
+      ),
+      'id' => 'category',
+      'table' => 'project_issues',
+      'field' => 'category',
+      'relationship' => 'none',
+    ),
+    'priority' => array(
+      'operator' => 'in',
+      'value' => array(),
+      'group' => '0',
+      'exposed' => TRUE,
+      'expose' => array(
+        'use_operator' => 0,
+        'operator' => 'priority_op',
+        'identifier' => 'priority',
+        'label' => 'Priority',
+        'optional' => 1,
+        'single' => 1,
+        'remember' => 0,
+        'reduce' => 0,
+      ),
+      'id' => 'priority',
+      'table' => 'project_issues',
+      'field' => 'priority',
+      'relationship' => 'none',
+    ),
+    'sid' => array(
+      'operator' => 'in',
+      'value' => array(),
+      'group' => '0',
+      'exposed' => TRUE,
+      'expose' => array(
+        'use_operator' => 0,
+        'operator' => 'sid_op',
+        'identifier' => 'status',
+        'label' => 'Status',
+        'optional' => 1,
+        'single' => 1,
+        'remember' => 0,
+        'reduce' => 0,
+      ),
+      'id' => 'sid',
+      'table' => 'project_issues',
+      'field' => 'sid',
+      'relationship' => 'none',
+    ),
+  ));
+  $handler->override_option('access', array(
+    'type' => 'none',
+  ));
+  $handler->override_option('title', 'Issues for all projects');
+  $handler->override_option('items_per_page', 50);
+  $handler->override_option('use_pager', '1');
+  $handler->override_option('style_plugin', 'table');
+  $handler->override_option('style_options', array(
+    'grouping' => '',
+    'override' => 1,
+    'sticky' => 0,
+    'order' => 'desc',
+    'columns' => array(
+      'project_issue_queue' => 'project_issue_queue',
+      'title' => 'title',
+      'comment_count' => 'comment_count',
+      'new_comments' => 'comment_count',
+      'sid' => 'sid',
+      'priority' => 'priority',
+      'category' => 'category',
+      'version' => 'version',
+      'last_comment_timestamp' => 'last_comment_timestamp',
+      'name' => 'name',
+    ),
+    'info' => array(
+      'project_issue_queue' => array(
+        'sortable' => 1,
+        'separator' => '',
+      ),
+      'title' => array(
+        'sortable' => 1,
+        'separator' => '',
+      ),
+      'comment_count' => array(
+        'sortable' => 1,
+        'separator' => '<br />',
+      ),
+      'new_comments' => array(
+        'separator' => '',
+      ),
+      'sid' => array(
+        'sortable' => 1,
+        'separator' => '',
+      ),
+      'priority' => array(
+        'sortable' => 1,
+        'separator' => '',
+      ),
+      'category' => array(
+        'sortable' => 1,
+        'separator' => '',
+      ),
+      'version' => array(
+        'sortable' => 1,
+        'separator' => '',
+      ),
+      'last_comment_timestamp' => array(
+        'sortable' => 1,
+        'separator' => '',
+      ),
+      'name' => array(
+        'sortable' => 1,
+        'separator' => '',
+      ),
+    ),
+    'default' => 'last_comment_timestamp',
+  ));
+  
+  $views[$view->name] = $view;
+
   return $views;
 }
 
