Using RallyRestToolkitFor.NET how to assign a release to hierarchicalrequirement?

StackOverflow https://stackoverflow.com/questions/22242445

  •  10-06-2023
  •  | 
  •  

Frage

I am a newbie and need help with assigning a release to hierarchicalrequirement using Rally REST Toolkit for .NET.

I am able to update a lot of fields but having issues with chaning Release field.

I tried the following:

...
restApi = new RallyRestApi("xxx@yy.com", "password", "https://rally1.rallydev.com", "v2.0");
DynamicJsonObject toUpdate = new DynamicJsonObject();
toUpdate["Release._ref"] = "https://rally1.rallydev.com/slm/webservice/v2.0/release/23453434";
OperationResult updateResult = restApi.Update('hierarchicalrequirement', 1234323, toUpdate);

Also, tried 
toUpdate["Release.Name"] = "ABCDRelease";

Any help with this is greatly appreciated.

Regards Kanth

War es hilfreich?

Lösung

You're super close. All object associations work the same in the Web Services API. Simply set its ref:

toUpdate["Release"] = "/release/23453434";

Note the ref can be absolute as in your original code or relative, as shown above.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top