diff --git a/lang/en.json b/lang/en.json index 6537978..f345a85 100755 --- a/lang/en.json +++ b/lang/en.json @@ -63,5 +63,6 @@ "Are you sure you want to delete this part?": "Are you sure you want to delete this part?", "Are you sure you want to delete this category?": "Are you sure you want to delete this category?", "Image": "Image", - "Location": "Location" + "Location": "Location", + "Print QR": "Print QR" } \ No newline at end of file diff --git a/lang/nl.json b/lang/nl.json index 87d2cb8..4608c4e 100755 --- a/lang/nl.json +++ b/lang/nl.json @@ -63,5 +63,6 @@ "Are you sure you want to delete this part?": "Weet je zeker dat je dit onderdeel wilt verwijderen?", "Are you sure you want to delete this category?": "Weet je zeker dat je deze categorie wilt verwijderen?", "Image": "Afbeelding", - "Location": "Locatie" + "Location": "Locatie", + "Print QR": "Print QR" } \ No newline at end of file diff --git a/src/Controllers/ItemController.php b/src/Controllers/ItemController.php index 4a9fea1..a48dc08 100755 --- a/src/Controllers/ItemController.php +++ b/src/Controllers/ItemController.php @@ -234,9 +234,12 @@ class ItemController } $item = new Item($db, $id, $name, $description, $categoryId, null, $idCode, $imagePath, $location); + error_log("Updating item $id with image: $imagePath"); if ($item->save()) { + error_log("Item $id updated successfully"); echo json_encode(['success' => true, 'message' => 'Part updated successfully']); } else { + error_log("Failed to update item $id"); throw new Exception('Failed to update part'); } } catch (Exception $e) { diff --git a/templates/items.twig b/templates/items.twig index 6fa9795..4011f6f 100755 --- a/templates/items.twig +++ b/templates/items.twig @@ -45,9 +45,9 @@ {% endif %}