-
Notifications
You must be signed in to change notification settings - Fork 0
/
inventory_logs.php
64 lines (64 loc) · 2.79 KB
/
inventory_logs.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
<?php include("includes/header.php"); ?>
<?php include('includes/navigation.php'); ?>
<?php $page_title="APICTO Inventory"; ?>
<div class="row mx-auto mt-3">
<div class="col-md-12 mb-2">
<div class="row">
<div class="col-md-12 mb-2">
<div class="card">
<div class="card-header p-2 bg-primary text-white">
Inventory Logs
</div>
<div class="card-body">
<div class="row">
<div class="col-md-12">
<table class="table table-striped table-bordered table-sm text-center" width="100%" cellspacing="0" cellpadding="0" id="tblInventoryLogs">
<thead>
<tr>
<?php
$stud_head=explode(",","Computer Name,Page,Action,Details,Date");
foreach($stud_head as $stud_val)
{
echo "<th>".$stud_val."</th>";
}
?>
</tr>
</thead>
<tbody>
<?php
$disp_computers = retrieve("SELECT * FROM inventory_logs",array());
for ($i=0; $i < count($disp_computers); $i++) {
echo "<tr>
<td>".$disp_computers[$i]['computer_name']."</td>
<td>".$disp_computers[$i]['page']."</td>
<td>".$disp_computers[$i]['action']."</td>
<td>".$disp_computers[$i]['details']."</td>
<td>".$disp_computers[$i]['date']."</td>
</tr>";
}
?>
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<?php include("includes/modal.php") ?>
<?php include('includes/footer.php'); ?>
<script>
$(document).ready(function(){
$("#tblInventoryLogs").DataTable({
"scrollX": true,
"info": true,
"lengthChange": true,
"paging": true,
"searching": true,
"pageLength":10,
"order": [[4, "desc"]],
});
})
</script>