Skip to content

Commit 834b73c

Browse files
Refactor button labels in queue.php and supply.php
1 parent 048e81c commit 834b73c

File tree

3 files changed

+11
-10
lines changed

3 files changed

+11
-10
lines changed

functions/views/queue.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,10 @@
3838
<td><?php echo $row['created_at']; ?></td>
3939
<td class="text-center">
4040
<?php if ($row['status'] < 5): ?>
41-
<a class="mx-1" href="#" data-bs-target="#up" data-bs-toggle="modal" data-id="<?php echo $row['laundry_id']?>"><i class="far fa-arrow-alt-circle-up text-success" style="font-size: 20px;"></i></a>
42-
<a class="mx-1 <?php if($row['status'] <= 1) { echo 'd-none';}?>" href="#" data-bs-target="#down" data-bs-toggle="modal" data-id="<?php echo $row['laundry_id']?>"><i class="far fa-arrow-alt-circle-down" style="font-size: 20px;"></i></a>
43-
<a class="mx-1" href="tracking.php?id=<?php echo $row['id']; ?>" target="_blank"><i class="far fa-credit-card" style="font-size: 20px;"></i></a>
44-
<a class="mx-1" href="#" role="button" data-bs-target="#confirm" data-bs-toggle="modal" data-id="<?php echo $row['id']?>"><i class="far fa-trash-alt text-danger" style="font-size: 20px;"></i></a>
41+
<a class="mx-1 text-decoration-none text-success" href="#" data-bs-target="#up" data-bs-toggle="modal" data-id="<?php echo $row['laundry_id']?>"><i class="far fa-arrow-alt-circle-up text-success" style="font-size: 20px;"></i> Proceed</a>
42+
<a class="mx-1 text-decoration-none <?php if($row['status'] <= 1) { echo 'd-none';}?>" href="#" data-bs-target="#down" data-bs-toggle="modal" data-id="<?php echo $row['laundry_id']?>"><i class="far fa-arrow-alt-circle-down" style="font-size: 20px;"></i> Undo</a>
43+
<a class="mx-1 text-decoration-none" href="tracking.php?id=<?php echo $row['id']; ?>" target="_blank"><i class="far fa-credit-card" style="font-size: 20px;"></i> Tracking</a>
44+
<a class="mx-1 text-decoration-none text-danger" href="#" role="button" data-bs-target="#confirm" data-bs-toggle="modal" data-id="<?php echo $row['id']?>"><i class="far fa-trash-alt text-danger" style="font-size: 20px;"></i> Remove</a>
4545
<?php else: ?>
4646
<a class="mx-1" href="#"><i class="far fa-circle text-warning" style="font-size: 20px;"></i></a>
4747
<a class="mx-1" href="#"><i class="far fa-circle text-warning" style="font-size: 20px;"></i></a>

functions/views/supply.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
<td class="text-center">
2020
<a class="mx-1 text-decoration-none text-success" href="#" data-bs-target="#stock-in" data-bs-toggle="modal" data-id="<?php echo $row['id']?>"><i class="far fa-arrow-alt-circle-up text-success" style="font-size: 20px;"></i> Stock In</a>
2121
<a class="mx-1 text-decoration-none" href="#" data-bs-target="#stock-out" data-bs-toggle="modal" data-id="<?php echo $row['id']?>"><i class="far fa-arrow-alt-circle-down" style="font-size: 20px;"></i> Stock Out</a>
22-
<a class="mx-1" href="#" data-bs-target="#update" data-bs-toggle="modal" data-id="<?php echo $row['id']?>" data-name="<?php echo $row['name']?>" data-unit="<?php echo $row['unit']?>"><i class="far fa-edit text-warning" style="font-size: 20px;"></i></a>
23-
<a class="mx-1" href="#" data-bs-target="#remove" data-bs-toggle="modal" data-id="<?php echo $row['id']?>"><i class="far fa-trash-alt text-danger" style="font-size: 20px;"></i></a>
22+
<a class="mx-1 text-decoration-none text-warning" href="#" data-bs-target="#update" data-bs-toggle="modal" data-id="<?php echo $row['id']?>" data-name="<?php echo $row['name']?>" data-unit="<?php echo $row['unit']?>"><i class="far fa-edit text-warning" style="font-size: 20px;"></i> Update</a>
23+
<a class="mx-1 text-decoration-none text-danger" href="#" data-bs-target="#remove" data-bs-toggle="modal" data-id="<?php echo $row['id']?>"><i class="far fa-trash-alt text-danger" style="font-size: 20px;"></i> Remove</a>
2424
</td>
2525
<?php
2626

profile-staff.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,11 @@
33
include_once 'functions/connection.php';
44
$sid = $_SESSION['id'];
55
$id = $_GET['id'] ?? $sid;
6-
$sql = 'SELECT Transactions.id, Transactions.kilo, Transactions.total, Transactions.status, Transactions.created_at, users.username, customers.fullname
7-
FROM Transactions
8-
JOIN users ON Transactions.user_id = users.id
9-
JOIN customers ON Transactions.customer_id = customers.id
6+
$sql = 'SELECT l.id, l.kilo, t.total, l.status, l.created_at, users.username, customers.fullname
7+
FROM laundry AS l
8+
JOIN transactions AS t ON l.transaction_id = t.id
9+
JOIN users ON t.user_id = users.id
10+
JOIN customers ON t.customer_id = customers.id
1011
WHERE user_id = :id';
1112
$stmt = $db->prepare($sql);
1213
$stmt->bindParam(':id', $id);

0 commit comments

Comments
 (0)