room reservation model, controller, seeder and migration files added

This commit is contained in:
Kiss Dávid
2026-08-19 19:59:18 +02:00
parent b281724a1a
commit 0b88fe87e5
49 changed files with 4073 additions and 2472 deletions
+12 -2
View File
@@ -289,21 +289,31 @@ Deletes a category.
## Images
### List Images
Retrieves a list of all uploaded images.
- **URL:** `/api/images`
- **Method:** `GET`
- **Authentication:** Required (Admin)
- **Response:** `[{"filename": "...", "url": "...", "thumbnailUrl": "..."}]`
### Upload Image
Uploads an image for menu items or categories. Supported extensions: jpg, jpeg, png, webp, gif. Max size: 10mb.
Uploads an image for menu items or categories. Supported extensions: jpg, jpeg, png, webp, gif. Max size: 10mb. Automatically generates a 200px wide thumbnail.
- **URL:** `/api/images/upload`
- **Method:** `POST`
- **Authentication:** Required (Admin)
- **Body:**
- `image` (file, required): The image file to upload.
- **Response:** `{"filename": "...", "url": "..."}`
- **Response:** `{"filename": "...", "url": "...", "thumbnailUrl": "..."}`
### Show Image
Retrieves and displays a previously uploaded image.
- **URL:** `/api/images/:filename`
- **Method:** `GET`
- **Query Parameters:**
- `type` (string, optional): Use `thumbnail` to retrieve the 200px wide thumbnail.
- **Response:** Image stream with correct MIME type.
---