Field cannot be set although it IS on the appropriate screen

Ronja Rehm March 24, 2021

Hi, 

I am having the problem that I can only set system fields (due date, summary, assignee,...) in Shary. 

I would like to set the field "gremium date", which is on "create issue screen" the screen in Jira. But in Shary I still get the message

com.atlassian.sal.api.net.ResponseException: Error communicating with Jira, {"errorMessages":[],"errors":{"gremium date":"Field 'gremium date' cannot be set. It is not on the appropriate screen, or unknown."}} 

The code in Shary is

{ 
"fields":

{
"project": { "key": "BKB" },

"gremiumdate": "[entry.golivedate.jiraDate]",

"issuetype": { "name": "Task" }
}
}

Can anyone help? Thanks a lot!screen.JPGscreen2.JPG

1 answer

1 accepted

1 vote
Answer accepted
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 24, 2021

I don't think the field id in your code is correct - "gremium date" is not  system field, it's a custom field, so you should be using the key for that.

Go to your list of custom fields, find gremium date and hover over, or click, one of the edit/configure options.  You should see a url that contains "id=xxxxx", with the xxxxx being a five digit number something like 10047.  Instead of gremiumdate, use customfield_10047 in your code.

Ronja Rehm March 24, 2021

Hey Nic, 

thanks a lot for your answer! I tried that and found 

,{"id":"customfield_16747","name":"Gremium Date","custom":true,"orderable":true,"navigable":true,"searchable":true,"clauseNames":["cf[16747]","Gremium Date"],"schema":{"type":"date","custom":"com.atlassian.jira.plugin.system.customfieldtypes:datepicker","customId":16747}}

so the new code is:

{ 
"fields":

{
"project": { "key": "BKB" },

"customfield_16747": "[entry.golivedate.jiraDate]",

"issuetype": { "name": "Task" }
}
}

 

but I still get the same error. Now it is 

com.atlassian.sal.api.net.ResponseException: Error communicating with Jira, {"errorMessages":[],"errors":{"customfield_16747":"Field 'customfield_16747' cannot be set. It is not on the appropriate screen, or unknown."}}

It is not possible that the ID of the customfield in the test environment is different is it? 

Because I usally use this link https://t-jira-consorsbank.is.echonet/rest/api/2/field to access the ID.

 

Thanks again

Ronja

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 24, 2021

Yes, the id of a field is variable by system.  

Unless the test system is a direct database clone of the production system.

Ronja Rehm March 25, 2021

Ah you are right! Now it works, thanks a lot

Suggest an answer

Log in or Sign up to answer