Skip to content
Snippets Groups Projects
Commit d820e816 authored by Haoyu Sun's avatar Haoyu Sun
Browse files

check itemDetails and exchangeItem, button exchange and cancel function

parent c1696e3b
No related branches found
No related tags found
1 merge request!1Dev
......@@ -26,8 +26,5 @@ public class ExchangeController {
ExchangeItem exchangeItem = exchangeService.getExchangeItem(id);
modelAndView.addObject("exchangeItem", exchangeItem);
return modelAndView;
}
}
......@@ -9,6 +9,6 @@ public class ExchangeItem {
private Long id;
private String name;
private String description;
private boolean ExchangeOrNot;
private boolean MoneyOrNot;
private boolean exchangeOrNot;
private boolean moneyOrNot;
}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
</head>
<body>
<div>itemDetail</div>
</body>
<head>
<meta charset="UTF-8">
<title>Title</title>
<script>
function sendRequest() {
alert("exchange message send successful");
}
</script>
</head>
<body>
<!-- <div>itemDetail</div>-->
<table>
<!-- thead-->
<thead>
<tr>
<th>itemDetail</th>
</tr>
</thead>
<!--tbody-->
<tbody>
<tr>
<td>Id</td>
<td th:text="${exchangeItem.id}"></td>
</tr>
<tr>
<td>ItemName</td>
<td th:text="${exchangeItem.name}"></td>
</tr>
<tr>
<td>Description</td>
<td th:text="${exchangeItem.description}"></td>
</tr>
<tr>
<td>exchangeOrNot</td>
<td th:text="${exchangeItem.exchangeOrNot}"></td>
</tr>
<tr>
<td>exchangeOrNot</td>
<td th:text="${exchangeItem.moneyOrNot}"></td>
</tr>
</tbody>
</table>
<a th:href="@{/exchange}" style="text-decoration: none">
<button onclick="sendRequest()">EXCHANGE</button>
</a>
<a th:href="@{/exchange}" style="text-decoration: none">
<button>Cancel</button>
</a>
</body>
</html>
\ No newline at end of file
......@@ -22,7 +22,7 @@
<td th:text="${exchangeItem.name}"></td>
<td th:text="${exchangeItem.description}"></td>
<td>
<button><a th:href="@{/exchange/{link} (link=${exchangeItem.id})}">
<button><a th:href="@{/exchange/{link} (link=${exchangeItem.id})}" style="text-decoration: none">
seeDetails
</a></button>
</td>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment