<%-include("partials/header.ejs")%>
    <section class="order-list">
        <h2>Your Order History</h2>
        <div class="border">
<%if(locals.login){%>
    <%if(locals.items){%>
       <%items.forEach(element=>{%>
        <div class="order">
            <div class="order-details">
                <h3>Order #0<%=element.order_id%></h3>
                <p>Date: <%=element.time%></p>
                <p>Total: $<%=element.price%></p>
                <p>Status: Delivered</p>
            </div>
            <div class="btn-box" >
                <a href="#" class="btn" style="text-decoration: none;font-size: 20px;" class="as">View Details</a> 
            </div>
        </div>
        <%})}else{%>
            <div class="prints">
                <h1>No Orders found</h1>
            </div>
            <%}}else{%>
                <div class="nothings d-flex justify-content-center">
                    <h1>PLEASE LOGIN FIRST</h1>
                </div>
                <%}%>
    </div>
    </section>
    <%-include("partials/footer.ejs")%>
