Changes for page Books

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

From version 9.6
edited by Jip-jan Alunkel
on August 30, 21:59
Change comment: Renamed back-links.
To version 8.28
edited by Jip-jan Alunkel
on April 17, 23:24
Change comment: Updated class property

Summary

Details

Page properties
Content
... ... @@ -1,9 +1,10 @@
1 -{{include reference="assets.pagemaker.macros"/}}
1 +{{include reference="assets.formMaker.macros" /}}
2 2  
3 3  {{velocity}}
4 -#set($discard = $services.localization.use('document', 'assets.pagemaker.translations'))
5 -#set($discard = $xwiki.ssx.use('assets.pagemaker.WebHome', {'minify' : false}))
6 -#set($discard = $xwiki.jsx.use('assets.pagemaker.WebHome', {'minify' : false}))
4 +#set($discard = $services.localization.use('document', 'cases.Code.translations'))
5 +#set($discard = $services.localization.use('document', 'assets.formMaker.translations'))
6 +#set($discard = $xwiki.ssx.use('assets.formMaker.WebHome'))
7 +#set($discard = $xwiki.jsx.use('assets.formMaker.WebHome', {'minify' : false}))
7 7  
8 8  {{html wiki="true" clean="false"}}
9 9  <p>
... ... @@ -10,7 +10,7 @@
10 10  All about books
11 11  </p>
12 12  <h2 class="livetable">Overview of all books</h2>
13 -<div class="livetable">
14 +<div id="livetable">
14 14  
15 15  #set ($columns = ["doc.title", "author", "doc.space"])
16 16  #set ($columnsProperties = {
... ... @@ -34,6 +34,7 @@
34 34  </p>
35 35  
36 36  #createFormStart("homeoworld_form" "book")
38 +
37 37  #set($booktype = {
38 38   "id" : "booktype",
39 39   "type" : "select",
... ... @@ -46,7 +46,9 @@
46 46   "select-space-reference" : "books",
47 47   "help-block" : "Choose the type of book you would like to add."
48 48  })
51 +
49 49  #createFormElement($booktype)
53 +
50 50  #set($book_title = {
51 51   "id" : "book_title",
52 52   "type" : "text",
... ... @@ -56,7 +56,7 @@
56 56   "placeholder" : "Title",
57 57   "data-error-response-type" : "use_label_definite_1",
58 58   "data-query-type" : "XWQL.matchTitle",
59 - "data-query-scope" : "books",
63 + "data-query-scope" : "materia-medica",
60 60   "data-query-list-type" : "suggest-negate",
61 61   "data-query-list-header" : "$services.localization.render('formMaker.line.suggest_negate_list')",
62 62   "data-query-list-contents" : "value",
... ... @@ -63,7 +63,9 @@
63 63   "data-create-page" : "true",
64 64   "help-block" : 'When providing a title of a common type of book, please also provide the authorʼs last name, viz. Boericke Materia Medica.'
65 65  })
70 +
66 66  #createFormElement($book_title)
72 +
67 67  #set($author = {
68 68   "id" : "author",
69 69   "type" : "text",
... ... @@ -83,31 +83,38 @@
83 83   "data-xobj-fieldname" : "author",
84 84   "help-block" : 'Select the author of this case.'
85 85  })
92 +
86 86  #createFormElement($author)
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 +
87 87  #set($extra_info = {
88 88   "id" : "extra_info",
89 89   "type" : "checkbox",
90 90   "required" : "no",
91 91   "label" : "Extra information (optional)",
92 - "value" : "yes",
93 - "data-opener" : "true"
115 + "value" : "yes"
94 94  })
117 +
95 95  #createFormElement($extra_info)
96 -#createExpandStart($extra_info "yes")
97 - #set($publish_year = {
98 - "id" : "publish_year",
99 - "type" : "number",
100 - "required" : "false",
101 - "label" : "Year of publishing",
102 - "aria-label" : "Enter the year of publishing",
103 - "placeholder" : "Year",
104 - "data-error-response-type" : "use_label_definite_1",
105 - "data-create-xobj" : "true",
106 - "data-xobj-classname" : "books.WebHome",
107 - "data-xobj-fieldname" : "publish_year"
108 - })
109 - #createFormElement($publish_year)
119 +
120 +#createExpandStart("extra_info" "yes")
121 +
110 110  #createExpandEnd()
123 +
111 111  #set($submit = {
112 112   "id" : "create_book",
113 113   "button-text" : "Create book",
... ... @@ -114,6 +114,7 @@
114 114   "help-block" : ""
115 115  })
116 116  #createSubmit($submit)
130 +
117 117  #createFormEnd()
118 118  
119 119  {{/html}}