Browse Source

Update REST API help reference page

Signed-off-by: Pekka Helenius <fincer89@hotmail.com>
v0.0.2-alpha
Pekka Helenius 4 years ago
parent
commit
73960c2b17
2 changed files with 17 additions and 0 deletions
  1. +1
    -0
      bookstore/src/main/resources/messages.properties
  2. +16
    -0
      bookstore/src/main/resources/templates/apiref.html

+ 1
- 0
bookstore/src/main/resources/messages.properties View File

@ -70,6 +70,7 @@ page.text.apiref.book.add = Adding a book
page.text.apiref.book.add.a = Without author and category information\:
page.text.apiref.book.add.b = With author and category information\:
page.text.apiref.book.add.c = Without author and with category information\:
page.text.apiref.book.add.d = With author's last name\:
page.text.apiref.book.info.a = Category is correctly mapped even if letter case is not correct.


+ 16
- 0
bookstore/src/main/resources/templates/apiref.html View File

@ -256,6 +256,22 @@
</td>
</tr>
<tr>
<td class="apiref-table-right">
<small th:text="${#messages.msgOrNull('page.text.apiref.book.add.d')} ?: 'page.text.apiref.book.add.d'">
page.text.apiref.book.add.d
</small>
<br>
<code th:text="'curl --include --request POST --header &quot;Content-Type: application/json&quot; --data \'{&quot;title&quot;:&quot;Halo: The Flood&quot;,&quot;year&quot;:2003,&quot;isbn&quot;:&quot;0345459-210&quot;,&quot;price&quot;:24.99,&quot;category&quot;:{&quot;name&quot;:&quot;sCi-fI&quot;},&quot;author&quot;:{&quot;lastname&quot;:&quot;Dietz&quot;}}\' ' + ${baseUrl} + 'api/booklist'">
code placeholder
</code>
<br>
<small th:text="${#messages.msgOrNull('page.text.apiref.book.info.a')} ?: 'page.text.apiref.book.info.a'">
page.text.apiref.book.info.a
</small>
</td>
</tr>
<tr>
<td>
<small th:text="${#messages.msgOrNull('page.text.apiref.unix.info')} ?: 'page.text.apiref.unix.info'">page.text.apiref.unix.info</small>


Loading…
Cancel
Save