How can I restrict non-subscribed users to creating only 6 posts in FlutterFlow?

Actions & Logic

I'm creating a to-do list app with FlutterFlow,

and I want to allow paid subscribers to create unlimited posts while restricting non-subscribed users to creating only 6 posts.

I've connected the app to Firebase for data storage.

The app has a to-do list page with a ListView, and when the "Add" button is pressed, a bottom sheet appears for creating a new post.

The bottom sheet contains a text field and a "Create" button.

When the "Create" button is pressed, a new entry is added to Firebase. I want to ensure that if the user is not a subscriber, they can only create up to 6 posts. How can I achieve this?

What have you tried so far?

GPT suggests limiting the ListView item count, but I don’t understand how to access that item count in a condition inside the bottom sheet component.

Did you check FlutterFlow's Documentation for this topic?
Yes
1
5 replies