Wiki source code of Cases

Version 110.512 by Jip-jan Alunkel on November 05, 14:32

Show last authors
1 {{velocity}}
2 #set ($discard = $services.localization.use('document', 'cases.Code.translations'))
3 #set( $discard = $xwiki.ssx.use('cases.WebHome') )
4 #set( $discard = $xwiki.jsx.use('cases.WebHome', {'minify' : false}) )
5 {{html wiki="true" clean="false"}}
6 <div class="intro-text">
7 <p class="intro-text">
8 <span class="saying">
9 The true healing art is in its nature a pure science of experience, and can and must rest on clear facts and on the sensible phenomena pertaining to their sphere of action, for all the subjects it has to deal with are clearly and satisfactorily cognizable by the senses through experience.
10 </span>
11 <span class="sayee">Samuel Hahnemann</span>
12 </p>
13 </div>
14 <p>
15 As the homeopathic case develops, the case taker gains insight on (a certain timeframe of) a patient's life. While proceding to document the realities of a particular moment, the complement of all documented interactions can be seen as a story.<br />
16 It is well known that storytelling is of great use in preserving and spreading information. This gives the publication of homeopathic cases a tremendous potential to teach and inspire.<br />
17 </p>
18 <h2 class="livetable">Overview of all cases</h2>
19 <div id="liveTable">
20 #set ($columns = ["doc.title", "remedy", "doc.space"])
21 #set ($columnsProperties = {
22 "doc.title": {"type": "text", "filterable" : true, "sortable": true, "link": "view"},
23 "remedy" : {"type": "text", "filterable" : true, "sortable": true, "size" : 4},
24 "doc.space" : {"type": "text", "filterable" : true, "sortable": true, "size" : 4, "link": "space"}
25 })
26 #set ($options = {
27 "className" : "cases.Code.casesClass",
28 "translationPrefix" : "cases.livetable.",
29 "queryFilters" : "currentlanguage",
30 "rowCount": 10
31 })
32 #livetable("cases" $columns $columnsProperties $options)
33 </div>
34 <h3>Add a case to this wiki</h3>
35 <p>
36 Do you know of any cases that can be of value to people who would like to learn more about homeopathy?
37 Please feel free to share these cases with our readers. However, to make sure your case is correctly filed in this wiki it is necessary that you answer a few simple questions about the case.
38 </p>
39 <form action="" id="homeoworld_form" method="post" class="formMaker" data-form-product="case" novalidate="novalidate">
40 <p class="required">
41 <label for="locality_select">
42 Locality of the main complaint
43 <span class="input-wrap select-wrap">
44 <select class="form-select form-control" aria-label="Select the locality" aria-describedby="locality_helpBlock" aria-required="true" required="required" data-error-response-type="use_label_defined_1" data-set-space="true" name="locality_select" id="locality_select">
45 <option value="" disabled="" selected="" hidden="hidden">$services.localization.render('cases.word.locality_select.placeholder')</option>
46 #set($xwql = "from doc.object(AppWithinMinutes.MetadataClass) met where doc.space like 'cases.%' and doc.space <> 'cases.Code' order by met.dataSpaceName asc")
47 #set($results = $services.query.xwql($xwql).addFilter('unique').execute())
48 #foreach ($item in $results)
49 #set ($document = $xwiki.getDocument($item))
50 <option value="$document.space">$document.getTitle()</option>
51 #end
52 </select>
53 <span id="locality_helpBlock" class="help-block">Please select the best suited physiological or psychological epicenter that the main complaint of the case hinges on.</span>
54 <span class="required-input-field"></span>
55 <span role="alert" class="form-not-valid-tip"></span>
56 </span>
57 </label>
58 </p>
59 <p class="required" contenteditable="true">
60 <label for="main_complaint_textinput">
61 Main complaint
62 <span class="input-wrap">
63 <input type="text" class="form-control full" name="main_complaint_textinput" id="main_complaint_textinput" placeholder="${services.localization.render('cases.wordgroup.main_complaint.placeholder')}" aria-describedby="main_complaint_helpBlock" aria-required="true" aria-label="Enter the main complaint" required="required" data-error-response-type="use_label_defined_1" data-query-type="XWQL.matchTitle" data-query-list-type="suggest-negate" data-query-list-contents="value" data-create-page="true" data-query-scope="cases" autocomplete="off">
64 <span id="main_complaint_helpBlock" class="help-block">Please be as concise as possible when you describe the main complaint. For example: "chronic headache", "intermittend fever" or "diarrhea"</span>
65 <span class="required-input-field"></span>
66 <span role="alert" class="form-not-valid-tip"></span>
67 </span>
68 </label>
69 </p>
70 <p class="required" contenteditable="true">
71 <label for="remedy_textinput">
72 Remedy
73 <span class="input-wrap">
74 <input type="text" class="form-control full" name="remedy_textinput" id="remedy_textinput" placeholder="${services.localization.render('cases.word.remedy.placeholder')}" aria-describedby="remedy_helpBlock" aria-required="true" aria-label="Choose the remedy" required="required" data-error-response-type="use_label_undefined" data-query-type="JSON.remedies" data-query-list-type="suggest-select" data-query-list-contents="value/key" data-create-xobj="true" data-xobj-classname="cases.Code.casesClass" data-xobj-fieldname="remedy" autocomplete="off">
75 <span id="remedy_helpBlock" class="help-block">Select the remedy that is central in this case.</span>
76 <span class="required-input-field"></span>
77 <span role="alert" class="form-not-valid-tip"></span>
78 </span>
79 </label>
80 </p>
81 <p>
82 <span class="input-wrap checkradio">
83 <span class="fieldset no-fieldset-border">
84 <label for="extra_info" class="strong">
85 <input type="checkbox" name="extra_info" id="extra_info" data-mod-display="extra_info_contents" value="yes" />Extra information (optional)
86 </label>
87 </span>
88 </span>
89 </p>
90 <div id="extra_info_section_yes" class="togglee">
91 <p contenteditable="true">
92 <label for="author_textinput">
93 Author
94 <span class="input-wrap">
95 <input type="text" class="form-control full" name="author_textinput" id="author_textinput" placeholder="${services.localization.render('cases.word.author.placeholder')}" aria-describedby="author_helpBlock" aria-label="Enter the author name" data-query-type="XWQL.matchObject" data-query-scope="cases" data-query-list-type="suggest-select" data-query-list-contents="value" data-query-list-editable="true" data-create-xobj="true" data-xobj-classname="cases.Code.casesClass" data-xobj-fieldname="author" autocomplete="off">
96 <span id="author_helpBlock" class="help-block">Select the author of this case.</span>
97 </span>
98 </label>
99 </p>
100 </div>
101 <div class="clearfix">
102 <p class="alert alert-warning alert-button-float-right">
103 <span class="alert-button pull-right">
104 #if ($xcontext.user != 'XWiki.XWikiGuest')
105 <input type="submit" class="btn btn-primary" id="create_case" name="create_case" value="Create new case" />
106 #else
107 <a data-toggle="modal" data-target="#displayLogin" href="#" class="btn btn-primary">$services.localization.render('login')</a>
108 #end
109 </span>
110 <span class="alert-text">
111 Please remind yourself to always anonymize the case.
112 </span>
113 </p>
114 </div>
115 <div role="alert" class="form-response-output form-validation-errors" style="display: none">
116 <p>
117 $services.localization.render('cases.line.global_error_msg')
118 </p>
119 </div>
120 <div role="alert" class="form-response-output form-validation-ok" style="display: none">
121 <p>
122 $services.localization.render('cases.line.global_ok_msg')
123 </p>
124 </div>
125 </form>
126 {{/html}}
127 {{/velocity}}