Forum Academy Marketplace Showcase Pricing Features

Scheduling Jobs using a List of Date Ranges

Please help!

The below seems to be easy but I cant make it work.

I am trying to build a service app for my company. I have a recursive backend workflow that creates generates a date type called “day” each day 30 days out (I wanted to limit bookable days to 30 days out). This data type “day” has a field called “availability” that is a list of date ranges. When the “day” is generated there is only one date range -which is the whole service day’s availability. My plan is to have these date ranges manipulated by scheduled jobs thus changing/limiting availability.

When a client wants to book a service. I want to have a RG search “Days” and then filter “Day” by “availability” contains the estimated duration of the service (filter because you can’t use a list of Date Ranges as a constraint during a search) . Once the “day” is selected date ranges that are large enough to contain the job’s estimated duration would be shown. Then when the job is booked the date range is manipulated to close availability.

I guess I have these questions:

  1. Is it possible to manipulate a date range (split, shorten, or other).
  2. Can a date range only contain another date range or date?
  3. Is it possible to filter a data type (in this case “day”) by using a constraint that is a date range (“availability”) that “contains” an estimated duration.
  4. What data type should the estimated duration be to make this work if possible? (date range, date interval, numeric range, or other). I assumed date interval would be the one but I cant get it to work.

This topic was automatically closed after 70 days. New replies are no longer allowed.