feat: Add storage hierarchy API and frontend integration

This commit is contained in:
garionion (aider) 2025-02-28 21:18:07 +01:00 committed by garionion
parent 005b04e380
commit 29ec555090
6 changed files with 264 additions and 10 deletions

View file

@ -53,3 +53,16 @@ SELECT * FROM pictures WHERE event_ID = ?;
-- name: AddPicture :exec
INSERT INTO pictures (user_ID, storagespace_ID, object_ID, event_ID, check_in_ID, Path, Description, datetime)
VALUES (?, ?, ?, ?, ?, ?, ?, ?);
-- name: GetAllStorageSpaces :many
SELECT id, parent, location FROM storagespace;
-- name: GetStorageSpaceByID :one
SELECT id, parent, location FROM storagespace WHERE id = ?;
-- name: GetChildStorageSpaces :many
SELECT id, parent, location FROM storagespace WHERE parent = ?;
-- name: GetObjectsByStorageID :many
SELECT id, storagespace_id, name, description, serialnumber, created
FROM objects WHERE storagespace_ID = ?;