<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<SportsStore.Domain.Entities.Cart>" %>

<% if(Model.Lines.Count > 0) { %> 
    <div id="cart">
        <span class="caption"> 
            <b>Twój koszyk:</b> 
            sztuk: <%: Model.Lines.Sum(x => x.Quantity) %>,
            wartość: <%: Model.ComputeTotalValue().ToString("c") %> 
        </span> 
        <%: Html.ActionLink("Zamówienie", "Index", "Cart",  
            new { returnUrl = Request.Url.PathAndQuery }, null)%> 
    </div> 
<% } %> 
