aboutsummaryrefslogtreecommitdiff
path: root/app/views/pages/sales/currentSales.scala.html
blob: 30cea781607fec1ed8f998e446ed1bd96416b525 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
@(sales: Seq[Views.Sale])(implicit request: AuthRequest[AnyContent], flash: Flash, token: play.filters.csrf.CSRF.Token)

@templates.ebe("Sales")(request.account) {

	<div class="action-buttons pure-g">
	@fragments.ebeMainActions()
	</div>

	<br>

	<div class="pure-g">
		<div class="pure-u-1 pure-u-lg-1-1">
			<div class="l-box">
				<h2>Current sales</h2>

				<table class="pure-table pure-table-horizontal">

					<thead>
						<tr>
							<td>End date</td>
							<td>Item</td>
							<td>Current price</td>
						</tr>
					</thead>

					<tbody>
					@for(sale <- sales) {
						<tr>
							<td>@sale.endDate</td>
							<td><a href="@routes.Sale.item(sale.itemUuid.get)">@sale.itemName</a></td>
							<td>@if(sale.bestOffer.isDefined) {@sale.bestOffer} else {sale.initialPrice} €</td>
						</tr>
					}
					</tbody>

				</table>
			</div>
		</div>
	</div>

}