Is there a way to call issue.description but only show the fist 5 lines of the description?
I am sending a custom email and do not want to display the whole description in it as it might be really long.
You want something like this but it's a bit inelegant, also you'd want to show an ellipsis if you are truncating it.
Given a string s:
s.readLines()[0 .. (s.readLines().size() < 5 ? s.readLines().size() - 1 : 4)].join("\n")
There is probably something better in a textutils class.
Mehmet's answer is for velocity templates, whereas you have a GStringTemplate.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Did you create the custom event and associate with your custom email template you have posted in the server?
You then use script runner to fire that up. One more thing, in order to have those vm's take affect, you need to restart JIRA instance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
So I dont want to edit vm templates as those are replaced every upgrade. That is why I am just having it done in the send email post function. If it is not possible there, then that is ok.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Right. If you look at the link I sent in details- especially the section that has the code:
## setup some additional parameters
$!rendererParams.put(
"rows"
,
"12"
)
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.
Actually. That does not work when sending through script runners send custom email post function.
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.
That is for setting a default description. That is not what i am asking.
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.