-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
494 lines (407 loc) · 18 KB
/
index.html
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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Tookuw POS</title>
<!-- Bootstrap -->
<link rel="stylesheet" href="./vendors/bootstrap/css/bootstrap.min.css">
<!-- Font Awesome -->
<link rel="stylesheet" href="./vendors/fontawesome/css/all.min.css">
<!-- Animate CSS -->
<link rel="stylesheet" href="./vendors/animate/animate.min.css" />
<!-- The Style -->
<link rel="stylesheet" href="./style.css">
</head>
<body>
<!-- Main Top Navigation Bar -->
<nav id="main-navbar" class="navbar navbar-dark bg-primary shadow py-0">
<!-- Toggler Button -->
<button class="navbar-toggler text-light border-0 mr-2" data-toggle="collapse" data-target="#hidden-sidebar">
<i class="fas fa-bars"></i>
</button>
<!-- End of Toggler Button -->
<!-- Business Name -->
<a class="navbar-brand d-none d-sm-block text-uppercase" href="#">Tookuw</a>
<!-- Profile Button -->
<div class="dropdown ml-auto">
<button type="button" href="#" class="btn text-white dropdown-toggle" data-toggle="dropdown">
<span class="font-weight-bold mr-2">Jalu</span>
<i class="fas fa-user-ninja bg-dark p-3 rounded-circle"></i>
</button>
<div class="dropdown-menu" style="min-width: 7.5rem;">
<a class="dropdown-item" href="#"><small>Profile</small></a>
<a class="dropdown-item" href="#"><small>Logout</small></a>
</div>
</div>
<!-- End of Profile Button -->
</nav>
<!-- End of Main Top Navigation Bar -->
<!-- Main Content Wrapper -->
<div class="d-flex">
<!-- Sidebar (hidden by default)-->
<nav class="bg-dark collapse px-1" id="hidden-sidebar">
<ul class="navbar-nav mt-4">
<li class="nav-item text-center">
<a href="" class="text-light">
<span><i class="fas fa-fw fa-cash-register fa-lg"></i></span>
</a>
</li>
<li class="nav-item text-center">
<a href="" class="text-light">
<span><i class="fas fa-fw fa-receipt fa-lg"></i></span>
</a>
</li>
<li class="nav-item text-center">
<a href="" class="text-light">
<span><i class="fas fa-fw fa-gift fa-lg"></i></span>
</a>
</li>
<li class="nav-item text-center">
<a href="" class="text-light">
<span><i class="fas fa-fw fa-user fa-lg"></i></span>
</a>
</li>
<li class="nav-item text-center">
<a href="" class="text-light">
<span><i class="fas fa-fw fa-cog fa-lg"></i></span>
</a>
</li>
</ul>
</nav>
<!-- End of Sidebar -->
<!-- Main Content -->
<main class="w-100 mt-2 p-lg-2" id="body-content">
<!-- Main Content Start Here -->
<div id="main-container" class="container-fluid mt-2">
<div class="row">
<!-- Catalog Wrapper -->
<div class="col-md-6 col-lg-7 col-xl-8 px-0 px-md-3">
<!-- Charge Button (only shown on mobile) -->
<div class="card shadow d-md-none mb-3 mx-3">
<div class="card-body d-flex justify-content-between align-items-center">
<button class="btn btn-outline-secondary" data-toggle="modal" data-target="#receipt-modal">
<h4 class="mb-0">
Receipt
<span id="item-counter" class="badge badge-light d-inline-block ml-3"></span>
</h4>
</button>
<a href="#" class="add-customer-btn btn" data-toggle="modal" data-target="#user-modal">
<i class="fas fa-user-plus"></i>
</a>
</div>
<div class="btn-group" role="group" aria-label="Basic example">
<button class="save-receipt-btn btn btn-success rounded-0 text-uppercase">Save</button>
<button class="charge-btn btn btn-success rounded-0 text-uppercase">
<span class="d-block">Charge</span>
<span class="total-due d-block"></span>
</button>
</div>
</div>
<!-- Charge Button (only shown on mobile) -->
<!-- Product Catalog -->
<div class="card shadow rounded-bottom" style="border-radius: 0;">
<!-- Catalog Search Bar -->
<div class="card-header d-flex bg-white align-items-center mt-2 pb-3 justify-content-between">
<h4 class="d-none d-sm-block mb-0">Catalog</h4>
<input type="text" class="form-control rounded-pill" id="search-catalog" placeholder="Search...">
</div>
<!-- End of Catalog Search Bar -->
<!-- Catalog Body -->
<div class="card-body" style="height:485px;overflow-y:scroll;">
<!-- Catalog item is generated dynamically by javascript -->
<div id="catalog" class="list-group list-group-flush"></div>
</div>
<!-- End of Catalog Body -->
</div>
<!-- End of Product Catalog -->
</div>
<!-- End of Catalog Wrapper -->
<!-- Checkout Card Wrapper (hidden on mobile) -->
<div class="col-md-6 col-lg-5 col-xl-4 d-none d-md-block">
<!-- Checkout Card -->
<div class="card shadow mb-3" id="bill-card">
<div class="card-body pr-0">
<!-- Checkout Header -->
<div class="d-flex justify-content-between align-items-center mb-3">
<h4 class="text-center">Receipt</h4>
<a href="#" class="add-customer-btn btn" data-toggle="modal" data-target="#user-modal">
<i class="fas fa-user-plus"></i>
</a>
</div>
<!-- Receipt List Wrapper -->
<ul class="receipt-list-group list-group list-group-flush mb-1" style="height:220px;overflow-y:scroll">
<!-- Receipt - Header -->
<li class="list-group-item pl-1 pr-2 d-flex justify-content-between align-items-center bg-light">
<p class="receipt-item-name">Item</p>
<p class="receipt-item-action text-center">Qty</p>
<p class="receipt-item-total text-right">Total</p>
</li>
<!-- End of Receipt Header -->
<!-- List of Receipt Item -->
<div class="receipt-list-item"></div>
<!-- Discount -->
<div class="discount-line border-top"></div>
</ul>
<!-- End of Receipt List Wrapper -->
<!-- Receipt - Apply Discount -->
<li class="list-group-item pl-1 pr-3 d-flex justify-content-between align-items-center mb-4"
style="border:none">
<a href="#" class="apply-discount-btn text-muted border-none" style="text-decoration:none;">Apply
Discount</a>
<input type="text" class="discount-input form-control text-right w-25">
</li>
<!-- Receipt - Total -->
<li class="list-group-item pl-1 pr-3 d-flex justify-content-between align-items-center"
style="border:none;">
<h4 class="font-weight-bold">Total</h4>
<h4 class="total-due font-weight-bold">0</h4>
</li>
</div>
</div>
<!-- End of Checkout Card -->
<!-- Charge Button -->
<div class="card shadow">
<div class="card-body d-flex justify-content-between">
<button class="save-receipt-btn btn btn-outline-secondary text-uppercase w-50 mr-2">Save</button>
<button class="charge-btn btn btn-primary text-uppercase w-50">Charge</button>
</div>
</div>
<!-- Charge Button -->
</div>
<!-- End of Checkout Card Wrapper-->
</div>
</div>
</main>
<!-- End of Main Content -->
</div>
<!-- End of Main Content Wrapper -->
<!-- Customer Modal -->
<div class=" modal fade" id="user-modal" tabindex="-1">
<div class="modal-dialog modal-dialog-centered">
<div class="modal-content">
<div class="modal-body">
<!-- Tab Navigation -->
<ul class="nav nav-tabs" id="myTab" role="tablist">
<li class="nav-item">
<a class="nav-link active" id="home-tab" data-toggle="tab" href="#home">Customers</a>
</li>
<li class="nav-item">
<a class="nav-link" id="profile-tab" data-toggle="tab" href="#profile">Add New</a>
</li>
<li class="nav-item ml-auto">
<button type="button" class="close" data-dismiss="modal">
<span>×</span>
</button>
</li>
</ul>
<!-- End of Tab Navigation -->
<div class="tab-content" id="myTabContent">
<!-- Customer List Tab Pane -->
<div class="tab-pane fade show active" id="home">
<input type="text" class="form-control mt-3 mb-3" id="search-customer" placeholder="Search...">
<form action="#" id="customer-select-form" name="customer">
<!-- Customer List is generated dynamically by Javascript -->
<ul id="customer-list" class="list-group list-group-flush" style="height:108px;overflow-y:scroll;"></ul>
<div class="d-flex">
<button id="clear-customer-btn"
class="btn btn-outline-secondary w-100 mr-2 text-uppercase">Clear</button>
<button id="select-customer-btn" class="btn btn-primary w-100 text-uppercase">Select</button>
</div>
</form>
</div>
<!-- End of Customer List Tab Pane -->
<!-- Add New Customer Tab Pane -->
<div class="tab-pane fade" id="profile">
<form id="new-customer-form" name="newCustomerForm" class="mt-3">
<div class="form-group">
<input type="text" class="form-control" id="inputName" placeholder="Name">
</div>
<div class="form-group">
<input type="text" class="form-control" id="inputAddress" placeholder="Address">
</div>
<div class="form-group">
<input type="text" class="form-control" id="inputPhone" placeholder="Phone">
</div>
<button type="submit" class="btn btn-primary btn-block">Save Data</button>
</form>
</div>
<!-- End of Customer List Tab Pane -->
</div>
</div>
</div>
</div>
</div>
<!-- End of User Modal -->
<!-- Payment Modal -->
<div id="payment-modal" class="modal fade" tabindex="-1">
<div class="modal-dialog modal-dialog-centered modal-dialog-scrollable">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">Payment</h5>
<button type="button" class="close" data-dismiss="modal">
<span>×</span>
</button>
</div>
<div class="modal-body">
<form id="payment-form" name="paymentForm" action="#" method="post">
<div class="text-center mb-4 bg-light py-4">
<p class="mb-0"><small>Total Due</small></p>
<h2 id="total-due" class="mb-0 font-weight-bold"></h2>
</div>
<div class="form-group">
<label for="payment-received"><small>Received</small></label>
<input id="payment-received" class="form-control" type="text" name="" required="">
</div>
<div class="form-group">
<label for=""><small>Payment Method</small></label>
<ul class="payment-method-list list-group list-group-flush" style="height:108px;overflow-y:scroll;"></ul>
</div>
</form>
</div>
<div class="modal-footer">
<button form="payment-form" type="submit" id="proceed-payment-btn"
class="btn btn-primary btn-block text-uppercase">Proceed</button>
</div>
</div>
</div>
</div>
<!-- End of Payment Modal -->
<!-- Payment Success Modal -->
<div id="payment-success-modal" class="modal fade" tabindex="-1">
<div class="modal-dialog modal-dialog-centered modal-dialog-scrollable">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">Payment Succesful</h5>
<button type="button" class="close" data-dismiss="modal">
<span>×</span>
</button>
</div>
<div class="modal-body">
<div class="d-flex justify-content-around mb-4">
<div class="text-center bg-light py-4 flex-grow-1 mr-2">
<p class="mb-0"><small>Total Paid</small></p>
<h2 id="total-paid--modal" class="mb-0 font-weight-bold">0</h2>
</div>
<div class="text-center bg-light py-4 flex-grow-1">
<p class="mb-0"><small id="payment-effect-title">Change/Due</small></p>
<h2 id="payment-effect-amount" class="mb-0 font-weight-bold">0</h2>
</div>
</div>
<ul class="list-group">
<li class="list-group-item d-flex justify-content-between align-items-center">
<div>
<small class="text-muted">Date</small>
<h6 class="my-0">20 August 2020</h6>
</div>
<i class="fas fa-check-circle"></i>
</li>
<li class="list-group-item d-flex justify-content-between align-items-center">
<div>
<small class="text-muted">Method</small>
<h6 id="payment-method--modal" class="my-0"></h6>
</div>
<i class="fas fa-check-circle"></i>
</li>
<li class="list-group-item d-flex justify-content-between align-items-center">
<div>
<small class="text-muted">From</small>
<h6 id="from-customer--modal" class="my-0">-</h6>
</div>
<i class="fas fa-check-circle"></i>
</li>
</ul>
</div>
<div class="modal-footer">
<div class="w-100">
<button type="button" id="new-sale-btn" class="btn btn-primary btn-block text-uppercase"
data-dismiss="modal">New Sale</button>
</div>
</div>
</div>
</div>
</div>
<!-- End of Payment Success Modal -->
<!-- Alert modal -->
<div id="alert-modal" class="modal fade" tabindex="-1" role="dialog">
<div class="modal-dialog modal-dialog-centered" role="document">
<div class="modal-content">
<div class="modal-body text-center pt-4"></div>
</div>
</div>
</div>
<!-- Spinner modal -->
<div id="spinner-modal" class="modal fade" tabindex="-1" role="dialog">
<div class="modal-dialog modal-dialog-centered" role="document">
<div class="modal-content" style="background-color:transparent;border:none">
<div class="modal-body text-center pt-4">
<i class="fas fa-spinner fa-pulse fa-3x text-white"></i>
</div>
</div>
</div>
</div>
<!-- Receipt Modal -->
<div id="receipt-modal" class="modal fade" tabindex="-1" role="dialog">
<div class="modal-dialog modal-dialog-centered modal-dialog-scrollable" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">Receipt Detail</h5>
<button type="button" class="close" data-dismiss="modal">
<span>×</span>
</button>
</div>
<div class="modal-body">
<!-- Receipt List Wrapper -->
<ul id="mobile-receipt" class="receipt-list-group list-group list-group-flush mb-1">
<!-- Receipt - Header -->
<li class="list-group-item pl-1 pr-2 d-flex justify-content-between align-items-center bg-light">
<p class="receipt-item-name">Item</p>
<p class="receipt-item-action text-center">Qty</p>
<p class="receipt-item-total text-right">Total</p>
</li>
<!-- End of Receipt Header -->
<!-- List of Receipt Item -->
<div class="receipt-list-item"></div>
<!-- Discount -->
<div class="discount-line"></div>
</ul>
</div>
<div class="modal-footer py-1">
<!-- Receipt - Apply Discount -->
<li class="list-group-item pl-1 pr-0 d-flex justify-content-between align-items-center" style="border:none">
<a href="#" class="apply-discount-btn text-muted border-none" style="text-decoration:none;">Apply
Discount</a>
<input type="text" class="discount-input form-control text-right w-25">
</li>
</div>
</div>
</div>
</div>
<!-- Receipt - Quantity Modal (shown on qty click) -->
<div class="modal fade" id="item-qty-modal" tabindex="-1">
<div class="modal-dialog modal-dialog-centered modal-sm">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title"></h5>
<button type="button" class="close" data-dismiss="modal">
<span>×</span>
</button>
</div>
<div class="modal-body">
<input type="number" name="" id="qty-input--modal" class="form-control">
</div>
<div class="modal-footer">
<button type="button" id="set-item-qty-btn" class="btn btn-primary btn-block text-uppercase" data-item-id=""
data-dismiss="modal">Set Quantity</button>
</div>
</div>
</div>
</div>
<!-- End of Receipt Quantity Modal -->
<!-- Bootstrap and its dependencies -->
<script src="./vendors/jquery/jquery.slim.min.js"></script>
<script src="./vendors/bootstrap/js/bootstrap.min.js"></script>
<!-- The Script -->
<script type="module" src="./script.js"></script>
</body>
</html>