Back

Right pattern to link Document and Storage

  • 0
  • Databases
  • Storage
ash10
9 Oct, 2023, 20:11

Hello, This is a thread to discuss options on how to properly have the equivalent of a « File » field in a document linking it to the storage. What do you suggest? Simplicity, genericity, security, etc. Thank you

TL;DR
The user is asking for suggestions on how to link a document to a storage file in a way that maintains consistency with permissions. They mention using an attribute to store the file id or making the file id match the document id. They are looking for suggestions that prioritize simplicity, genericity, and security.
Drake
9 Oct, 2023, 20:15

i have an attribute where i put the file id. either that or i make the file id match the document id

ash10
9 Oct, 2023, 20:19

Thank you. How would you maintain consistency on permissions with this? Like make sure that the ones on the document applies to the file?

Drake
9 Oct, 2023, 20:20

pass the same permissions when making them

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more