Migrated from Redmine #747 | Author: Sergio Campos Status: New | Priority: High, I’m very impatient | Created: 2021-07-30
Hello to all !
I have a Premium account (Client Ingenes) and I’d like to have a way to import or create in a massive way schedules for my service providers. Let me explain myself:
We currently have a in-house developed booking system, and we have about 10 branches with 10 service providers for branch. Only one person is responsible of creating the schedules for all branches and service providers. He creates all the schedules in a excel file, and then he imports this file to the in-house booking system and all schedules are created in the system. I am attaching a sample of this file. On this file, the sheet that is imported is the one that says LayOut… The other are only references.
We configure the schedules based on roles and later we only assign the Providers to this roles through importing the layout sheet.
We want to do that in Simplybook, and we made a request for this and the developement dept. answered that:
“We can use API for coding a solution for this request”, however we do not know what method or function to use. Can you suggest a solution for this ? We have a cluster with about 12 subcounts and we need to be able to import the schedules for service provider.
/**
* Set work day schedule for company|service|provider for week_day|date
* @param array $info
*
* Example:
*
* {
* "start_time":"10:00",
* "end_time":"18:00",
* "is_day_off":0,
* "breaktime":[{"start_time":"14:00","end_time":"15:00"}],
* "index":"1",
* "name":"Monday",
* "date":"",
* "unit_group_id":"",
* "event_id":""
* }
*
*
* index is 1-7 for Monday - Sunday (used for weekly settings)
* date is used to set worktime for special date
* unit_group_id is provider id
* event_id is service id
* if unit_group_id and event_id not passed then it set data for company
*
* @return boolean true on success
*/
public function setWorkDayInfo($info)
Thanks a Lot ! We started checking this function. I want to confirm as well if for deleting or modifying the WorkDay Info i should use the function: deleteSpecialDay.
I’ve been using the setWorkDayInfo function, and I am trying to set several times on a day, I mean this:
For special date 2021-08-17, I want to enable the following times: 07:00 to 07:10 and 08:00 to 08:10, however I can’t set 2 times, it only allows me to enable one time (the last one). I am using the following code:
start time and end time is longest period of your working day. Non working time must be set using “breaktime”:[{“start_time”:“14:00”,“end_time”:“15:00”}] array
make sure all your time settings are multiple of timeframe. E.g. it is not possible to set 07:40 if timefrane is 30 minutes. For such scenario it must be 10 minutes