Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejs
titleGET /workingHours period object:
linenumberstrue
collapsetrue
[{
    "endDate": "2018-12-31",
    "endDateDate": 1546214400000,
    "firstWeek": false,
    "fourthWeek": false,
    "fri": false,
    "lastWeek": false,
    "mon": false,
    "objects": [{
        "days": [{
            "checked": false,
            "times": [{
                "active": true,
                "endTime": 1700,
                "endTimeObj": "2018-08-20 17:00:00",
                "roomNumber": null,
                "startTime": 1600,
                "startTimeObj": "2018-08-20 16:00:00",
                "workScheduleId": 1420758
            }],
            "workday": 1
        }],
        "locationId": 81353,
        "locationName": "Downtown Office",
        "objecttype": "PROFESSIONAL",
        "professionalId": 80891,
        "professionalName": "Mr. Biscuits",
        "reasonId": null,
        "reasonName": null,
        "resourceId": null,
        "resourceName": null
    }],
    "recurring": false,
    "repeatInterval": null,
    "repeatSchedule": null,
    "sat": false,
    "secondWeek": false,
    "startDate": "2018-08-20",
    "startDateDate": 1534723200000,
    "sun": false,
    "thirdWeek": false,
    "thu": false,
    "tue": false,
    "wed": false
},
{
    "endDate": "2019-05-17",
    "endDateDate": 1546300800000,
    "firstWeek": false,
    "fourthWeek": false,
    "fri": false,
    "lastWeek": false,
    "mon": false,
    "objects": [{
        "days": [{
            "checked": false,
            "times": [{
                "active": true,
                "endTime": 1700,
                "endTimeObj": "2018-08-20 17:00:00",
                "roomNumber": null,
                "startTime": 1600,
                "startTimeObj": "2018-08-20 16:00:00",
                "workScheduleId": 1420762
            }],
            "workday": 1
        }],
        "locationId": 81353,
        "locationName": "Downtown Office",
        "objecttype": "PROFESSIONAL",
        "professionalId": 80891,
        "professionalName": "Mr. Biscuits",
        "reasonId": null,
        "reasonName": null,
        "resourceId": null,
        "resourceName": null
    }],
    "recurring": false,
    "repeatInterval": null,
    "repeatSchedule": null,
    "sat": false,
    "secondWeek": false,
    "startDate": "2019-01-01",
    "startDateDate": 1546300800000,
    "sun": false,
    "thirdWeek": false,
    "thu": false,
    "tue": false,
    "wed": false
}]

...

Say your employee Master J has service availability at your beach office from 10 am until noon on Thursday, June 14. You want to add your employee Dr. J to the service availability, but you want to make him available in the evenings evening for those customers who cannot make it to the morning session. Here is what you would do:

...

Code Block
languagejs
titleGET /workingHours period object:
linenumberstrue
collapsetrue
[{
    "endDate": "2018-06-14",
    "endDateDate": 1528934400000,
    "firstWeek": false,
    "fourthWeek": false,
    "fri": false,
    "lastWeek": false,
    "mon": false,
    "objects": [{
        "days": [{
            "checked": false,
            "times": [{
                "active": true,
                "endTime": 1200,
                "endTimeObj": "2018-06-14 12:00:00",
                "roomNumber": null,
                "startTime": 1000,
                "startTimeObj": "2018-06-14 10:00:00",
                "workScheduleId": 1389497
            }],
            "workday": 4
        }],
        "locationId": 81129,
        "locationName": "Beach Office",
        "objecttype": "PROFESSIONAL",
        "professionalId": 82275,
        "professionalName": "Master J",
        "reasonId": null,
        "reasonName": null,
        "resourceId": null,
        "resourceName": null
    }],
    "recurring": false,
    "repeatInterval": null,
    "repeatSchedule": null,
    "sat": false,
    "secondWeek": false,
    "startDate": "2018-06-14",
    "startDateDate": 1528934400000,
    "sun": false,
    "thirdWeek": false,
    "thu": false,
    "tue": false,
    "wed": false
}]

...