-
Notifications
You must be signed in to change notification settings - Fork 0
/
inventory.php
179 lines (175 loc) · 11 KB
/
inventory.php
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
<?php
include_once 'functions/authentication.php';
include_once 'functions/view/datatable.php';
include_once 'functions/view/nav-bar.php';
?>
<!DOCTYPE html>
<html data-bs-theme="light" id="bg-animation" lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, shrink-to-fit=no">
<title>Sales & Transactions - RMMFBS</title>
<meta name="description" content="Rental Management and Monitoring for a Fashion Boutique">
<link rel="icon" type="image/png" sizes="512x512" href="assets/img/boutique.png">
<link rel="icon" type="image/png" sizes="512x512" href="assets/img/boutique.png">
<link rel="icon" type="image/png" sizes="512x512" href="assets/img/boutique.png">
<link rel="icon" type="image/png" sizes="512x512" href="assets/img/boutique.png">
<link rel="icon" type="image/png" sizes="512x512" href="assets/img/boutique.png">
<link rel="stylesheet" href="assets/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" href="assets/bootstrap/css/bootstrap-select.min.css">
<link rel="stylesheet" href="assets/css/Nunito.css">
<link rel="stylesheet" href="assets/css/dataTables.min.css">
<link rel="stylesheet" href="assets/fonts/fontawesome-all.min.css">
</head>
<body id="page-top">
<div id="content">
<nav class="navbar navbar-expand-lg mb-4 shadow navbar-light">
<div class="container-fluid"><img src="assets/img/boutique.png" width="60em"><a class="navbar-brand d-flex align-items-center" href="/"><span>RMMFB</span></a><button data-bs-toggle="collapse" class="navbar-toggler" data-bs-target="#navcol-1"><span class="visually-hidden">Toggle navigation</span><span class="navbar-toggler-icon"></span></button>
<div id="navcol-1" class="collapse navbar-collapse">
<ul class="navbar-nav mx-auto">
<?php navbar(); ?>
</ul>
<a class="btn btn-light shadow" role="button" data-bs-toggle="tooltip" data-bss-tooltip="" data-bs-placement="left" href="functions/logout.php" title="Here you can logout your acccount.">Logout</a>
</div>
</div>
</nav>
<div class="container-fluid">
<div class="d-sm-flex justify-content-between align-items-center mb-4">
<h3 class="text-dark mb-0">Inventory Management</h3><button class="btn btn-dark btn-sm" type="button" data-bss-tooltip="" title="Here you can add item." data-bs-target="#add" data-bs-toggle="modal"><i class="fas fa-truck-loading fa-sm text-white-50"></i> Add Item</button>
</div>
<div class="card shadow">
<div class="card-header py-3">
<p class="text-primary m-0 fw-bold">Item List</p>
</div>
<div class="card-body">
<div class="table-responsive table mt-2" role="grid" aria-describedby="dataTable_info">
<table class="table table-striped table-bordered my-0 w-100" id="dataTable">
<thead>
<tr>
<th>ID #</th>
<th>Item</th>
<th>Description</th>
<th>Quantity</th>
<th>Price</th>
<th>Date</th>
<th class="text-center">Option</th>
</tr>
</thead>
<tbody>
<?php
item_list();
?>
</tbody>
<tfoot>
<tr></tr>
</tfoot>
</table>
</div>
</div>
</div>
</div>
</div><a class="border rounded d-inline scroll-to-top" href="#page-top"><i class="fas fa-angle-up"></i></a>
<div class="modal fade" role="dialog" tabindex="-1" id="add">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Add Item</h4><button class="btn-close" type="button" aria-label="Close" data-bs-dismiss="modal"></button>
</div>
<div class="modal-body">
<form action="functions/item-create.php" method="post">
<div class="mb-3"><label class="form-label" for="first_name"><strong>Item Name</strong></label><input class="form-control" type="text" name="name" required=""></div>
<div class="mb-3"><label class="form-label" for="first_name"><strong>Description</strong></label><input class="form-control" type="text" name="description" required=""></div>
<div class="mb-3"><label class="form-label" for="first_name"><strong>Quantity</strong></label><input class="form-control" type="number" name="qty" required="" value="1" min="1"></div>
<div class="mb-3"><label class="form-label" for="first_name"><strong>Price</strong></label><input class="form-control" type="number" name="price" required="" value="1" min="1"></div>
</div>
<div class="modal-footer"><button class="btn btn-light" type="button" data-bs-dismiss="modal">Close</button><button class="btn btn-primary" type="submit">Save</button></div>
</form>
</div>
</div>
</div>
<div class="modal fade" role="dialog" tabindex="-1" id="update">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Update Item</h4><button class="btn-close" type="button" aria-label="Close" data-bs-dismiss="modal"></button>
</div>
<div class="modal-body">
<form action="functions/item-update.php" method="post">
<input type="hidden" name="data_id">
<div class="mb-3"><label class="form-label" for="first_name"><strong>Item Name</strong></label><input class="form-control" type="text" name="name" required=""></div>
<div class="mb-3"><label class="form-label" for="first_name"><strong>Description</strong></label><input class="form-control" type="text" name="description" required=""></div>
<div class="mb-3"><label class="form-label" for="first_name"><strong>Price</strong></label><input class="form-control" type="number" name="price" required="" value="1" min="1"></div>
</div>
<div class="modal-footer"><button class="btn btn-light" type="button" data-bs-dismiss="modal">Close</button><button class="btn btn-primary" type="submit">Save</button></div>
</form>
</div>
</div>
</div>
<div class="modal fade" role="dialog" tabindex="-1" id="stock-in">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Item Stock In</h4><button class="btn-close" type="button" aria-label="Close" data-bs-dismiss="modal"></button>
</div>
<div class="modal-body">
<form action="functions/item-stock-in.php" method="post">
<input type="hidden" name="data_id">
<div class="mb-3"><label class="form-label" for="first_name"><strong>Quantity</strong></label><input class="form-control" type="number" name="qty" required="" value="1" min="1"></div>
</div>
<div class="modal-footer"><button class="btn btn-light" type="button" data-bs-dismiss="modal">Close</button><button class="btn btn-primary" type="submit">Save</button></div>
</form>
</div>
</div>
</div>
<div class="modal fade" role="dialog" tabindex="-1" id="stock-out">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Item Stock Out</h4><button class="btn-close" type="button" aria-label="Close" data-bs-dismiss="modal"></button>
</div>
<div class="modal-body">
<form action="functions/item-stock-out.php" method="post">
<input type="hidden" name="data_id">
<div class="mb-3"><label class="form-label" for="first_name"><strong>Quantity</strong></label><input class="form-control" type="number" name="qty" required="" value="1" min="1"></div>
</div>
<div class="modal-footer"><button class="btn btn-light" type="button" data-bs-dismiss="modal">Close</button><button class="btn btn-primary" type="submit">Save</button></div>
</form>
</div>
</div>
</div>
<div class="modal fade" role="dialog" tabindex="-1" id="remove">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Remove Item</h4><button class="btn-close" type="button" aria-label="Close" data-bs-dismiss="modal"></button>
</div>
<div class="modal-body">
<p>Are you sure you want to remove this item?</p>
</div>
<form action="functions/item-remove.php" method="post">
<input type="hidden" name="data_id">
<div class="modal-footer"><button class="btn btn-light" type="button" data-bs-dismiss="modal">Close</button><button class="btn btn-danger" type="submit">Remove</button></div>
</form>
</div>
</div>
</div>
<script src="assets/js/jquery.min.js"></script>
<script src="assets/bootstrap/js/bootstrap.min.js"></script>
<script src="assets/bootstrap/js/bootstrap-select.min.js"></script>
<script src="assets/js/bs-init.js"></script>
<script src="assets/js/jquery.dataTables.min.js"></script>
<script src="assets/js/dataTables.bootstrap5.min.js"></script>
<script src="assets/js/dataTables.buttons.min.js"></script>
<script src="assets/js/jszip.min.js"></script>
<script src="assets/js/pdfmake.min.js"></script>
<script src="assets/js/three.min.js"></script>
<script src="assets/js/theme.js"></script>
<script src="assets/js/vfs_fonts.js"></script>
<script src="assets/js/buttons.html5.min.js"></script>
<script src="assets/js/buttons.print.min.js"></script>
<script src="assets/js/vanta.birds.min.js"></script>
<script src="assets/js/vanta.waves.min.js"></script>
<script src="assets/js/sweetalert2.all.min.js"></script>
<script src="assets/js/main.js"></script>
</body>
</html>