Codice sorgente Wiki di Homeopaths

Version 8.119 by Jip-jan Alunkel on dicembre 08, 20:41

Show last authors
1 {{include reference="assets.pagemaker.macros"/}}
2
3 {{velocity}}
4 #set($discard = $services.localization.use('document', 'homeopaths.Code.translations'))
5 #set($discard = $services.localization.use('document', 'assets.pagemaker.translations'))
6 #set($discard = $xwiki.ssx.use('assets.pagemaker.WebHome', {'minify': false}))
7 #set($discard = $xwiki.jsx.use('assets.pagemaker.WebHome', {'minify': false}))
8
9 {{html wiki="false" clean="false"}}
10 <p>
11 All about homeopaths.
12 ##from XWikiSpace as space where doc.space = space.reference and ((doc.name <> 'WebHome' and lower(doc.name) like '%wiki%') or (doc.name = 'WebHome' and lower(space.name) like '%wiki%'))
13
14 ##set($q = $services.query.xwql("where doc.space like 'homeopaths' and doc.name like :usr"))
15 ##$q.bindValue('usr', 'practice').execute()
16 #set($q = $services.query.xwql("where doc.space like 'homeopaths'"))
17 $q.execute()
18 ##$xcontext.getUserReference().getName()
19 </p>
20 <div id="homeopaths_map"></div>
21
22
23 <h2>Add your practice to the map</h2>
24 #set($form_start = {
25 "id": "homeoworld_form",
26 "product": "practice",
27 "method": "post",
28 "url": "",
29 "use_captcha": "false"
30 })
31 #createFormStart($form_start)
32 #set($practice_name = {
33 "id" : "practice_name",
34 "type" : "text",
35 "required" : "true",
36 "label" : "Name of your practice",
37 "aria-label" : "Enter the name of your practice",
38 "placeholder" : "$services.localization.render('homeopaths.wordgroup.practice_name.placeholder')",
39 "data-pattern" : "^[a-zA-ZÀ-ÖÙ-öù-ÿĀ-žḀ-ỿ]+[a-zA-ZÀ-ÖÙ-öù-ÿĀ-žḀ-ỿ0-9- ]*$",
40 "data-error-response-type" : "use_label_definite_1",
41 "data-auto-first-capital" : "true",
42 "data-query-type" : "XWQL",
43 "data-query-reference" : "assets.pagemaker.XWQL.matchTitle",
44 "data-query-scope" : "homeopaths",
45 "data-query-list-type" : "suggest-negate",
46 "data-query-list-header" : "$services.localization.render('pagemaker.line.suggest_negate_list')",
47 "data-query-list-contents" : "value",
48 "data-create-page" : "true",
49 "help-block" : 'This will be used as the title of your practice page. The first character must be a letter.'
50 })
51 #createFormElement($practice_name)
52
53 #set($country = {
54 "id" : "country",
55 "type" : "text",
56 "required" : "true",
57 "label" : "Country of practice residence",
58 "aria-label" : "Choose the country",
59 "placeholder" : "$services.localization.render('homeopaths.word.country.placeholder')",
60 "data-set-space": "true",
61 "data-parent-space": "homeopaths",
62 "data-error-response-type" : "use_label_definite_1",
63 "data-auto-first-capital" : "true",
64 "data-query-type" : "JSON",
65 "data-query-reference" : "assets.pagemaker.JSON.countries",
66 "data-query-list-type" : "suggest-select",
67 "data-query-list-header" : "$services.localization.render('pagemaker.line.suggest_select_list')",
68 "data-query-list-contents" : "key",
69 "data-query-list-editable" : "false",
70 "help-block" : 'Input and select the country where your practice resides.'
71 })
72 #createFormElement($country)
73
74 #*
75 "data-create-xobj" : "true",
76 "data-xobj-classname" : "homeopaths.Code.homeopathsClass",
77 "data-xobj-fieldname" : "country",
78 *#
79
80 #set($address = {
81 "id" : "address",
82 "type" : "address",
83 "required" : "true",
84 "label" : "Address of your practice",
85 "aria-label" : "Input and select the address of your practice",
86 "placeholder" : "$services.localization.render('homeopaths.multiword.address.placeholder')",
87 "data-error-response-type" : "use_label_definite_1",
88 "data-auto-first-capital" : "true",
89 "data-query-type" : "address",
90 "data-query-reference" : "",
91 "data-page-name": "$xcontext.getUserReference().getName()",
92 "data-query-list-type" : "suggest-select",
93 "data-query-list-header" : "$services.localization.render('pagemaker.line.suggest_select_list')",
94 "data-query-list-contents" : "value/key",
95 "data-query-list-editable" : "false",
96 "data-create-xobj" : "true",
97 "data-xobj-classname" : "homeopaths.Code.homeopathsClass",
98 "data-xobj-fieldname" : "address",
99 "help-block" : 'Input street and number, then select the address of your practice.'
100 })
101 #createFormElement($address)
102 #set($submit = {
103 "id" : "create_practice",
104 "button-text" : "Add practice",
105 "help-block" : "Please remind yourself to always anonymize the case."
106 })
107 #createSubmit($submit)
108 #set($form_end = {
109 "use_captcha": "false"
110 })
111 #createFormEnd($form_end)