Wiki source code of Pinned posts Sheet

Last modified by superadmin on 2026/12/01 08:53

Show last authors
1 {{velocity output="false"}}
2 #macro (stripHTMLMacro $displayOutput)
3 $stringtool.removeEnd($stringtool.removeStart($displayOutput, '{{html clean="false" wiki="false"}}'), '{{/html}}')
4 #end
5 {{/velocity}}
6
7 {{velocity}}
8 #set ($discard = $xwiki.jsx.use('Blog.PinnedPostsSheet'))
9 {{html clean="false"}}
10 <div class="row">
11 <div class="col-md-12">
12 <h3>
13 $services.localization.render('blog.post.layout.cards.pinnedposts.edit')
14 </h3>
15 <div id="pinnedPostsContainer">
16 <form id="pinnedPostsForm" action="$doc.getURL('save')" method="post">
17 #if ("$!doc.getObject('Blog.PinnedPostsClass')" != '')
18 #set ($vdoc = $doc)
19 #else
20 #set ($vdoc = $xwiki.getDocument("Blog.PinnedPostsTemplate"))
21 #end
22 #set ($displayOutput = $vdoc.display('posts', 'edit'))
23 #stripHTMLMacro($displayOutput)
24 #set ($orderedPosts = $vdoc.getObject('Blog.PinnedPostsClass').getValue('orderedPosts'))
25 <input type="hidden" id="Blog.PinnedPostsClass_0_orderedPosts" name="Blog.PinnedPostsClass_0_orderedPosts" value="$escapetool.xml($orderedPosts)"/>
26 <input type="hidden" name="form_token" value="$services.csrf.token"/>
27 <div>
28 <input class="btn btn-primary" type="submit" name="action_save" value="$escapetool.xml($services.localization.render('blog.post.layout.cards.pinnedposts.save'))" id="savePinnedPostsBtn"/>
29 </div>
30 </form>
31 <div id="errors-container"></div>
32 </div>
33 </div>
34 </div>
35 {{/html}}
36 {{/velocity}}