Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Setting Elements Connect JIRA Field with ConfiForms

Brian Karst
Contributor
July 28, 2020

There are a few fields that are pulling from a database that I don't quite understand how to set via ConfiForms. They type is "Elements Connect (formerly nFeed) (nFeed) - Live - Text" The field autofills when creating an issue from within JIRA or updating the issue from JIRA, but will not from ConfiForms.

2 answers

1 vote
Nicolas Esteves
Contributor
July 29, 2020

Hi @Brian Karst , @Alex Medved _ConfiForms_ ,

I'm Nicolas, from the Elements team.

Firstly, I must say that I don't know very well ConfiForms so, my answers might need some adjustments.

Then, before going further, I'd like to get more information about your setup. Can you please illustrate your issue with some screenshots for example? And let me know how you integrated your Elements Connect field into ConfiForms? That would help me to try to reproduce your use case on my side.

If ConfiForms uses the public Jira REST API to get access or set custom field values, then that might explain the issue. Indeed, this API is not able to do everything...

(i) To better understand the following points, the concept of Key with Elements Connect should be known: https://doc.elements-apps.com/elements-connect/latest/administration-guide/configuration/field-configuration/field-query-configuration#id-.Fieldqueryconfigurationv6.1-Key

- Here is how to set a value (a valid Key) with REST: https://doc.elements-apps.com/elements-connect/latest/api-guide/rest-api#id-.RESTAPIv6.0-JiraRESTAPI

- Now, here is how to get a value (the Template) with REST: https://app.swaggerhub.com/apis-docs/bgts/elements-connect/2.0

- Finally, here is how to get possible values for a field with REST: https://docs.atlassian.com/software/jira/docs/api/REST/latest/#api/2/jql/autocompletedata-getFieldAutoCompleteForQueryString

I hope that helps.

Kind regards,

Alex Medved _ConfiForms_
Community Champion
July 29, 2020

The question here is how to set a particular field.

My understanding after reading this page https://doc.elements-apps.com/elements-connect/latest/api-guide/rest-api#id-.RESTAPIv6.0-JiraRESTAPI you use a "standard custom field" which can be updates/set via standard Jira REST API.

It is a matter of knowing the IDs of the options your field has, right?

Nicolas Esteves
Contributor
July 29, 2020

Indeed, if you want to set an Elements Connect field value with a REST call, you need to use the Jira REST API, and especially the "issue" method with a PUT.

Source: https://docs.atlassian.com/software/jira/docs/api/REST/latest/#api/2/issue-editIssue

Example: https://developer.atlassian.com/server/jira/platform/jira-rest-api-example-edit-issues-6291632/

For an Elements Connect field, you can push any value (there is no control on the value), BUT, you need to make sure the value you set is a valid Key according to the configuration of the field.

It is a matter of knowing the IDs of the options your field has, right?

So, the answer is yes!

Brian Karst
Contributor
July 29, 2020

@Nicolas Esteves @Alex Medved _ConfiForms_ 

Alex, always thank you for your quick responses.

Nicolas,

Unfortunately I can't post screen shots or illustrate it much better. Quite frustrating but I need to be vague on my end because of information sensitivity in my organization (Alex has had to deal with my vague unspecific questions for a while now). I am inquiring into the database the fields pull from to find out more about what is being sent.

Ideally I would like the ConfiForm to send whatever the field is pulling from the database based upon the user assigned to reporter/requestor etc. 

I have the custom field #s but was at a loss for what to put in for the input, through inspecting the page while acting like I am creating an issue in JIRA I did find it seeming to send this in the code.  

{"inputValues":["###XX"]} with the numbers and characters replaced obviously.

I am going to play with sending some things and see if I can get it to send something, even if it isn't the right thing 

Brian Karst
Contributor
July 29, 2020

After some testing....

The Elements Connect field I am playing with expects an Array of Strings. 

"customfield_#####": ["string"],

The above code successfully sent the wrong string to the field and it accepted it. Attempting to edit the field through JIRA resulted in it automatically setting the database string. So my next step would be figuring out how to have it set the Database value without editing the issue in JIRA. Any thoughts @Nicolas Esteves @Alex Medved _ConfiForms_ ?

Alex Medved _ConfiForms_
Community Champion
July 29, 2020

@Brian Karst 

As @Nicolas Esteves has mentioned earlier.. you need to send valid values. I dont know what more can I add here...

0 votes
Alex Medved _ConfiForms_
Community Champion
July 29, 2020

ConfiForms app integration with Jira is on REST API level.

So, you have to know what is the format accepted/expected by the field when set/updated via the REST API

I suggest you ask the vendors of the Elements Connect plugin about the format expected when such field is to be updated via REST API

Knowing that will help you to craft the mapping in ConfiForms

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events