Hello,
I build the Confiforms logic where I am reading data from JIRA. In JIRA I have many Epics and linked Stories.
What I would like to achieve is to add to the form only the key of the Epic and see the list of dependent / linked Stories. For every single story, I need to read the value of the Story Point and on the form, I need to add up these numbers and display the on the form.
What I already achieved
I have the form where I can add or search for any JIRA issue, story, or Epic. I am able to read the status and the value of the Story Points.
I am able also to read a number of stories when I add to the form JQL script.
I didn't find a way to have the listed keys of linked stories to the Epic via linked to Epic as Array or any other way where I will be able to parse and read story points by any other script.
Here is my code:
<p class="auto-cursor-target">
<br/>
</p>
<ac:structured-macro ac:macro-id="0ac060cf-c01e-4b08-bccf-6ecba9bc13a2" ac:name="confiform" ac:schema-version="1">
<ac:parameter ac:name="formName">f</ac:parameter>
<ac:rich-text-body>
<p class="auto-cursor-target">
<br/>
</p>
<ac:structured-macro ac:macro-id="ffda1fef-a7fc-4eda-8659-ef0107f79012" ac:name="confiform-entry-register" ac:schema-version="1">
<ac:parameter ac:name="embedded">true</ac:parameter>
<ac:rich-text-body>
<p>
<br/>
</p>
</ac:rich-text-body>
</ac:structured-macro>
<p>
<ac:structured-macro ac:macro-id="04f94039-92fb-4804-a362-d1a7535a7dd2" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="css">max-width:300px;width:300px;</ac:parameter>
<ac:parameter ac:name="fieldName">keyCF</ac:parameter>
<ac:parameter ac:name="fieldLabel">JIRA ticket #</ac:parameter>
<ac:parameter ac:name="extras">Jira</ac:parameter>
<ac:parameter ac:name="fieldDescription">projectkey-000</ac:parameter>
<ac:parameter ac:name="type">jira</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="9c923c23-b604-428e-93f8-7b068fafd1e5" ac:name="confiform-field-definition-rules" ac:schema-version="1">
<ac:parameter ac:name="condition">!keyCF:[empty]</ac:parameter>
<ac:parameter ac:name="fieldName">reporterCF=fields.reporter.name&summaryCF=fields.summary&statusCF=fields.status.name&storypointsCF=fields.customfield_10008&fixversionCF=fields.fixVersions.name&labelsCF=fields.labels.asArray&epiclinkCF=fields.customfield_18300&issuetypeCF=fields.issuetype.name</ac:parameter>
<ac:parameter ac:name="values">[entry.keyCF]</ac:parameter>
<ac:parameter ac:name="action">Lookup and set JIRA issue data</ac:parameter>
<ac:parameter ac:name="actionFieldName">keyCF</ac:parameter>
<ac:parameter ac:name="values2">Jira</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="68ea6f80-a1eb-4dc5-9fc1-8090c0cbd9f4" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">reporterCF</ac:parameter>
<ac:parameter ac:name="fieldLabel">Reporter field from JIRA</ac:parameter>
<ac:parameter ac:name="type">user</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="1db610be-8bcb-4ec3-9842-532156138aea" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">summaryCF</ac:parameter>
<ac:parameter ac:name="fieldLabel">Summary</ac:parameter>
<ac:parameter ac:name="type">text</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="8f17aaf8-f3fb-44b4-80d3-091f480a676d" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">statusCF</ac:parameter>
<ac:parameter ac:name="fieldLabel">Status</ac:parameter>
<ac:parameter ac:name="type">text</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="5eb44cf3-95c0-4ca4-ab3c-b3764f63562e" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">storypointsCF</ac:parameter>
<ac:parameter ac:name="fieldLabel">Story Points</ac:parameter>
<ac:parameter ac:name="type">hidden</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="16c314c8-3111-4651-a952-2ed178631c38" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">Roundednumber</ac:parameter>
<ac:parameter ac:name="fieldLabel">Story Points</ac:parameter>
<ac:parameter ac:name="type">text</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="8266e5eb-6f21-4835-b3eb-d2e03bd3eff3" ac:name="confiform-field-definition-rules" ac:schema-version="1">
<ac:parameter ac:name="values">Roundednumber=ROUND(storypointsCF,2)</ac:parameter>
<ac:parameter ac:name="action">Set expression</ac:parameter>
<ac:parameter ac:name="actionFieldName">storypointsCF</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="7ce2f073-cc47-46b7-9de3-8fc2e441fc2d" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">fixversionCF</ac:parameter>
<ac:parameter ac:name="fieldLabel">Fix Version</ac:parameter>
<ac:parameter ac:name="type">text</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="b0ff8473-dbee-41f3-9ad2-5297200455ca" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">labelsCF</ac:parameter>
<ac:parameter ac:name="fieldLabel">Labels</ac:parameter>
<ac:parameter ac:name="type">confluencemultilabel</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="078844d3-a855-4f05-b038-5792b47f82bb" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">epiclinkCF</ac:parameter>
<ac:parameter ac:name="fieldLabel">Group</ac:parameter>
<ac:parameter ac:name="type">text</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="c1d138f9-88e3-4d31-9a4b-aba8b5dc06ef" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">issuetypeCF</ac:parameter>
<ac:parameter ac:name="fieldLabel">Issue Type</ac:parameter>
<ac:parameter ac:name="type">text</ac:parameter>
</ac:structured-macro>
</p>
</ac:rich-text-body>
</ac:structured-macro>
<p class="auto-cursor-target">
<br/>
</p>
<ac:structured-macro ac:macro-id="77e6daaa-8c15-428d-98ac-5453d9fd463e" ac:name="confiform-table" ac:schema-version="1">
<ac:parameter ac:name="formName">f</ac:parameter>
<ac:rich-text-body>
<p class="auto-cursor-target">
<br/>
</p>
<ac:structured-macro ac:macro-id="aee3ccb6-c31d-44c4-8cc8-781e0c1ada18" ac:name="confiform-entry-edit" ac:schema-version="1">
<ac:rich-text-body>
<p>
<br/>
</p>
</ac:rich-text-body>
</ac:structured-macro>
<p class="auto-cursor-target">
<br/>
</p>
</ac:rich-text-body>
</ac:structured-macro>
<p class="auto-cursor-target">
<br/>
</p>
So there is another way how to achieve to get a list of all stories related to the Epic but this requires the use of the parameter in the JQL
issueFunction in issuesInEpics('key=[entry.keyCF]')
Is it the possible way how to receive the list of keys or any other parameter from JIRA?
Hi @HR
Do you know if the Jira issue you are retrieving from Jira has this information included in the object?
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, there is no problem retrieving data from JIRA however, I do not know how to add a request to JIRA as following JQL:
and use key as parameter.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Not quite what I was asking…
to see what Jira returns and ConfiForms sees you can by following the concept shown here https://wiki.vertuna.com/display/CONFIFORMS/Accessing+Jira+issue+fields+directly+from+ConfiForms+using+Jira+issue+field
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
What is working for me I am able to retrieve data from JIRA using Confiform Rules with Action "Lookup and set JIRA issue data"
Maybe a do not understand clearly how this "bridge" is properly setup.
In This "ConfiForms Rules for Field Definition" I have setup Application link to JIRA and this works.
For values set I properly working:
reporterCF=fields.reporter.name&summaryCF=fields.summary&statusCF=fields.status.name&storypointsCF=fields.customfield_10008&fixversionCF=fields.fixVersions.name&labelsCF=fields.labels.asArray&epiclinkCF=fields.customfield_18300&issuetypeCF=fields.issuetype.name
What I do not clearly understand is the setup this bridge for Applink or if I can simply use the Rule as explained above.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Where is nothing else to "setup" - but ConfiForms can work only with what JIra returns... and that was my question - does it return the data you are looking for (as a part of Jira issue)?
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, I am receiving data from JIRA. My issue is I do not know how to set up the request where the answer will be the list of keys linked to the Epic.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I did a couple more tests for the values from the link you provided to me:
I have one more question about this. If this is the complete list of all variables/values you can retrieve from JIRA. I see you can read for example sub-task key, (this is working for me) but I didn't find the value/path for "links in Epic"
If I try value like a issuelinks I will receive [object Object]
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That was really my question to you - to check what the Jira issue object has and if iot has the "links in Epic"...
If I look at the "issuelinks" I can see it is an array of linked Jira issues. Of course if you ask to get just the issuelinks property then you will get what you see - an unspecified and untyped object
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am sorry for this misunderstanding.
What will be then the path which I need to add to the keyCF field as above?
JiraIssueLinksCF=fields.???
this is what I am looking for.
Thanks for your understanding
Jaromir
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Path to get WHAT exactly from the issue links object?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
OK, let's say you want access the values for the issuelinks of an "inwardIssue" type
According to the structure returned by Jira you will do something like this
linkedIssues=[entry.jiraIssue.fields.issuelinks.inwardIssue.key]
Assuming the field you want to set this to is named "linkedIssues" and the field you have your Jira key is named "jiraIssue"
Little demo below
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Alex,
Thanks for your response and nice little demo. Unfortunately, it still doesn't work for me. See my little demo and source code
https://recordit.co/rwhgaLaRa7
<p class="auto-cursor-target">
<br/>
</p>
<ac:structured-macro ac:macro-id="764b619c-02f2-49c2-b950-3fc50f897ef8" ac:name="confiform" ac:schema-version="1">
<ac:parameter ac:name="formName">f</ac:parameter>
<ac:rich-text-body>
<p class="auto-cursor-target">
<br/>
</p>
<ac:structured-macro ac:macro-id="3c2b26f3-a7c3-4542-a4b5-a772bf247cba" ac:name="confiform-entry-register" ac:schema-version="1">
<ac:parameter ac:name="formName">f</ac:parameter>
<ac:parameter ac:name="type">Embedded</ac:parameter>
<ac:rich-text-body>
<p class="auto-cursor-target">
<br/>
</p>
<p class="auto-cursor-target">
<br/>
</p>
</ac:rich-text-body>
</ac:structured-macro>
<p class="auto-cursor-target">
<ac:structured-macro ac:macro-id="85a9b1d3-bd9e-468c-b96d-18277b3f4fa5" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">jiraIssue</ac:parameter>
<ac:parameter ac:name="fieldLabel">JIRA Issue</ac:parameter>
<ac:parameter ac:name="extras">Jira</ac:parameter>
<ac:parameter ac:name="type">jira</ac:parameter>
<ac:parameter ac:name="required">true</ac:parameter>
</ac:structured-macro> <ac:structured-macro ac:macro-id="7d9652fc-a20f-421d-bfa3-d0a9943a9123" ac:name="confiform-field-definition-rules" ac:schema-version="1">
<ac:parameter ac:name="condition">!jiraIssue:[empty]</ac:parameter>
<ac:parameter ac:name="values">linkedIssues=[entry.jiraIssue.fields.issuelinks.inwardIssue.key]</ac:parameter>
<ac:parameter ac:name="action">Set value</ac:parameter>
<ac:parameter ac:name="actionFieldName">jiraIssue</ac:parameter>
</ac:structured-macro>
</p>
<p class="auto-cursor-target">
<ac:structured-macro ac:macro-id="0d02b26c-1831-4bf4-8ef2-780d243426e6" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">linkedIssues</ac:parameter>
<ac:parameter ac:name="fieldLabel">Linked Issues</ac:parameter>
<ac:parameter ac:name="type">confluencemultilabel</ac:parameter>
<ac:parameter ac:name="required">true</ac:parameter>
</ac:structured-macro>
</p>
</ac:rich-text-body>
</ac:structured-macro>
<p>
<br/>
</p>
<p>
<br/>
</p>
<p>
<br/>
</p>
<p class="auto-cursor-target">
<br/>
</p>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Do you have any inward issues linked to the ticket you have selected in a demo?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That comes back to my original question - are they part of the issue object?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have been thinking of one more possibility to receive the list of keys or any other variable from JIRA.
For me is working via Jira JQL field where I could use as a parameter only the key which I am adding to the field keyCF
then the value should be
epiclinks=issueFunction in issuesEpics('key=[entry.keyCF]'). Unfortunately, I am receiving an issue from this as well.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Well, I believe that answers the question you asked in the demo you have recorded, right? If there is no data in the Jira object then you cannot retrieve it
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.