[ ] Users shall be able to delete their images once logged in.
Satisfied by: Testing if a user can delete their images on the server. Server and Database shall handle valid delete requests gracefully and delete a user's images on the server. Server and Database shall handle invalid delete requests gracefully.
SQL:
CREATE TABLE IF NOT EXISTS uuids.uuid (
uuid UUID PRIMARY KEY,
parentTable VARCHAR(64) -- The table that contains the actual asset of the UUID
);
CREATE TABLE IF NOT EXISTS accounts.user (
uuid UUID PRIMARY KEY REFERENCES uuids.uuid(uuid),
username VARCHAR(16) UNIQUE, -- No repeated usernames allowed
password VARCHAR(256) -- SHA256
);
-- It is recommended images be stored on local file disk versus database
-- We will store metadata here, like the path on the local file system
CREATE TABLE IF NOT EXISTS images.image (
uuid UUID PRIMARY KEY REFERENCES uuids.uuid(uuid),
filePath VARCHAR(255), -- Maximum directory length in the ext4 file system, common in Ubuntu
userUUID UUID REFERENCES accounts.user(uuid) -- Foreign key referencing user UUID
);
user
'simage
s on the server. Server and Database shall handle invalid delete requests gracefully.SQL: