From 39a64a9ad21a93d616476b76c1e402442eebfe26 Mon Sep 17 00:00:00 2001
From: 65160381 <65160381@go.buu.ac.th>
Date: Mon, 24 Mar 2025 13:00:32 +0000
Subject: [PATCH] Update file order.ejs

---
 views/order.ejs | 16 ++++++----------
 1 file changed, 6 insertions(+), 10 deletions(-)

diff --git a/views/order.ejs b/views/order.ejs
index f2380c0..9ecffa7 100644
--- a/views/order.ejs
+++ b/views/order.ejs
@@ -5,10 +5,6 @@
       <meta charset="utf-8">
       <meta http-equiv="X-UA-Compatible" content="IE=edge">
       <meta name="viewport" content="width=device-width, initial-scale=1">
-      <!-- mobile metas -->
-      <meta name="viewport" content="width=device-width, initial-scale=1">
-      <meta name="viewport" content="initial-scale=1, maximum-scale=1">
-      <!-- site metas -->
       <title>ASA</title>
       <meta name="keywords" content="">
       <meta name="description" content="">
@@ -25,10 +21,6 @@
       <link rel="stylesheet" href="css/jquery.mCustomScrollbar.min.css">
       <!-- Tweaks for older IEs-->
       <link rel="stylesheet" href="https://netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css">
-      <!-- owl stylesheets --> 
-      <link rel="stylesheet" href="css/owl.carousel.min.css">
-      <link rel="stylesheet" href="css/owl.theme.default.min.css">
-      <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/fancybox/2.1.5/jquery.fancybox.min.css" media="screen">
    </head>
    <body>
       <!--header section start -->
@@ -69,6 +61,7 @@
       <div class="add_product_section layout_padding">
          <div class="container">
             <h1 class="gallery_taital">Add New Product</h1>
+            <% if (loggedIn) { %>
             <form action="/product/add" method="POST" enctype="multipart/form-data">
                <!-- Show error message -->
                <% if (message && message.length > 0) { %>
@@ -99,10 +92,13 @@
 
                <button class="btn btn-primary w-100 py-2" type="submit">Add Product</button>
             </form>
+            <% } else { %>
+               <p>Please log in to add a product.</p>
+            <% } %>
          </div>
       </div>
       <!-- Add Product section end -->
-
+      
       <!-- footer section start -->
       <div class="footer_section layout_padding">
          <div class="container">
@@ -120,7 +116,7 @@
                   </div>
                </div>
                <div class="col-lg-3 col-sm-6">
-                  <h1 class="useful_text">Contact Us</h1>
+                  <h3 class="useful_text">Contact Us</h3>
                   <div class="location_text">
                      <ul>
                         <li>
-- 
GitLab