# How do I make automatic time allocation?

**URL:** <https://community.glideapps.com/t/how-do-i-make-automatic-time-allocation/77928>\
**Category:** Ask for Help\
**Created:** [November 15, 2024, 9:27am UTC](https://community.glideapps.com/t/how-do-i-make-automatic-time-allocation/77928 "2024-11-15T09:27:07Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![voronsoff49](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/voronsoff49/32/78875_2.png) [@voronsoff49](https://community.glideapps.com/u/voronsoff49)\
**Post date:** [November 15, 2024, 9:27am UTC](https://community.glideapps.com/t/how-do-i-make-automatic-time-allocation/77928/1 "2024-11-15T09:27:07Z")

</div>

We have a customer base and a doctor base. There is a start and end time for admission. But I can’t figure out how to make automatic time allocation? I need to make a dynamic time list from one date to another in an interval of 16 minutes, for example. And we also need to make an automatic distribution on free dates. 1 date - 4 people can be booked. At the same time, time should be distributed according to our dynamic (preferably) interval, who went beyond the time frame - the next day, etc. Can this be implemented? Is there any example?

---

<div class="post-metadata">

**Author:** ![MaximeBaker](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/maximebaker/32/80877_2.png) [@MaximeBaker](https://community.glideapps.com/u/MaximeBaker)\
**Post date:** [November 16, 2024, 12:28am UTC](https://community.glideapps.com/t/how-do-i-make-automatic-time-allocation/77928/2 "2024-11-16T00:28:18Z")

</div>

> [@voronsoff49](#):
>
> I need to make a dynamic time list from one date to another in an interval of 16 minutes, for example.

By that you mean something infinite like:  
[0:00,0:16,0:32,0:48,1:04]?

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [November 16, 2024, 12:28am UTC](https://community.glideapps.com/t/how-do-i-make-automatic-time-allocation/77928/3 "2024-11-16T00:28:35Z")

</div>

So everytime someone fills out a form, you have to assign them to the right doctor based on the rules above?

Should it look something like this?

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/2/f/2fe3f1e3138d6294f3b4a80cc682255d6f97426c.png)

---

<div class="post-metadata">

**Author:** ![voronsoff49](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/voronsoff49/32/78875_2.png) [@voronsoff49](https://community.glideapps.com/u/voronsoff49)\
**Post date:** [November 16, 2024, 5:32am UTC](https://community.glideapps.com/t/how-do-i-make-automatic-time-allocation/77928/4 "2024-11-16T05:32:58Z")

</div>

Yes, something like that

---

<div class="post-metadata">

**Author:** ![voronsoff49](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/voronsoff49/32/78875_2.png) [@voronsoff49](https://community.glideapps.com/u/voronsoff49)\
**Post date:** [November 16, 2024, 5:35am UTC](https://community.glideapps.com/t/how-do-i-make-automatic-time-allocation/77928/5 "2024-11-16T05:35:43Z")

</div>

The doctor will have his own time interval for which he will receive patients. For example, from 12:00 to 15:00. I would like to somehow break this time into intervals of 12:16, 12:32, etc. Because it is not very good to fill in all time intervals manually for the doctor

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [November 17, 2024, 1:02am UTC](https://community.glideapps.com/t/how-do-i-make-automatic-time-allocation/77928/6 "2024-11-17T01:02:31Z")

</div>

I don’t have an immediate good way to do that. What I think you can do might look like this:

- Set the doctor’s ID to a field in User Profiles when a customer clicks on a doctor to view his details.
- Use a relation + lookup to retrieve the start and end admission times for that doctor.
- Use JavaScript to generate a comma delimited list of start and end internals for that doctor, based on the lookup above.
- Use this method to transpose them to a helper table and use that in a choice component.

> [@fishbaguette\_breadbasket Transpose Columns to an Inline List: The Miracle Method](https://community.glideapps.com/t/transpose-columns-to-an-inline-list-the-miracle-method/32766):
>
> I’m often asked how to take columns of data (say form responses) and display them in an inline list. Here’s one way to do it—the MIRACLE METHOD. [[Glide: Transpose Data Columns into an Inline List with the MIRACLE METHOD] ](https://www.youtube.com/watch?v=t-sh_Q3WbQc)
