From version < 2.1 >
edited by Vincent Massol
on 2021/04/06
To version 1.1 >
edited by Vincent Massol
on 2017/05/31
>
Change comment: Install extension [org.xwiki.contrib.releasenotes:application-releasenotes-ui-1.4]

Summary

Details

Page properties
Content
... ... @@ -1,4 +1,4 @@
1 -{{include reference="ReleaseNotes.Code.EntryVelocityMacros"/}}
1 +{{include reference="ReleaseNotes.Code.ChangesVelocityMacros"/}}
2 2  
3 3  {{velocity}}
4 4  #set ($topSpace = $doc.documentReference.extractFirstReference('SPACE').getName())
... ... @@ -24,8 +24,15 @@
24 24   #set ($discard = $rnObject.set('date', ''))
25 25   ## Copy the template content + title
26 26   #set ($templateDoc = $xwiki.getDocument($defaultTemplateReferenceString))
27 - #set ($discard = $rnDoc.setContent($templateDoc.content))
28 - #set ($discard = $rnDoc.setTitle($templateDoc.title))
27 + ## Run Velocity on the template to evaluate the velocity code in the template
28 + #define($evaluatedContent)
29 + #evaluate($templateDoc.content)
30 + #end
31 + #set ($discard = $rnDoc.setContent($evaluatedContent))
32 + #define($evaluatedTitle)
33 + #evaluate($templateDoc.title)
34 + #end
35 + #set ($discard = $rnDoc.setTitle($evaluatedTitle))
29 29   #set ($discard = $rnDoc.save('New Release note'))
30 30   ## Redirect in edit mode to edit the RN
31 31   $response.sendRedirect($xwiki.getURL($services.model.serialize($rnPageReference)))

Get Connected