• Blog
  • Info Support
  • Career
  • Training
  • International Group
  • Info Support
  • Blog
  • Career
  • Training
  • International Group
  • Search
logo InfoSupport
  • Latest blogs
  • Popular blogs
  • Experts
      • All
      • Bloggers
      • Speakers
  • Meet us
  • About us
    • nl
    • en
    • .NET
    • 3D printing
    • Advanced Analytics
    • Agile
    • Akka
    • Alexa
    • Algorithms
    • Api's
    • Architectuur
    • Artificial Intelligence
    • ATDD
    • Augmented Reality
    • AWS
    • Azure
    • Big Data
    • Blockchain
    • Business Intelligence
    • Chatbots
    • Cloud
    • Code Combat
    • Cognitive Services
    • Communicatie
    • Containers
    • Continuous Delivery
    • CQRS
    • Cyber Security
    • Dapr
    • Data
    • Data & Analystics
    • Data Science
    • Data Warehousing
    • Databricks
    • DataOps
    • Developers life
    • DevOps
    • Digital Days
    • Digital Twin
    • Docker
    • eHealth
    • Enterprise Architecture
    • Event Sourcing
    • Hacking
    • Infrastructure & Hosting
    • Innovatie
    • Integration
    • Internet of Things
    • Java
    • Machine Learning
    • Microservices
    • Microsoft
    • Microsoft Bot Framework
    • Microsoft Data Platform
    • Mobile Development
    • Mutation Testing
    • Open source
    • Pepper
    • Power BI
    • Privacy & Ethiek
    • Python
    • Quality Assistance & Test
    • Quality Assurance & Test
    • Requirements Management
    • Scala
    • Scratch
    • Security
    • SharePoint
    • Software Architecture
    • Software development
    • Software Factory
    • SQL Server
    • SSL
    • Start-up
    • Startup thinking
    • Stryker
    • Test Quality
    • Testing
    • TLS
    • TypeScript
    • Various
    • Web Development
    • Web-scale IT
    • Xamarin
    • All
    • Bloggers
    • Speakers
Home » How to assign a work item to a group and actually have it show a list of values
  • How to assign a work item to a group and actually have it show a list of values

    • By Marcel de Vries
    • .NET 13 years ago
    • .NET 0 comments
    • .NET .NET
    How to assign a work item to a group and actually have it show a list of values

    *Moved to: http://fluentbytes.com/how-to-assign-a-work-item-to-a-group-and-actually-have-it-show-a-list-of-values/

    Today I was asked one of the most asked questions related to work item tracking: “Can you can assign a work item to a group in stead of a person”?

    My standard answer to this question is “yes” and I tell people this can be easily be done by setting the ALLOWEDVALUES to include the attribute expanditems = “false” and add list items that contain the TFS group names.

    Since the question came from my team mate I said I would fix the work item type so he did not have to spend to much time for this simple change.

    To my surprise I found that it is easy but you have to know one additional fact and that is that you must not have altered the System.AssignedTo to only allow valid users!

    So what happened?

    I have a work item type called “Deliverable”. This is a work item that can be assigned to a group of developers, designers, testers, etc. So the requirement was simple, have this work item only assigned to a group in stead of a person. What I did was quite simple, for each state definition I just set the ALLOWEDVALUES to the list of groups I want to have the work item assigned to. See the example below:

     <br />&lt;STATE value=&quot;Scoped&quot;&gt; <br />&nbsp;&nbsp; &lt;FIELDS&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;FIELD refname=&quot;System.AssignedTo&quot;&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;ALLOWEDVALUES expanditems=&quot;false&quot;&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;LISTITEM value=&quot;[project]Project Managers&quot; /&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;LISTITEM value=&quot;[project]Feature Managers&quot;&nbsp; /&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;LISTITEM value=&quot;[project]Software Architects&quot; /&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;LISTITEM value=&quot;[project]Designers&quot; /&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;LISTITEM value=&quot;[project]Implementers&quot; /&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;LISTITEM value=&quot;[project]Testers&quot; /&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;LISTITEM value=&quot;[project]Integrators&quot; /&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/ALLOWEDVALUES&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;REQUIRED /&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/FIELD&gt; <br />&nbsp;&nbsp; &lt;/FIELDS&gt; <br />&lt;/STATE&gt; <br />

    After uploading the work item, I got a strange surprise, the assigned to field always appeared empty [:(]

    image

    It took me quite some time to figure out what happened here. I finally figured out that this is caused by the fact that the Work Item Field definition for System.AssignedTo has a constraint set of <VALIDUSER/> and a TFS group is not considered to be a valid user. (This is something that probably your custom work item has as well since the common way to customize your work items is to pick the Microsoft work items and change those. The Microsoft work item types have this constraint set as well )

     <br />&lt;FIELD reportable=&quot;dimension&quot; type=&quot;String&quot; name=&quot;Assigned To&quot; refname=&quot;System.AssignedTo&quot;&gt; <br /><strong>&nbsp; &lt;VALIDUSER /&gt; <br /></strong>&lt;/FIELD&gt; <br />

    So to fix this problem, I removed the <VALIDUSER/> constraint on the System.AssignedTo field. After removing the constraint and restarting Visual Studio after uploading the new type definition(I used WITImport at the command line, but this can also be done using the power tools) , the dropdown will show the options I expected to see.

    image

    So it is nice when you know the answer , but here you can see again that only knowing the answer is not enough to be productive, you actually have to have done this so you also know the problems you might run into [:)]

    &nbsp;

    Hope this keeps you from pulling your hair out.

    Cheers,
    Marcel

    Follow my new blog on http://fluentbytes.com

    Share this

Marcel de Vries

View profile

Related IT training

Go to training website

Related Consultancy solutions

Go to infosupport.com

Related blogs

  • Building a custom Kubernetes operator in C#

    Building a custom Kubernetes operator in C# Willem Meints - 2 months ago

  • Transform SpecFlow Table Column

    Transform SpecFlow Table Column Ronald Bosma - 5 months ago

  • Building a passwordless login flow with WebAuthn and th…

    Building a passwordless login flow with WebAuthn and th… Willem Meints - 7 months ago

Data Discovery Channel

  • Explainable AI - Break open the blackbox

  • Toekomstvaste microservice data architecturen

  • Modern Data Platform

Nieuwsbrief

* verplichte velden

Contact

  • Head office NL
  • Kruisboog 42
  • 3905 TG Veenendaal
  • T +31 318 552020
  • Call
  • Mail
  • Directions
  • Head office BE
  • Generaal De Wittelaan 17
  • bus 30 2800 Mechelen
  • T +32 15 286370
  • Call
  • Mail
  • Directions

Follow us

  • Twitter
  • Facebook
  • Linkedin
  • Youtube

Newsletter

Sign in

Extra

  • Media Library
  • Disclaimer
  • Algemene voorwaarden
  • ISHBS Webmail
  • Extranet
Beheer cookie toestemming
Deze website maakt gebruik van Functionele en Analytische cookies voor website optimalisatie en statistieken.
Functioneel Always active
De technische opslag of toegang is strikt noodzakelijk voor het legitieme doel het gebruik mogelijk te maken van een specifieke dienst waarom de abonnee of gebruiker uitdrukkelijk heeft gevraagd, of met als enig doel de uitvoering van de transmissie van een communicatie over een elektronisch communicatienetwerk.
Voorkeuren
De technische opslag of toegang is noodzakelijk voor het legitieme doel voorkeuren op te slaan die niet door de abonnee of gebruiker zijn aangevraagd.
Statistieken
De technische opslag of toegang die uitsluitend voor statistische doeleinden wordt gebruikt. De technische opslag of toegang die uitsluitend wordt gebruikt voor anonieme statistische doeleinden. Zonder dagvaarding, vrijwillige naleving door uw Internet Service Provider, of aanvullende gegevens van een derde partij, kan informatie die alleen voor dit doel wordt opgeslagen of opgehaald gewoonlijk niet worden gebruikt om je te identificeren.
Marketing
De technische opslag of toegang is nodig om gebruikersprofielen op te stellen voor het verzenden van reclame, of om de gebruiker op een website of over verschillende websites te volgen voor soortgelijke marketingdoeleinden.
Manage options Manage services Manage vendors Read more about these purposes
Voorkeuren
{title} {title} {title}