Changes for page Release Notes for XWiki Enterprise 4.0 Milestone 2
Last modified by Thomas Mortagne on 2017/03/24
Change comment:
There is no comment for this version
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -43,7 +43,7 @@ 43 43 44 44 We introduced a new Velocity tool to be able to serialize Java objects to the JSON format. Checkout the [[documentation>>doc:extensions:Extension.Velocity Module||anchor="HJSONTool"]]. Here's an example that shows how to serialize a Map object: 45 45 46 -{{code language="velocity"}}46 +{{code}} 47 47 {{velocity}} 48 48 #set($map = {'name': 'xwiki', 'values': [1, 2, 3], 'enabled': true}) 49 49 $jsontool.serialize($map) ... ... @@ -58,10 +58,10 @@ 58 58 59 59 We also refactored ##XWiki.LiveTableResultsMacros## page to generate the live table JSON in memory using a Map, which is serialized in the end using the new JSON tool. This makes it easier to customize the live table JSON. For example this is how the JSON for the AppWithinMinutes applications live table is generated: 60 60 61 -{{code}} 61 +{{code language="velocity"}} 62 62 {{include document="XWiki.LiveTableResultsMacros" /}} 63 63 64 -{{velocity language="velocity"}}64 +{{velocity}} 65 65 #if($xcontext.action == 'get' && "$!{request.outputSyntax}" == 'plain') 66 66 $response.setContentType('application/json') 67 67 #set($map = {})