Wiki source code of Extensions
Version 3.1 by Thomas Mortagne on 2011/10/27 17:29
Show last authors
author | version | line-number | content |
---|---|---|---|
1 | {{velocity output="false"}} | ||
2 | ## If this page is called with createExtension=true then create a new page using the ExtensionTemplate template | ||
3 | #if ($request.createExtension == "true") | ||
4 | $response.sendRedirect($xwiki.getURL("Extension.${request.name}", "inline", "$!{request.queryString}&title=${request.name}")) | ||
5 | #end | ||
6 | {{/velocity}} | ||
7 | |||
8 | (% class="centered" %) ((( | ||
9 | |||
10 | (% class="extension-link search-extension" %)((( | ||
11 | Search Extension... | ||
12 | ((( | ||
13 | {{velocity}} | ||
14 | {{html}} | ||
15 | <form action="$xwiki.getURL("ExtensionCode.ExtensionSearch")"> | ||
16 | <input type="hidden" name="space" value="Extension" /> | ||
17 | <input type="text" name="text" value="extension id..." size="25" class="withTip" /> | ||
18 | <span class="buttonwrapper"> | ||
19 | <input class="button" type="submit" value="Search" /> | ||
20 | </span> | ||
21 | </form> | ||
22 | {{/html}} | ||
23 | {{/velocity}} | ||
24 | ))) | ||
25 | ))) | ||
26 | |||
27 | (% class="extension-link add-extension" %)((( | ||
28 | Contribute Extension... | ||
29 | |||
30 | ((( | ||
31 | {{velocity}} | ||
32 | {{html}} | ||
33 | #if ($isGuest) | ||
34 | You need first to <a href="${escapetool.xml($xwiki.getURL("Main.WebHome", "login", "xredirect=$doc.externalURL"))}">log in</a> or <a href="${escapetool.xml($xwiki.getURL("xwiki:Main.WebHome", "register", "xredirect=$doc.externalURL"))}">register</a>. | ||
35 | #else | ||
36 | <form action="" id="newextension"> | ||
37 | <input type="hidden" name="parent" value="Extension.WebHome" /> | ||
38 | <input type="hidden" name="template" value="ExtensionCode.ExtensionTemplate" /> | ||
39 | <input type="hidden" name="createExtension" value="true" /> | ||
40 | <input class="withTip" type="text" name="id" value="extension id..." size="25"/> | ||
41 | <span class="buttonwrapper"> | ||
42 | <input class="button" type="submit" value="Add" /> | ||
43 | </span> | ||
44 | </form> | ||
45 | {{/html}} | ||
46 | #end | ||
47 | {{/velocity}} | ||
48 | ))) | ||
49 | ))) | ||
50 | |||
51 | ))) | ||
52 | |||
53 | (% class="clearfloats" %)((()))(%%) | ||
54 | |||
55 | {{velocity}} | ||
56 | #set($columns = ["id", "name", "summary", "type", "authors", "doc.creationDate", "doc.date"]) | ||
57 | #set($columnsProperties = { | ||
58 | "id" : { "type" : "text", "link" : "view" }, | ||
59 | "name" : { "type" : "text", "link" : "view" }, | ||
60 | "summary" : { "type" : "text", "link" : "view" }, | ||
61 | "type" : { "type" : "list" }, | ||
62 | "authors" : { "type" : "string"}, | ||
63 | "doc.creationDate" : { "type" : "date" }, | ||
64 | "doc.date" : { "type" : "date" } | ||
65 | }) | ||
66 | #set($options = { | ||
67 | "tagCloud":true, | ||
68 | "resultPage":"ExtensionCode.ExtensionJSON", | ||
69 | "className":"ExtensionCode.ExtensionClass", | ||
70 | "selectedColumn":"doc.creationDate", | ||
71 | "defaultOrder":"desc", | ||
72 | "translationPrefix" : "extension.repository.", | ||
73 | "rowCount": 30, | ||
74 | "extraParams" : 'space=Extension' | ||
75 | }) | ||
76 | #livetable("extensions" $columns $columnsProperties $options) | ||
77 | |||
78 | (% class="hidden" %) ((( | ||
79 | Temporary provide a link for robots to index all extension. | ||
80 | In the future, this link will be provided via a sitemap. | ||
81 | [[ExtensionCode.AllExtensionsList]] | ||
82 | ))) | ||
83 | {{/velocity}} |