Elektromarket/templates/category.html

18 lines
643 B
HTML
Raw Normal View History

{{define "content"}}
<h1>{{.category.Name}}</h1>
{{range $.products}}
2018-10-27 17:30:25 +02:00
<a href="/product?id={{ .Id }}">
<div class="productTile">
{{if le .Quantity 0}}
<div class="productUnavailable" style="width: 350px; position:absolute;">Produkt niedostępny</div>
{{end}}
<div class="categoryTileContent">
<div class="productIcon" style="background-image: url({{ .ImgUrl }});"></div>
<div class="categoryName">{{ .Name }}</div>
<div class="productPrice">{{ .Price }} zł</div>
</div>
</div>
</a>
{{end}}
{{end}}