Changes for page Books

Last modified by Jip-jan Alunkel on November 23, 10:59

From version 8.24
edited by Jip-jan Alunkel
on April 11, 23:55
Change comment: Updated class property
To version 8.6
edited by Jip-jan Alunkel
on April 10, 15:27
Change comment: Added class property

Summary

Details

Page properties
Content
... ... @@ -1,38 +3,16 @@
1 -{{include reference="assets.formMaker.macros" /}}
2 -
3 3  {{velocity}}
4 4  #set($discard = $services.localization.use('document', 'cases.Code.translations'))
5 5  #set($discard = $services.localization.use('document', 'assets.formMaker.translations'))
6 6  #set($discard = $xwiki.ssx.use('assets.formMaker.WebHome'))
7 7  #set($discard = $xwiki.jsx.use('assets.formMaker.WebHome', {'minify' : false}))
6 +{{/velocity}}
8 8  
9 -{{html wiki="true" clean="false"}}
10 -<p>
11 11  All about books
12 -</p>
13 -<h2 class="livetable">Overview of all books</h2>
14 -<div id="livetable">
15 15  
16 -#set ($columns = ["doc.title", "author", "doc.space"])
17 -#set ($columnsProperties = {
18 - "doc.title": {"type": "text", "filterable" : true, "sortable": true, "link": "view"},
19 - "remedy" : {"type": "text", "filterable" : true, "sortable": true, "size" : 4},
20 - "doc.space" : {"type": "text", "filterable" : true, "sortable": true, "size" : 4, "link": "space"}
21 -})
22 -#set ($options = {
23 - "className" : "books.WebHome",
24 - "translationPrefix" : "books.livetable.",
25 - "queryFilters" : "currentlanguage",
26 - "rowCount": 10
27 -})
28 -#livetable("books" $columns $columnsProperties $options)
10 +{{include reference="assets.formMaker.macros" /}}
29 29  
30 -</div>
31 -<h3>Add a book to this wiki</h3>
32 -<p>
33 - Do you know of any books that can be of value to people who would like to learn more about homeopathy?
34 - Please feel free to share these books 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.
35 -</p>
12 +{{velocity}}
13 +{{html}}
36 36  
37 37  #createFormStart("homeoworld_form" "book")
38 38  
... ... @@ -41,12 +41,12 @@
41 41   "type" : "select",
42 42   "required" : "true",
43 43   "label" : "Type of book",
44 - "aria-label" : "Select the type of book",
45 - "placeholder" : "Type",
22 + "aria-label" : "Select the locality",
46 46   "data-error-response-type" : "use_label_definite_1",
47 47   "data-set-space" : "true",
25 + "placeholder" : "Type",
48 48   "space-reference" : "books",
49 - "help-block" : "Choose the type of book you would like to add."
27 + "help-block" : "Choose the type of book you would like to enter."
50 50  })
51 51  
52 52  #createFormElement($booktype)
... ... @@ -55,58 +55,41 @@
55 55   "id" : "book_title",
56 56   "type" : "text",
57 57   "required" : "true",
58 - "label" : "Title of the book",
36 + "label" : "Book title",
59 59   "aria-label" : "Enter the title of the book",
60 - "placeholder" : "Title",
38 + "placeholder" : "$services.localization.render('cases.wordgroup.main_complaint.placeholder')",
61 61   "data-error-response-type" : "use_label_definite_1",
62 62   "data-query-type" : "XWQL.matchTitle",
63 63   "data-query-scope" : "books",
64 64   "data-query-list-type" : "suggest-negate",
65 - "data-query-list-header" : "$services.localization.render('formMaker.line.suggest_negate_list')",
43 + "data-suggest-list-header" : "$services.localization.render('cases.line.suggest_negate_list')",
66 66   "data-query-list-contents" : "value",
67 67   "data-create-page" : "true",
68 - "help-block" : 'When providing a title of a common type of book, please also provide the authorʼs last name, viz. Boericke Materia Medica.'
46 + "help-block" : 'Please be as concise as possible when you describe the main complaint. For example:<br />"chronic headache with bowel complaints,"<br />"intermittend fever" or<br />"diarrhea."'
69 69  })
70 70  
71 71  #createFormElement($book_title)
72 72  
73 -#set($author = {
74 - "id" : "author",
51 +#set($remedy = {
52 + "id" : "remedy",
75 75   "type" : "text",
76 76   "required" : "true",
77 - "label" : "Author of the book",
78 - "aria-label" : "Enter the author of the book",
79 - "placeholder" : "Author",
55 + "label" : "Remedy",
56 + "aria-label" : "Choose the remedy",
57 + "placeholder" : "$services.localization.render('cases.word.remedy.placeholder')",
80 80   "data-error-response-type" : "use_label_definite_1",
81 - "data-query-type" : "XWQL.matchObject",
82 - "data-query-scope" : "books",
59 + "data-query-type" : "JSON.remedies",
83 83   "data-query-list-type" : "suggest-select",
84 - "data-query-list-header" : "$services.localization.render('formMaker.line.suggest_select_list')",
85 - "data-query-list-contents" : "value",
86 - "data-query-list-editable" : "true",
61 + "data-suggest-list-header" : "$services.localization.render('cases.line.suggest_select_list')",
62 + "data-query-list-contents" : "value/key",
87 87   "data-create-xobj" : "true",
88 88   "data-xobj-classname" : "books.WebHome",
89 - "data-xobj-fieldname" : "author",
90 - "help-block" : 'Select the author of this case.'
65 + "data-xobj-fieldname" : "remedy",
66 + "help-block" : 'Select the remedy that is central in this case.'
91 91  })
92 92  
93 -#createFormElement($author)
69 +#createFormElement($remedy)
94 94  
95 -#set($publish_year = {
96 - "id" : "publish_year",
97 - "type" : "number",
98 - "required" : "true",
99 - "label" : "Year of publishing",
100 - "aria-label" : "Enter the year of publishing",
101 - "placeholder" : "Year",
102 - "data-error-response-type" : "use_label_definite_1",
103 - "data-create-xobj" : "true",
104 - "data-xobj-classname" : "books.WebHome",
105 - "data-xobj-fieldname" : "publish_year"
106 -})
107 -
108 -#createFormElement($publish_year)
109 -
110 110  #set($extra_info = {
111 111   "id" : "extra_info",
112 112   "type" : "checkbox",
... ... @@ -119,15 +119,28 @@
119 119  
120 120  #createExpandStart("extra_info" "yes")
121 121  
122 -#createExpandEnd()
123 -
124 -#set($submit = {
125 - "id" : "create_book",
126 - "button-text" : "Create book",
127 - "help-block" : ""
83 +#set($author = {
84 + "id" : "author",
85 + "type" : "text",
86 + "required" : "false",
87 + "label" : "Author",
88 + "aria-label" : "Enter the author name",
89 + "placeholder" : "$services.localization.render('cases.word.author.placeholder')",
90 + "data-query-type" : "XWQL.matchObject",
91 + "data-query-scope" : "books",
92 + "data-query-list-type" : "suggest-select",
93 + "data-suggest-list-header" : "$services.localization.render('cases.line.suggest_select_list')",
94 + "data-query-list-contents" : "value",
95 + "data-create-xobj" : "true",
96 + "data-xobj-classname" : "books.WebHome",
97 + "data-xobj-fieldname" : "author",
98 + "help-block" : 'Select the author of this case.'
128 128  })
129 -#createSubmit($submit)
130 130  
101 +#createFormElement($author)
102 +
103 +#createExpandEnd()
104 +
131 131  #createFormEnd()
132 132  
133 133  {{/html}}
author
Use Suggest
... ... @@ -1,1 +1,0 @@
1 -1
remedy
Number
... ... @@ -1,0 +1,1 @@
1 +3
Size
... ... @@ -1,0 +1,1 @@
1 +30
Pretty Name
... ... @@ -1,0 +1,1 @@
1 +remedy
Name
... ... @@ -1,0 +1,1 @@
1 +remedy
title
Number
... ... @@ -1,0 +1,1 @@
1 +1
Size
... ... @@ -1,0 +1,1 @@
1 +30
Pretty Name
... ... @@ -1,0 +1,1 @@
1 +title
Name
... ... @@ -1,0 +1,1 @@
1 +title
Use Suggest
... ... @@ -1,0 +1,1 @@
1 +1
type
Number
... ... @@ -1,0 +1,1 @@
1 +2
Size
... ... @@ -1,0 +1,1 @@
1 +30
Pretty Name
... ... @@ -1,0 +1,1 @@
1 +type
Name
... ... @@ -1,0 +1,1 @@
1 +type
Use Suggest
... ... @@ -1,0 +1,1 @@
1 +1
publish_year
Number
... ... @@ -1,1 +1,0 @@
1 -2
Number Type
... ... @@ -1,1 +1,0 @@
1 -long
Size
... ... @@ -1,1 +1,0 @@
1 -30
Pretty Name
... ... @@ -1,1 +1,0 @@
1 -publish_year
Name
... ... @@ -1,1 +1,0 @@
1 -publish_year