Skip to content

Add UI for adding a release year to a series #1344

Closed
@php-coder

Description

@php-coder

On the src/main/webapp/WEB-INF/views/series/info.html page we should add another form to add a release year. It should have a single input and a submit button. Here is an example that can be helpful:

<option value="" th:text="#{t_year}">Year</option>
<!--/*/
<option th:each="year : ${years}" th:value="${year.key}" th:text="${year.value}"></option>
/*/-->
<!--/*-->
<option value="1990">1999</option>
<option value="2000">2000</option>
<option value="2010">2010</option>
<!--*/-->
</select>

When we submit a form, it should send a PATCH request to API /series/{id} with

[
  { "op": "add", "path": "/release_year", "value": <user data> }
]

and reload a page on success. It should show an error when server returns an error. Note that there can be 2 type of errors -- general (for a whole form) and validation error (for a particular field).

Part of #1343

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions