Dapplo.Jira icon indicating copy to clipboard operation
Dapplo.Jira copied to clipboard

Custom drop down fields?

Open SamirKharchi opened this issue 3 years ago • 10 comments

I am trying to create an issue with custom fields (drop downs!) but I always get a bad request response upon issue creation.

Custom fields I can set without problems but only string type fields. The two fields I would like to set are drop downs and nothing seems to work for them, the client call always returns a 400 bad request (Exception message: "Field 'Change Reason' cannot be set. It is not on the appropriate screen, or unknown.").

Here is how I try to set such a drop down field:

new Issue { Fields = new IssueFields { CustomFields = { {"customfield_10401", "Sonstiges"} } ...

I am not sure if it's fine to simply pass a string of the drop down item to select as the value. I also tried a single-entry anonymous array and id (e.g. 10305) instead of the value ("Sonstiges") but that didn't change anything. Is it possible to set a custom field that is a combobox?

Btw. the field is definetly available in the issue type (required even). And I can create the issue with a simple Jira CLI client without a problem. The field is also available when I use client.Server.GetFieldsAsync()

SamirKharchi avatar Oct 19 '20 15:10 SamirKharchi