<
From version < 13.2 >
edited by Vincent Massol
on 2015/01/23
To version < 14.1 >
edited by Vincent Massol
on 2015/01/23
>
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -36,7 +36,40 @@
36 36  
37 37  When upgrading make sure you compare your ##xwiki.cfg##, ##xwiki.properties## and ##web.xml## files with the newest version since some configuration parameters may have been modified or added. Note that you should add ##xwiki.store.migration=1## so that XWiki will attempt to automatically migrate your current database to the new schema. Make sure you backup your Database before doing anything.
38 38  
39 +== Issues specific to XWiki 6.4.1 ==
40 +
41 +* The Mail Sender API has changed slightly when sending emails to a list of users or to a group. For example if you wanted to send a template email to a group, you previously had to write:(((
42 +{{code language="none"}}
43 +## Parameters for the 'template' MimeMessageFactory
44 +#set ($templateParameters = {'language' : $xcontext.language, 'velocityVariables' : { 'var1' : 'value1' }})
45 +
46 +## Parameters for the 'group' MimeMessage Iterator Factory
47 +#set ($templateReference = $services.model.createDocumentReference('', 'Space', 'MailTemplatePage'))
48 +#set ($parameters = {'parameters' : $parameters, 'source' : $templateReference })
49 +
50 +#set ($groupReference = $services.model.createDocumentReference('', 'XWiki', 'MyGroup'))
51 +#set ($messages = $services.mailsender.createMessages('group', $groupReference, 'template', $parameters))
52 + ^^^^^^^^^^
53 +#set ($mailResult = $services.mailsender.send($messages, 'database'))
54 +{{/code}}
55 +
56 +And now in 6.4.1 you'll need to write:
57 +
58 +{{code language="none"}}
59 +## Parameters for the 'template' MimeMessageFactory
60 +#set ($templateParameters = {'language' : $xcontext.language, 'velocityVariables' : { 'var1' : 'value1' }})
61 +
62 +## Parameters for the 'group' MimeMessageFactory
63 +#set ($templateReference = $services.model.createDocumentReference('', 'Space', 'MailTemplatePage'))
64 +#set ($groupParameters = {'hint' : 'template', 'parameters' : $templateParameters, 'source' : $templateReference })
65 + ^^^^^^^^^^^^^^^^^^^
66 +#set ($groupReference = $services.model.createDocumentReference('', 'XWiki', 'MyGroup'))
67 +#set ($messages = $services.mailsender.createMessages('group', $groupReference, $groupParameters))
68 +#set ($mailResult = $services.mailsender.send($messages, 'database'))
69 +{{/code}}
70 +)))
71 +
39 39  == API Breakages ==
40 40  
41 -There is no API breakage since XWiki 6.4.
74 +TODO
42 42  

Get Connected