I’m building booking app. I need to get following calculation to get availability of items:
for each day in a date range calculate amount of items booked and return maximum amount.
Is it possible to do something like that in bubble? What plugins I might need? I need to run this calculation for both front end (show availability) and backend (check availability).
For the specific question about calculating how many Bookings there are, this could be done using a simple Search of the Database for ‘Bookings’ (or whatever the name is of the data you are saving a Booked Time as in your app) and then returning the Count.
However it sounds like this might be very early in your project, so I will give some general advice around building a Booking app in Bubble.
There are ways you can build this natively in Bubble (no plugins or custom javascript), but if you need it to work across time zones then it get’s tricky or not dependable without a Plugin or a little Javascript code to make it work.
If you search there forums there are a few solutions, but I would recommend my TopCal Plugin to help build this.
You can visit this page for videos and details on how to use the Plugin and create this type of app. Most of the Database structure and logic can be used whether you end up using the Plugin or not