This is a long delay, but after many trials and many headaches, we decided to create a specific scheme for this work. For the needs of our system, we only need to repeat weekly, if at all possible. The final product will be developed as such.
Here is the DB schema
id : int(10) window_name : varchar(100) start_date : datetime end_date : datetime start_time : time duration : int(10) timezone: varchar(100) monday : tinyint(1) tuesday : tinyint(1) ... sunday : tinyint(1)
- Each time window will have a specified start date, end date, start time, and duration.
- A window will open at the start date and start time and the βdurationβ of seconds will start
- The window will be open only on certain days of the week.
This is the only system that will allow windows to open and close on a periodic weekly basis, as well as have windows that will be distributed the next morning. I am sure that there are more complex systems that make repeating windows, but we were looking for something flexible and fast, and did not need monthly repeating events or annual events.
source share