Lifesoft

list.html

코드 1
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>메모 목록</title>
<link rel="stylesheet" href="/css/main.css">
</head>
<body>
<h1>메모 목록</h1>
<form method="post" action="/search">
<input type="text" name="keyword" th:value="${keyword}" placeholder="제목 검색">
<button type="submit">검색</button>
<button type="button" onclick="location.href='/write'">메모 작성</button>
</form>
<table border="1">
<tr>
<th>번호</th>
<th>제목</th>
<th>작성일</th>
</tr>
<tr th:each="memo, stat : ${memos}">
  <td th:text="${stat.count}">번호</td>
  <td><a th:href="@{/edit/{id}(id=${memo.id})}" th:text="${memo.title}">제목</a></td>
  <td th:text="${#temporals.format(memo.reg_date, 'yyyy-MM-dd HH:mm:ss')}">작성일</td>
</tr>
</table>
</body>
</html>