Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html xmlns:th="http://www.thymeleaf.org">
- <head>
- <meta charset="UTF-8">
- <title>Formulario de Materia</title>
- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css">
- </head>
- <body class="container mt-5">
- <h2 th:text="${materia.id != null} ? 'Editar Materia' : 'Nueva Materia'"></h2>
- <form th:action="@{/subjectNew}" th:object="${materia}" method="post">
- <input type="hidden" th:field="*{id}" />
- <div class="mb-3">
- <label for="materia" class="form-label">Nombre</label>
- <input type="text" th:field="*{materia}" class="form-control" required>
- </div>
- <div class="mb-3">
- <label for="descripcion" class="form-label">Código</label>
- <input type="text" th:field="*{descripcion}" class="form-control" required>
- </div>
- <button type="submit" class="btn btn-primary">Guardar</button>
- <a href="/subject" class="btn btn-secondary">Cancelar</a>
- </form>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement