apostroph in text field

Dr. Christian Jung March 6, 2014

Hello,

the Javascript expression

%{('${Status}'=='Resolved') ? '\n [${CustomerText}]' : ''}

works fine within a Word document. ${CustomerText}
is the content of a text field. However, if the text
contains an aphostrophe (e.g. '), nothing is printed. If I
change the text by replacing ' with \' then it is printed
again. The point is: This way is not practicable in our
case. Thus, what can be done in order to have text printed
with aphostrophes?

Regards,
Christian

1 answer

1 accepted

0 votes
Answer accepted
Xpand IT
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 17, 2014

Hi Christian

You also should use conditional statements instead of Javascript conditions.

http://jiraxporter.xpand-it.com/display/JIRAXPORTER/Working+with+Advanced+Templates#WorkingwithAdvancedTemplates-ConditionalBlocks

Ex:

#{if (%{'${escape:Description}'.length > 0})}

This issue has a description. The text is below:

${Description}

#{end}


Dr. Christian Jung March 19, 2014

Many thanks. It runs now.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events