[ADD] 収支編集画面を作成しました。
This commit is contained in:
76
src/main/resources/templates/transaction_update.html
Normal file
76
src/main/resources/templates/transaction_update.html
Normal file
@@ -0,0 +1,76 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Insert title here</title>
|
||||
<link rel="stylesheet" th:href="@{/css/menu.css}">
|
||||
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.7/dist/css/bootstrap.min.css" rel="stylesheet">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div th:replace="~{header :: header}"></div>
|
||||
|
||||
<h1>取引登録</h1>
|
||||
|
||||
<form th:action="@{/transaction/update}" th:object="${transactionForm}" method="post">
|
||||
|
||||
<input type="hidden" name="transactionId" th:value="${transactionId}">
|
||||
|
||||
<div>
|
||||
<label for="transactionDate">日付</label>
|
||||
<input type="date" id="transactionDate" name="transactionDate" th:value="*{transactionDate}">
|
||||
</div>
|
||||
|
||||
<br>
|
||||
|
||||
<div>
|
||||
<label for="transactionType">収入・支出</label>
|
||||
|
||||
<select id="transactionType" th:field="*{transactionType}">
|
||||
|
||||
<option value="">選択してください</option>
|
||||
<option value="0">支出</option>
|
||||
<option value="1">収入</option>
|
||||
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<br>
|
||||
|
||||
<div>
|
||||
<label for="categoryId">カテゴリ</label>
|
||||
|
||||
<select id="categoryId" th:field="*{categoryId}">
|
||||
|
||||
<option value="">選択してください</option>
|
||||
|
||||
<option th:each="category : ${categoryFormList}" th:value="${category.categoryId}"
|
||||
th:text="${category.categoryName}">
|
||||
</option>
|
||||
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<br>
|
||||
|
||||
<div>
|
||||
<label for="amount">金額</label>
|
||||
|
||||
<input type="number" id="amount" th:field="*{amount}" min="0" placeholder="金額を入力してください">
|
||||
</div>
|
||||
|
||||
<br>
|
||||
<input type="hidden" name="today" id="today" th:value="${today}">
|
||||
|
||||
<button type="submit">登録</button>
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
||||
Reference in New Issue
Block a user