-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaccessory.html
More file actions
70 lines (64 loc) · 2.02 KB
/
Copy pathaccessory.html
File metadata and controls
70 lines (64 loc) · 2.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
<!doctype html>
<html>
<head>
<title>Car Accessories</title>
<script
src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.7.1/jquery.min.js"
integrity="sha512-v2CJ7UaYy4JwqLDIrZUI/4hqeoQieOmAZNXBeQyjo21dadnwR+8ZaIJVT8EE2iyI61OV8e6M8PP2/4hpQINQ/g=="
crossorigin="anonymous"
referrerpolicy="no-referrer"
></script>
<script src="https://cdn.tailwindcss.com"></script>
</head>
<body class="p-6">
<h1 class="text-5xl font-bold">Car Accessories</h1>
<form id="accessoryForm" class="flex gap-4 mt-4 items-end">
<div class="flex flex-col">
<label for="accessory">Select an accessory:</label>
<select
id="accessory"
name="accessory"
class="rounded w-40 h-10 border-black border-2"
>
<option value="p111">Car Cover</option>
<option value="p222">Seat Covers</option>
<option value="p333">Floor Mats</option>
<option value="p4444">Door Visor</option>
<!-- Add more options as needed -->
</select>
</div>
<div class="flex-col flex">
<label for="amount">Amount:</label>
<input
class="rounded w-40 h-10 p-2 border-black border-2"
type="number"
id="amount"
name="amount"
min="1"
value="1"
/>
</div>
<button
type="button"
onclick="addToProductList()"
class="bg-black text-white w-40 h-10 rounded-md"
>
Add
</button>
</form>
<h2 class="mt-6 text-xl font-bold">Product List</h2>
<table id="productList" class="mt-2 max-w-screen-md w-full">
<tr class="border-black border-2 bg-black text-white">
<th>Accessory</th>
<th>Amount</th>
<th>Price</th>
</tr>
</table>
<div id="total" class="hidden">
<p class="total mt-6">Gross Price: $<span id="totalPrice">0</span></p>
<p id="vat">VAT:</p>
<p id="netPrice">Net Price:</p>
</div>
<script src="script.js"></script>
</body>
</html>