Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 19:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.
×Hi,
I'm trying to set the issue's field to its parent's url.
I can get the key of parent but I cant reach the parent's url.
Parent: TD-10
Sub-task: TD-11
I want "TD-10" in TD-11's screen as a hyperlink.
I tried below,
Can anyone help?
Thanks
Hi @Aslıhan Paksoy and welcome to the community!
Which field are you trying to place, and where exactly? You want to place the parent's URL on the e.g. summary of the child issue?
Hi @Alex Koxaras _Relational_ , I have a text field in the sub-task , I'm trying to place the parent's URL on this field.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I would use:
https://YOURINSTANCENAME.atlassian.net/browse/{{ issue.fields.parent.key }}
But, I would definitely try to find another way to get the base url from JMWE. Give me a couple of minutes.
And I would add a condition for that post function to run only if parent issue exists (unless you have this PF on a workflow used only by a subtask)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I would make it a URL field.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I wrote in JMWE
[{{parentIssue.fields.summary}}|https://myinstance/browse/{{parentIssue.key}}]
I'm trying to insert an hyperlink; summary of parent will be seen as link alias
:( url field gives an error:
customfield_10201: Specify a valid URL for the Custom Field
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, because this is not a valid URL. You are trying to enter a URL as a [MYSUMMARY|https://myinstance/browse/YOURKEY]
The valid URL would be only the code I've given you (starting with https). If you want to include the summary and the wiki notation, then use a text field.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have tried this,
But in the issue view, this is the result, summary and key is not shown
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Aslıhan Paksoy ,
the parentIssue variable is only available in post-functions that operate explicitly on the parent issue. Here, the post function operates on the current issue (the issue on which you're setting the field value). To access the current issue's parent, you need this:
[{{issue.fields.parent.fields.summary}}|URL/browse/{{issue.fields.parent.key}}]
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Do what David told you :)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Aslihan,
The field should've "Wiki Style Renderer" for the value to be displayed as expected.
However, in the new issue view, Short text only supports plain text, so the renderer settings don't apply. Use the Paragraph custom field for rich text like links to URLs.
Thanks,
Suprija
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Aslıhan Paksoy ,
Does the field have "Wiki Style Renderer"?
What's the type of the field and on which view(new/old) you're seeing this?
Regards,
Suprija
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Okay, I have changed my field's renderer. Unfortunately it was default text renderer. Sorry and thank you all for helping me :)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Great to hear that!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Aslihan,
To get the URL you will need to use the following URL:
{{null | serverInfo | field("baseUrl")}}
For more details please check our documentation linked below:
So your template in Set issue field post function should be something like this:
{% if issue.fields.parent.key %} [{{issue.fields.parent.key}}|{{ null | serverInfo | field("baseUrl")}}/browse/{{ issue.fields.parent.key }}] {% endif %}
Hope it helps and let us know how it goes.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Aslihan,
I just noticed you are using JMWE for Jira cloud, I have updated the above solution accordingly. Let us know if you were able to get the parent issue URL.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.