Forum Academy Marketplace Showcase Pricing Features

Control of actions

Hi, Bubblers. I want to let the user perform a certain action 10 times a month. Every month he earns 10 more credits to perform the task again. If the credits its over, show a popup notifying user that credits have run out, and that it can migrate to a new subscription

What is the best way to do this on Bubble?

#heeeeeeeeeeeeeelp

Hi!

Create a database called “actions” and save your users there every time they perform an action.

And every time, before allow them to do so, check how many times they appear in the database thru a “Search for”.

@jonathandantaschagas

  • Create a new fields “Credit” / “Last Credit Reset” in the User DB
  • Each time User perform the “actions”, make update to Current User: Credit = This User’s Credit - 1
  • If Current User’s Credit = 0, show pop-up menu (with the custom message)
  • If User is logged in, Credit = 0 and Current Date - Current User’s Last Time Reset" > 1 month → Make update to Current User: Credit = 10