Conditional visibility for text based on Count of Documents Not Working

Widgets & Design

Hi Everyone,

I am trying to set a text widget's visibility conditional based on whether or not a User has any tasks currently assigned to them.

However the text is always showing no matter what I try.

This is my current solution design (if you would please critique it):

  • Set a QueryCollection on the Text widget to the usersTasks collection, filtered uid == [User ID]

  • Set Visibility - Conditional TRUE

  • Set the Condition variable to:

    • Single Condition

    • First value "usersTasksCount"

    • Equal to

    • Value = 0

When I test it, this query is returning "6" so the text should not be showing, however it is still showing.

Any help is appreciated! I have tried lots of different ways and am at a loss. Thank you!

What have you tried so far?

I've tried greater than, I've tried notEqualTo.

I've tried querying the documents and returning the list, selecting the Number of items and then doing an equal to 0 statement.

Did you check FlutterFlow's Documentation for this topic?
Yes
4
6 replies