Template paths set to static
This commit is contained in:
parent
4eafe2fe00
commit
4264ff0bf6
@ -10,13 +10,9 @@
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<header>
|
<header>
|
||||||
<div class="headerColumn"><a href="http://127.0.0.1:8000"><div class="logoIcon"></div></a></div>
|
<div class="headerColumn"><a href="/"><div class="logoIcon"></div></a></div>
|
||||||
<div class="headerColumn">
|
<div class="headerColumn"><span id="purchasementsUrl"><a href="/purchasements">Lista zamówień</a></span></div>
|
||||||
<span id="purchasementsUrl"><a href="/purchasements">Lista zamówień</a></span></div>
|
<div class="headerColumn"><a href="/cart"><div class="cartIcon"><div class="cartItems">{{.cart.ItemsTotal}}</div></div></a></div>
|
||||||
<div class="headerColumn">
|
|
||||||
<a href="/cart"><div class="cartIcon"><div class="cartItems">{{.cart.ItemsTotal}}</div></div></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</header>
|
</header>
|
||||||
<div id="container">{{template "content" .}}</div>
|
<div id="container">{{template "content" .}}</div>
|
||||||
</body>
|
</body>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{{define "content"}}
|
{{define "content"}}
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
function deleteitem(id) {
|
function deleteitem(id) {
|
||||||
location.href = 'http://127.0.0.1:8000/removeFromCart?id=' + id;
|
location.href = '/removeFromCart?id=' + id;
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<h1>Koszyk</h1>
|
<h1>Koszyk</h1>
|
||||||
@ -15,7 +15,7 @@ function deleteitem(id) {
|
|||||||
{{range $.cart.Products}}
|
{{range $.cart.Products}}
|
||||||
<div class="cartItem">
|
<div class="cartItem">
|
||||||
<div class="cartItemColumn">
|
<div class="cartItemColumn">
|
||||||
<a href="http://127.0.0.1:8000/product?id={{ .Product.Id }}"><b>{{ .Product.Name }}</b>
|
<a href="/product?id={{ .Product.Id }}"><b>{{ .Product.Name }}</b>
|
||||||
<div class="cartItemIcon" style="background-image: url({{ .Product.ImgUrl }});"></div></a>
|
<div class="cartItemIcon" style="background-image: url({{ .Product.ImgUrl }});"></div></a>
|
||||||
</div>
|
</div>
|
||||||
<div class="cartItemColumn">{{ .Product.Price }} zł</div>
|
<div class="cartItemColumn">{{ .Product.Price }} zł</div>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{{define "content"}}
|
{{define "content"}}
|
||||||
<h1>{{.category.Name}}</h1>
|
<h1>{{.category.Name}}</h1>
|
||||||
{{range $.products}}
|
{{range $.products}}
|
||||||
<a href="http://127.0.0.1:8000/product?id={{ .Id }}">
|
<a href="/product?id={{ .Id }}">
|
||||||
<div class="productTile">
|
<div class="productTile">
|
||||||
{{if le .Quantity 0}}
|
{{if le .Quantity 0}}
|
||||||
<div class="productUnavailable" style="width: 350px; position:absolute;">Produkt niedostępny</div>
|
<div class="productUnavailable" style="width: 350px; position:absolute;">Produkt niedostępny</div>
|
||||||
|
@ -34,7 +34,7 @@ function pay() {
|
|||||||
var fN = document.getElementById("fname").value;
|
var fN = document.getElementById("fname").value;
|
||||||
var lN = document.getElementById("lname").value;
|
var lN = document.getElementById("lname").value;
|
||||||
if (fN!='' && lN!='')
|
if (fN!='' && lN!='')
|
||||||
location.href = 'http://127.0.0.1:8000/paymentDone?fn=' + fN + '&ln=' + lN + "&pm=" + pM + "&dd=" + dD;
|
location.href = '/paymentDone?fn=' + fN + '&ln=' + lN + "&pm=" + pM + "&dd=" + dD;
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<h1>Podsumowanie</h1>
|
<h1>Podsumowanie</h1>
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
<a href="/category?id={{ .Id }}">
|
<a href="/category?id={{ .Id }}">
|
||||||
<div class="categoryTile">
|
<div class="categoryTile">
|
||||||
<div class="categoryTileContent">
|
<div class="categoryTileContent">
|
||||||
<div class="categoryIcon" style="background-image: url(http://127.0.0.1:8000/static/icons/{{ .Name }}.png);"></div>
|
<div class="categoryIcon" style="background-image: url(/static/icons/{{ .Name }}.png);"></div>
|
||||||
<div class="categoryName">{{ .Name }}</div>
|
<div class="categoryName">{{ .Name }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{{define "content"}}
|
{{define "content"}}
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
function buy() {
|
function buy() {
|
||||||
location.href = 'http://127.0.0.1:8000/addToCart?id=' + {{.product.Id}} + '&quantity=' + document.getElementById("quantity").value;
|
location.href = '/addToCart?id=' + {{.product.Id}} + '&quantity=' + document.getElementById("quantity").value;
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<div class="productDescription">
|
<div class="productDescription">
|
||||||
|
Loading…
Reference in New Issue
Block a user