Gitlab@Informatics

Skip to content
Snippets Groups Projects
Commit fa27730c authored by 65160394's avatar 65160394
Browse files

Project Round 7

parent 8335244d
Branches
No related tags found
No related merge requests found
......@@ -8,26 +8,26 @@
</head>
<body>
<main>
<h1>Create New Tour</h1>
<h1>สร้างโปรแกรม Tour</h1>
<br>
<form action="/create" method="POST">
<div>
<label for="tourName">Tour Name:</label>
<label for="tourName">ชื่อโปรแกรมทัวร์:</label>
<input type="text" id="tourName" name="name" required>
</div>
<div>
<label for="tourDescription">Description:</label>
<label for="tourDescription">รายละเอียด:</label>
<textarea id="tourDescription" name="description" required></textarea>
</div>
<div>
<label for="tourPrice">Price:</label>
<label for="tourPrice">ราคา:</label>
<input type="text" id="tourPrice" name="price" required>
</div>
<div>
<label for="tourDuration">Duration (days):</label>
<label for="tourDuration">ระยะเวลา (วัน):</label>
<input type="text" id="tourDuration" name="duration" required>
</div>
<button type="submit">Create Tour</button>
<button type="submit">สร้างโปรแกรม Tour</button>
</form>
</main>
</body>
......
......@@ -8,22 +8,22 @@
</head>
<body>
<main>
<h1>Edit Tour</h1>
<h1>แก้ไข Tour</h1>
<form action="/edit/<%= tour.id %>" method="POST">
<div>
<label for="tourName">Tour Name:</label>
<label for="tourName">ชื่อโปรแกรมทัวร์ :</label>
<input type="text" id="tourName" name="name" value="<%= tour.name %>" required>
</div>
<div>
<label for="tourDescription">Description:</label>
<label for="tourDescription">รายละเอียด:</label>
<textarea id="tourDescription" name="description" required><%= tour.description %></textarea>
</div>
<div>
<label for="tourPrice">Price:</label>
<label for="tourPrice">ราคา:</label>
<input type="number" id="tourPrice" name="price" value="<%= tour.price %>" required>
</div>
<div>
<label for="tourDuration">Duration (in days):</label>
<label for="tourDuration">ระยะเวลา (วัน):</label>
<input type="number" id="tourDuration" name="duration" value="<%= tour.duration %>" required>
</div>
<button type="submit">Update Tour</button>
......
......@@ -18,6 +18,7 @@
<input type="text" name="query" placeholder="Search for tours..." required>
<button type="submit">Search</button>
</form>
<a href="/my-bookings">My-Booking</a>
<% if (session && session.userId) { %> <!-- ตรวจสอบ session -->
<a href="/logout">Logout</a>
<% } else { %>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment