0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-03-22 08:58:11 +00:00

Updated Folders etc (markdown)

ericscheid
2023-12-04 15:47:50 +11:00
parent c5b3264c6c
commit 500d6646df

@@ -45,19 +45,19 @@ Each folder is owned by one owner, and it only appears in the context of _their_
Multiple brews can be assigned to a folder by listing the `brew.shareID` in the folder entity. (This is distinct and different from a model where the association is achieved via an attribute on the brew entity).
Sub-folders are linked via a list of sub-folderIds, in the same manner as to how brews are linked.
Sub-folders are linked via a list of subfolderIds, in the same manner as how brews are linked.
### Minimal Data structure
- `__Id` (mongo specific ID field, exists wether we create it or not)
- `folderId` (nanoid, required, auto)
- `folderName` (to use in the URL) (string, required)
- `owner` (can be multiple?)
- `brewIds`(shareId)
- `createdAt`
- `UpdatedAt`
- `slug` (to use in the URL) (string, required)
- `owner`
- `brewIds` (list of shareId)
- `createdAt` (auto)
- `UpdatedAt` (auto)
#### More substantial data structure
![image](https://github.com/naturalcrit/homebrewery/assets/2605467/90fa8be0-6728-46f9-a1e1-2d09975e292f)
![ERD of folders, users, and brews](https://github.com/naturalcrit/homebrewery/assets/2605467/03b4a90b-3c7f-4923-91db-dc77264473fd)