Help creating the right actions to upload multiple photos for a user

Troubleshooting

Hi all,

I've been experimenting with FlutterFlow and really enjoy the tool so far. I am a novice.The task is for an authenticated user (using Firebase) can upload 1 or more photos from their gallery into Firebase for further cloud functions to be carried out.

I've managed to get the user to select their images into local state (widget), have an image preview in a list so user can scroll these to ensure they're happy with what they selected. I'm now stuck on the upload stage. The user will press another button which effectively takes those selected images and uploads them to Firebase Storage as well as I have in the Firestore Databse the user document where the image URLs are required to store the path so I can run some AI functions against them.

I am confused around how I should be managing AppStates, Schemas and the Actions etc.

Q1. What is the best flow for uploading the image(s) to Firestore? Is it 1. Upload 2. Update/Create document? Do I need to update the AppState at all? Unsure about that

Q2. Am I updating or creating a document? How do I manage the Firebase URLs for the imagepaths so they can be added to some document for each user?

Any help would be appreciated. I'm a bit lost!

Firestore:

What have you tried so far?

I've watched numerous Youtube videos, but they don't include updating or creating documents. Maybe I don't need to do this? But in my mind its required because I must retrieve some of the data from the user later in the next page.

Did you check FlutterFlow's Documentation for this topic?
Yes
2
1 reply