diff --git a/content/contents/balkonkraftwerk.blade.php b/content/contents/balkonkraftwerk.blade.php index 502bfb5..573143b 100644 --- a/content/contents/balkonkraftwerk.blade.php +++ b/content/contents/balkonkraftwerk.blade.php @@ -4,6 +4,7 @@ + @stop @section('content')
@@ -27,11 +28,9 @@ Inkl. MwSt.
- @if(2==2) Sofort verfügbar! - @elseif(2==3) Nachschub ist unterwegs. Jetzt vorbestellen! @@ -45,47 +44,30 @@

- -
-
- - - @if(1==rand(1,2)) - - @else - - - - @endif + +
- -
+ - - - - -

diff --git a/content/master.blade.php b/content/master.blade.php index 076a22d..bbc605c 100644 --- a/content/master.blade.php +++ b/content/master.blade.php @@ -153,6 +153,19 @@ $('#count-products-in-bag').hide(); } $('#total-price').text(formatter.format(totalPrice)); + let productId = $('meta[name="product-id"]').attr('content'); + if(productId != undefined){ + if(objProducts.find(obj => obj.id == productId) == undefined) { + $('#btn-add-to-bag').show(); + $('#btn-show-bag').hide(); + $('#btn-check-out').parent().show(); + } + else { + $('#btn-add-to-bag').hide(); + $('#btn-show-bag').show(); + $('#btn-check-out').parent().hide(); + } + } } function addToBag(productId){ let objProductInfo = objProducts.find(obj => obj.id == productId);