possibly close fix? #54

Merged
MrLyallCSIT merged 2 commits from possiblebrokenclose into main 2020-08-09 21:35:22 +00:00
2 changed files with 2 additions and 2 deletions

View File

@@ -15,7 +15,7 @@
}
function get_my_open_requests($db) {
$ticket_stmt = "SELECT * FROM tickets WHERE created_by=:uuid" AND status != 'Closed';
$ticket_stmt = "SELECT * FROM tickets WHERE created_by=:uuid AND status != 'Closed'";
$ticket_sql = $db->prepare($ticket_stmt);
$ticket_sql->bindParam(':uuid', $_SESSION['uuid']);
$ticket_sql->execute();

View File

@@ -10,7 +10,7 @@
if ($is_authorised == true) {
if($_SERVER['REQUEST_METHOD'] == 'POST') {
try {
$stmt = "UPDATE tickets SET status='Closed' WHERE uuid=:uuid";
$stmt = "UPDATE tickets SET status= 5 WHERE uuid=:uuid";
$sql = $db->prepare($stmt);
$sql->bindParam(':uuid', $request['uuid']);
$sql->execute();