Fix Create / Copy Trips missing trip_id

This commit is contained in:
johnnyq 2024-11-23 11:45:32 -05:00
parent b2651f7445
commit 504b28ee4c
1 changed files with 2 additions and 0 deletions

View File

@ -11,6 +11,8 @@ if (isset($_POST['add_trip'])) {
mysqli_query($mysqli,"INSERT INTO trips SET trip_date = '$date', trip_source = '$source', trip_destination = '$destination', trip_miles = $miles, round_trip = $roundtrip, trip_purpose = '$purpose', trip_user_id = $user_id, trip_client_id = $client_id");
$trip_id = mysqli_insert_id($mysqli);
// Logging
logAction("Trip", "Create", "$session_name logged trip from $source to $destination", $client_id , $trip_id);