<{* Template: basket.html Description: This template handles the basket view Author: 1260 A/S, @1260-digital Since: 2022-09-01 *}> <{capture name="noindex"}> noindex <{/capture}> <{capture name="title_basket_value"}> <{$price|number_format:2:$smarty.capture.decimal:$smarty.capture.thousand}> <{$currency}> <{/capture}> <{capture name="title"}> <{t section="Address" x=$total_amount y=$smarty.capture.title_basket_value s=$webshop->getName()}>You have {x} item(s) in your basket at a total of {y} - {s}<{/t}> <{/capture}>

<{t section="Basket"}>Basket<{/t}>

<{if $basket}> <{include file="components/button.html" variant="action" size="md" text="Go to checkout"|t type="link" href="/address"}> <{/if}> <{if $get.s == "NaN"}> <{include file="components/alert.html" variant="error" icon="x" text="One or more items are not in stock"|t}> <{/if}>
<{if $basket}>
<{include file="components/shipping-notice.html"}> <{if $get.check_fail == "1"}> <{include file="components/alert.html" variant="error" icon="x" text="One or more items are not in stock"|t}> <{/if}>
    <{section name="i" loop=$basket}>
  • <{include file="components/product-card-list.html" class="product-card-list--lg"}>
  • <{/section}>
<{include file="components/share-basket.html" class="basket__actions"}> <{if $settings.checkout_cart.enable_related_products}>
<{assign var="products" value=$webshop->getPopularProducts()}> <{if !$products}> <{assign var="products" value=$webshop->getOnlineProducts()}> <{/if}>

<{t}>Others also bought<{/t}>

<{if $settings.integrations.enable_clerk && $settings.integrations.clerk_api_key && $settings.integrations.clerk_basket }> <{include file="components/external-products.html" list_class="product-grid product-grid--basket-upsell" list_item_class="product-grid__item" external="clerk" max="4" endpoint="recommendations/most_sold_with" current_product=$products[0]->getProductId()}> <{else}>
    <{section name="i" loop=$products max=4}> <{assign var="profile" value=$products[i]->getProfile()}> <{assign var="profile_tag" value=$profile->getTag()}> <{if $profile_tag != "credit"}>
  • <{include file="components/product-card.html" class="product-card--sm" show_add_to_cart="true" product=$products[i]}>
  • <{/if}> <{/section}>
<{/if}>
<{/if}> <{else}>

<{t}>Your basket is empty. What about one of these popular products?<{/t}>

<{assign var="products" value=$webshop->getPopularProducts()}> <{if !$products}> <{assign var="products" value=$webshop->getOnlineProducts()}> <{/if}>
    <{section name="i" loop=$products max=4}> <{assign var="profile" value=$products[i]->getProfile()}> <{assign var="profile_tag" value=$profile->getTag()}> <{if $profile_tag != "credit"}>
  • <{include file="components/product-card.html" product=$products[i] class="product-card--sm" show_add_to_cart="true" }>
  • <{/if}> <{/section}>
<{/if}>
<{if $settings.checkout.enable_voucher && $settings.checkout_cart.enable_voucher}>
<{include file="components/voucher.html" class="" show_title="true"}>
<{/if}>
<{include file="components/order-summary-table.html" show_title="true" fragment="orderSummaryTable"}> <{if $webshop->hasLoyaltyProgram() && $customer}>
<{capture name="hasLoyaltyProgram"}> <{t x=$customer->getActivePoints()|number_format:0:",":"."}>Du har {x} aktive point.<{/t}> <{/capture}> <{include file="components/alert.html" variant="info" text=$smarty.capture.hasLoyaltyProgram}> <{/if}> <{include file="components/button.html" variant="action" class="btn--block basket__order-button" size="md" text="Go to checkout"|t type="link" href="/address"}> <{if $settings.shipping_alert.enable && $settings.shipping_alert.time && $settings.shipping_alert.days}>
<{include file="components/shipping-alert.html" class="alert--sm alert--block alert--text-center"}>
<{/if}> <{include file="components/icon-list-payment-methods.html" class="basket__icon-list"}> <{include file="components/icon-list-shipping-methods.html" class="basket__icon-list"}>