Wednesday, October 31, 2012

TFS2012–multiple users assignment – tfs user group

I think the most well known classical workaround like in TFS2008 and TFS 2010 is to assign a work item to a group of people.

How to do it?

  • You have to create for each combination of persons you want to be able to assign a user group in TFS
  • You have to adapt each work item which should support this by adding these groups to the assigned to field as allowed values.

Assume that you are working in a team with 5 persons and want to be able to assign your work items to the following combinations.

  • Group: Team
  • Group: PersonAPersonB (Person A, Person B)
  • Group: PersonAPersonC (Person A, Person C)
  • and so on ….

You have to create for each combination a new group in TFS and assign the persons to it.

You have to adapt your work items and change the definition of your Assigned To field to something like this:

<FIELD name="Assigned To" refname="System.AssignedTo" type="String" syncnamechanges="true" reportable="dimension">
<
ALLOWEDVALUES expanditems="true">
<
LISTITEM value="[project]\PersonAPersonB" />
<
LISTITEM value="[project]\Team" />
<
LISTITEM value="[project]\PersonAPersonC" />
</
ALLOWEDVALUES>
</
FIELD>



And in webaccess it will look like this (test is the only user in this screenshot and is assigned to the team group):


Task work item with groups in assigned to field


 


Limitations?


One of the most interesting question is how it will integrate with the new agile features in TFS2012.


General issues and workarounds:



  • Custom work item queries have to be adapted to also work with groups
  • Hardcoded work item queries are not working with groups like “My Work in Team Explorer“


Taskboard


For the taskboard it doesn’t make a difference if a work item is assigned to a user or a tfs user group.


agile taskboard with group assigment


agile taskboard with person filtering


Capacity planning Calculation is broken!


As we can see in the screenshot below the capacity planning calculation does not work together with the group assignments.


image


image


 


Conclusion


For special use cases this can be a valid approach with the downside that you cannot use the new capacity planning features. Each work item query which relies on the @me keyword has to be adapted for each team member to include the custom groups. This means that we won’t be able to have a generic query like “Assigned to me” anymore.

TFS2012–assign work items to multiple users–overview

Since the beginning, Team Foundation Server does not support multiple user assignments for work items at all.

Before continuing reading you should ask yourself the following questions about why you or your team want to be able to assign a bunch of work, tracked as a work item to multiple users:

  • What do you want to achieve?
  • What does the team want to achieve?
  • Who will be the owner/responsible of the workitem if it is not done?
  • Is to much work for one person? –> Split the work to multiple tasks!
  • Do you want to pair with another person on the task?
  • ….

Depending on the answers there are are multiple options/workarounds for different scenarios available like the following

  • Assign a work item to a tfs user group
  • Add additional fields on your work items (eg: AssignedTo2)
  • Change the behavior of the assigned to field from ‘allowed values’ to ‘suggested values’

In the following posts I will show different solutions how this can be achieved, limitations and to witch scenario the different solutions will fit.

If you think TFS should support this feature natively please vote on uservoice here

Monday, October 22, 2012

VS2012 – tips and tricks – team explorer shortcuts and patterns

In my last post I wrote about team explorer shortcuts and patterns for Visual Studio 2010.

Visual Studio 2012 has already been launched with the new Team Explorer. Like the new Solution Explorer, the new Team Explorer follows the concept of a single tool-window with multiple scopes depending on the content.

image

Unlike the solution explorer which supports multiple instances for different scopes the new Team Explorer doesn’t support this which requires multiple clicks to navigate between the different scopes and sometimes you’re felling like lost in the toolbox.

For quick navigation shortcuts are your friend …

If you are a ReSharper user the following shortcuts are compatible with IDEA scheme.

Pattern for Team Explorer: SHIFT + ALT + T

VS2012 Team Explorer commands shortcuts

Team.TeamExplorerSearch

STRG + รค

TeamFoundationContextMenus.Commands.GoToHome

SHIFT + ALT + T, H

TeamFoundationContextMenus.Commands.GoToBuilds

SHIFT + ALT + T, B

TeamFoundationContextMenus.Commands.GoToWorkItems

SHIFT + ALT + T, W

TeamFoundationContextMenus.Commands.GoToPendingChanges

SHIFT + ALT + T, P

TeamFoundationContextMenus.Commands.GoToMyWork

SHIFT + ALT + T, M

TeamFoundationContextMenus.Commands.GoToWebAccess

SHIFT + ALT + T, A

Pattern for Editor/SourceControl: SHIFT + ALT + S

VS2012 TFS Editor/SourceControl commands shortcuts

File.TfsHistory

SHIFT + ALT + S, H

File.TfsAnnotate

SHIFT + ALT + S, A

File.TfsCompare

SHIFT + ALT + S, C

File.TfsUndoCheckout

SHIFT + ALT + S, U