Mapping Finish and Start Dates

Jul 19, 2007 at 1:03 PM
How can we add to the synchronization project's start and finish dates for a task?

I've tried to add the following XML to the tasks fieldMappings element. It doesn't crash, but it doesn't synch the values either.

<add partnerWorkItemField="ASSNSTARTDATE" tfsWorkItemField="Microsoft.VSTS.Scheduling.StartDate" defaultValueToTFS="" defaultValueFromTFS="" type="Microsoft.Vsts.Ranger.Connector.ApplicationBlock.Configuration.WorkItemStores.FieldMapping, Microsoft.Vsts.Ranger.Connector.ApplicationBlock, Version=3.1.0.0, Culture=neutral, PublicKeyToken=null" name="Start Date">
<fieldMappingRules>
<add defaultDate="MinValue" direction="ToTFS" type="Microsoft.Vsts.Ranger.Connector.ApplicationBlock.Configuration.WorkItemStores.ValidDateRule, Microsoft.Vsts.Ranger.Connector.ApplicationBlock, Version=3.1.0.0, Culture=neutral, PublicKeyToken=null" name="ValidDate ToTFS Rule"/>
</fieldMappingRules>
</add>
<add partnerWorkItemField="ASSNFINISHDATE" tfsWorkItemField="Microsoft.VSTS.Scheduling.FinishDate" defaultValueToTFS="" defaultValueFromTFS="" type="Microsoft.Vsts.Ranger.Connector.ApplicationBlock.Configuration.WorkItemStores.FieldMapping, Microsoft.Vsts.Ranger.Connector.ApplicationBlock, Version=3.1.0.0, Culture=neutral, PublicKeyToken=null" name="Finish Date">
<fieldMappingRules>
<add defaultDate="MinValue" direction="ToTFS" type="Microsoft.Vsts.Ranger.Connector.ApplicationBlock.Configuration.WorkItemStores.ValidDateRule, Microsoft.Vsts.Ranger.Connector.ApplicationBlock, Version=3.1.0.0, Culture=neutral, PublicKeyToken=null" name="ValidDate ToTFS Rule"/>
</fieldMappingRules>
</add>


Any Hints?

Thanks
Coordinator
Jul 19, 2007 at 1:26 PM
tspascoal,
You need underscores for those partnerWorkitemField names. Eg., ASSNSTARTDATE, ASSNFINISHDATE. Also, just please be aware that many of the date fields within Project Server are actually readonly and calculated. If it is readonly, the Connector won't be able to write values to those fields.

HTH,
Lenny
Jul 19, 2007 at 1:51 PM
Edited Jul 19, 2007 at 1:55 PM
But i do have underscores. :-) Since an underscore is the wiki markup for italic,the wiki transformed it into italic.

Notice the START is in italic. :-)

Just copied and pasted, and didn't noticed it would be transformed into italic. Sorry about that, should have used the Do Not Apply formatting markup.

Read only would not be a problem since the template can be customized to be read only to everyone except the service account group. Anyway Microsoft.VSTS.Scheduling.StartDate and Microsoft.VSTS.Scheduling.FinishDate (in the MSF Agile) are not read only. Only in the layout definition has a read only constraint, not in the fields (i guess because these fields are mapped in the project mapping fields in filemapping.xml). So this won't be a problem.

As for the TFS->Project Server direction i don't care. These fields are not supposed to be changed in TFS, i only configured them in one direction.

Any more hints? :-)


lfenster wrote:
tspascoal,
You need underscores for those partnerWorkitemField names. Eg., ASSNSTARTDATE, ASSNFINISHDATE. Also, just please be aware that many of the date fields within Project Server are actually readonly and calculated. If it is readonly, the Connector won't be able to write values to those fields.

HTH,
Lenny

Jul 19, 2007 at 2:13 PM
Please ignore the problem. It is now working (although i didn't change anything)

I didn't restart IIS when made the change, perhaps i should have., could be the definition was still cached somewhere. Although changing web.config restarted the WP which should invalidate the cache.

Thanks for the help.



tspascoal wrote:
But i do have underscores. :-) Since an underscore is the wiki markup for italic,the wiki transformed it into italic.

Notice the START is in italic. :-)

Just copied and pasted, and didn't noticed it would be transformed into italic. Sorry about that, should have used the Do Not Apply formatting markup.

Read only would not be a problem since the template can be customized to be read only to everyone except the service account group. Anyway Microsoft.VSTS.Scheduling.StartDate and Microsoft.VSTS.Scheduling.FinishDate (in the MSF Agile) are not read only. Only in the layout definition has a read only constraint, not in the fields (i guess because these fields are mapped in the project mapping fields in filemapping.xml). So this won't be a problem.

As for the TFS->Project Server direction i don't care. These fields are not supposed to be changed in TFS, i only configured them in one direction.

Any more hints? :-)


lfenster wrote:
tspascoal,
You need underscores for those partnerWorkitemField names. Eg., ASSNSTARTDATE, ASSNFINISHDATE. Also, just please be aware that many of the date fields within Project Server are actually readonly and calculated. If it is readonly, the Connector won't be able to write values to those fields.

HTH,
Lenny