-
Notifications
You must be signed in to change notification settings - Fork 0
/
list.php
75 lines (61 loc) · 2.66 KB
/
list.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
<?php
require "session/sessionBranchAdmin.php";
require "includes/header.php";
require "includes/sidebarBranchAdmin.php";
require "includes/connection.php";
?>
<!-- End of Sidebar -->
<!-- Content Wrapper -->
<div id="content-wrapper" class="d-flex flex-column">
<!-- Main Content -->
<div id="content">
<!-- Topbar -->
<?php
require "includes/topbar.php";
?>
<!-- End of Topbar -->
<div class="container-fluid">
<table class="table table-light table-hover border" id="tellerListTable" style="text-align: center;">
<thead class="thead-dark">
<tr>
<th class='border border-top border-bottom' style=""></th>
<th class='border border-top border-bottom' style="">Employee ID</th>
<th class='border border-top border-bottom' style="">Full Name</th>
<th class='border border-top border-bottom' style="">Position</th>
<th class='border border-top border-bottom' style="">Delete</th>
</tr>
</thead>
<tbody id="tellerList">
<?php
$branchCode = $_SESSION["branchCode"];
$type = "user";
$deleted = 1;
$count = 0;
$sql = $conn->prepare("SELECT * FROM dbo.teller WHERE type=:type AND deleted!=:deleted AND branchCode=:branchCode");
$sql->execute([
"type" => $type,
"deleted" => $deleted,
"branchCode" => $branchCode
]);
while($row = $sql->fetch()){
echo "
<tr>
<td>".++$count."</td>
<td>$row[employeeID]</td>
<td>$row[fullname]</td>
<td>$row[position]</td>
<td><button class='btn btn-danger dltBtn'><i class='fa fa-trash'></i></button></td>
</tr>
";
}
?>
</tbody>
</table>
</div>
<!-- Begin Page Content -->
<!-- /.container-fluid -->
</div>
<!-- End of Main Content -->
<?php
require "includes/footer.php";
?>