0
votes

We have on-premises TFS 2015 and I would like to add a WIT field called Actual Time which is of type Double to the WIT. Right now, I used the TFS Team Project Manager and I was able to create the custom field for one project. However, our team has multiple projects and I would like to define this custom field across all projects for WIT that are Task and Bug. How can I do that?

I've looked at https://www.visualstudio.com/en-us/docs/work/reference/witadmin/manage-global-lists-for-work-item-types, but I just don't see how I can use that to define it globally and then have it show under the FORM / LAYOUT sections in the XML. Is there a global place where TASK and BUG WIT definitions exist on the collection level?

1

1 Answers

0
votes

No, there is no way to set that globally.

However you can add the field for Task Bug or any other work items for a specific project, then import the WIT definitions (xml file) to each team project which using the same process template.

You can create a cmd/batch file to do the import action, see below sample:

cd C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE
witadmin importwitd /collection:http://Server:8080/tfs/DefaultCollection /f:C:\WIT\Task.xml /p:Project1
witadmin importwitd /collection:http://Server:8080/tfs/DefaultCollection /f:C:\WIT\Bug.xml  /p:Project1 
witadmin importwitd /collection:http://Server:8080/tfs/DefaultCollection /f:C:\WIT\Task.xml /p:Project2 
witadmin importwitd /collection:http://Server:8080/tfs/DefaultCollection /f:C:\WIT\Bug.xml  /p:Project2 
witadmin importwitd /collection:http://Server:8080/tfs/DefaultCollection /f:C:\WIT\Task.xml /p:Project3
witadmin importwitd /collection:http://Server:8080/tfs/DefaultCollection /f:C:\WIT\Bug.xml  /p:Project3 

You can reference this article: https://blogs.msdn.microsoft.com/granth/2013/02/13/tfs-how-to-customize-work-item-types/

BTW,Global lists you linked above are pick lists that you can include in one or more fields and types of work items. That means if you add several fields which have the same list values, then you can use Global list, it's defined in collection level.