Depends how your data is set up.
I would set it up this way:
- A users table
- A table with a master list of todo items
- A table that assigns todo items to a bucket for each user
The button should add a row to the third table. It should write the todo item, the email of the signed in user, and the bucket number. In this same table, create two if then else columns
- “If Bucket A”: If bucket is A then 1 else 0
- “If Bucket B”: If bucket is B then 1 else 0
In the users table, create a multiple relation to table 3 via email address. Then do a Rollup (sum) of the “If Bucket A” column. Create a second Rollup (sum) of the “If Bucket B” column.
You now have two columns that count how many task items belong in each bucket for each user. Use these as visibility conditions for showing/hiding the button.