Is it possible to shorten a hyperlink in a Jira Structure column?

Max Thompson April 12, 2021

I have a custom field for a product spec that is a very long hyperlink. Is it possible to use Structure's formula to reference a field and shorten that link?

Currently "product_spec" will show the clickable link, but it is incredibly long. I'd love to take that field as a variable and only display "Link" or "Spec" if possible.

1 answer

1 accepted

2 votes
Answer accepted
David Niro
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 13, 2021

Hello Max,

David from ALM Works here. This is something that can be accomplished using a formula column and the Wiki Markup format option.

You will want your formula to look something like this:

If(custom_link,concat("[Spec|";custom_link;"]"))

"custom_link" will be your variable, mapped to the custom field with the hyperlink

Where I have "Spec", is where you will want to type whatever text you want to be shown in the column.

The last step is to select "Wiki Markup" in the list of Format options. 

Please do let us know how it goes!  If you have any additional questions or require support, you can contact us at support.almworks.com

Best Regards,
David

pritchsc July 6, 2021

Hi David, 

Jumping on this thread as I'm trying to acheive something similar. 

We have a base url such as https://mydomain.someapp.com/#/ that I would like append with a string ID in a customer field. 

Using the above format, such as 

If(appID,concat("[appID|";https://mydomain.someapp.com/#/appID;"]"))

In this example, I want the hyperlink in structure field to display the appID e.g, this might be 12345 which would point to a url of https://mydomain.someapp.com/#/12345

Format is wrong, but pouring over the docs and the commuity, I am unable to find the solution. Any pointers would be much apprecaited. 

Scott.

David Niro
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 6, 2021

Hi Scott,

I was actually working on a response to your post!

So, for your scenario, we could use something like: 

concat(URL;appID)

You wouldn't need wiki markup unless you were planning on shortening the link in some way.

If there's no appID in a field, the formula will just return the base url.  to avoid this, you could incorporate the If statement like this:

IF(appID,concat(URL;appID))

In this way, it will only show a value if there is an appID present.

Please give them a try and let me know if it helps!

I'll post this in your thread as well.

Best Regards,
David Niro
www.almworks.com

Like Dave Rosenlund likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events