Changes for page Books

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

From version 8.17
edited by Jip-jan Alunkel
on April 10, 17:02
Change comment: Updated class property
To version 8.27
edited by Jip-jan Alunkel
on April 17, 22:51
Change comment: Updated class property

Summary

Details

Page properties
Content
... ... @@ -1,16 +1,38 @@
1 +{{include reference="assets.formMaker.macros" /}}
2 +
1 1  {{velocity}}
2 2  #set($discard = $services.localization.use('document', 'cases.Code.translations'))
3 3  #set($discard = $services.localization.use('document', 'assets.formMaker.translations'))
4 4  #set($discard = $xwiki.ssx.use('assets.formMaker.WebHome'))
5 5  #set($discard = $xwiki.jsx.use('assets.formMaker.WebHome', {'minify' : false}))
6 -{{/velocity}}
7 7  
9 +{{html wiki="true" clean="false"}}
10 +<p>
8 8  All about books
12 +</p>
13 +<h2 class="livetable">Overview of all books</h2>
14 +<div id="livetable">
9 9  
10 -{{include reference="assets.formMaker.macros" /}}
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)
11 11  
12 -{{velocity}}
13 -{{html}}
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>
14 14  
15 15  #createFormStart("homeoworld_form" "book")
16 16  
... ... @@ -20,10 +20,16 @@
20 20   "required" : "true",
21 21   "label" : "Type of book",
22 22   "aria-label" : "Select the type of book",
45 + "placeholder" : "Type",
23 23   "data-error-response-type" : "use_label_definite_1",
24 24   "data-set-space" : "true",
25 - "placeholder" : "Type",
26 - "space-reference" : "books",
48 + "select-json" : {
49 + "boektiep_1" : "Dit is boektiep 1",
50 + "boektiep_2" : "Dit is boektiep 2",
51 + "boektiep_3" : "Dit is boektiep 3",
52 + "boektiep_4" : "Dit is boektiep 4",
53 + "boektiep_5" : "Dit is boektiep 5"
54 + },
27 27   "help-block" : "Choose the type of book you would like to add."
28 28  })
29 29  
... ... @@ -38,7 +38,7 @@
38 38   "placeholder" : "Title",
39 39   "data-error-response-type" : "use_label_definite_1",
40 40   "data-query-type" : "XWQL.matchTitle",
41 - "data-query-scope" : "books",
69 + "data-query-scope" : "materia-medica",
42 42   "data-query-list-type" : "suggest-negate",
43 43   "data-query-list-header" : "$services.localization.render('formMaker.line.suggest_negate_list')",
44 44   "data-query-list-contents" : "value",
... ... @@ -55,12 +55,13 @@
55 55   "label" : "Author of the book",
56 56   "aria-label" : "Enter the author of the book",
57 57   "placeholder" : "Author",
86 + "data-error-response-type" : "use_label_definite_1",
58 58   "data-query-type" : "XWQL.matchObject",
59 59   "data-query-scope" : "books",
60 60   "data-query-list-type" : "suggest-select",
61 61   "data-query-list-header" : "$services.localization.render('formMaker.line.suggest_select_list')",
62 62   "data-query-list-contents" : "value",
63 - "data-query-list-editable" : "false",
92 + "data-query-list-editable" : "true",
64 64   "data-create-xobj" : "true",
65 65   "data-xobj-classname" : "books.WebHome",
66 66   "data-xobj-fieldname" : "author",
... ... @@ -69,18 +69,6 @@
69 69  
70 70  #createFormElement($author)
71 71  
72 -#set($extra_info = {
73 - "id" : "extra_info",
74 - "type" : "checkbox",
75 - "required" : "no",
76 - "label" : "Extra information (optional)",
77 - "value" : "yes"
78 -})
79 -
80 -#createFormElement($extra_info)
81 -
82 -#createExpandStart("extra_info" "yes")
83 -
84 84  #set($publish_year = {
85 85   "id" : "publish_year",
86 86   "type" : "number",
... ... @@ -96,8 +96,27 @@
96 96  
97 97  #createFormElement($publish_year)
98 98  
116 +#set($extra_info = {
117 + "id" : "extra_info",
118 + "type" : "checkbox",
119 + "required" : "no",
120 + "label" : "Extra information (optional)",
121 + "value" : "yes"
122 +})
123 +
124 +#createFormElement($extra_info)
125 +
126 +#createExpandStart("extra_info" "yes")
127 +
99 99  #createExpandEnd()
100 100  
130 +#set($submit = {
131 + "id" : "create_book",
132 + "button-text" : "Create book",
133 + "help-block" : ""
134 +})
135 +#createSubmit($submit)
136 +
101 101  #createFormEnd()
102 102  
103 103  {{/html}}