diff --git a/classes/incident.php b/classes/incident.php index 277be45..52fad06 100644 --- a/classes/incident.php +++ b/classes/incident.php @@ -104,14 +104,14 @@ class Incident $end_time = ''; } - $stmt = $mysqli->prepare("INSERT INTO status VALUES ('',?, ?, ?, ?, ?, ?)"); + $stmt = $mysqli->prepare("INSERT INTO status VALUES (NULL,?, ?, ?, ?, ?, ?)"); $stmt->bind_param("issiii", $type, $title, $text, $time ,$end_time ,$user_id); $stmt->execute(); $query = $stmt->get_result(); $status_id = $mysqli->insert_id; foreach ($services as $service) { - $stmt = $mysqli->prepare("INSERT INTO services_status VALUES ('',?, ?)"); + $stmt = $mysqli->prepare("INSERT INTO services_status VALUES (NULL,?, ?)"); $stmt->bind_param("ii", $service, $status_id); $stmt->execute(); $query = $stmt->get_result(); diff --git a/classes/service.php b/classes/service.php index b0668a5..50adc69 100644 --- a/classes/service.php +++ b/classes/service.php @@ -46,7 +46,7 @@ class Service { global $mysqli; $name = $_POST['service']; - $stmt = $mysqli->prepare("INSERT INTO services VALUES('',?)"); + $stmt = $mysqli->prepare("INSERT INTO services VALUES(NULL,?)"); $stmt->bind_param("s", $name); $stmt->execute(); $query = $stmt->get_result(); diff --git a/classes/user.php b/classes/user.php index c8b94a5..9a9cae0 100644 --- a/classes/user.php +++ b/classes/user.php @@ -114,7 +114,7 @@ class User $permission = $_POST['permission']; - $stmt = $mysqli->prepare("INSERT INTO users values ('', ?, ?, ?, ?, ?, ?, ?, 1)"); + $stmt = $mysqli->prepare("INSERT INTO users values (NULL, ?, ?, ?, ?, ?, ?, ?, 1)"); $stmt->bind_param("ssssssi", $email, $username, $name, $surname, $hash, $salt, $permission); $stmt->execute(); $query = $stmt->get_result();