system
1
Migrated from Redmine #143 | Author: Anonymous
Status: Resolved | Priority: High, I’m very impatient | Created: 2018-04-04
Hi there,
I’m stuck. I need help implementing a calendar based on the following queries.
Here’s my snippet.
$year = 2018;
$month = 4; // April
$performerId = 3; // Can be null
$firstWorkingDay = $client->getFirstWorkingDay($performerId);
//echo $firstWorkingDay;
$workDays = $client->getWorkCalendar($year, $month, $performerId);
//print_r($workDays);
if($workDays){
$days = array();
foreach ($workDays as $workDay){
$days[] = $workDay;
}
//echo json_encode($days);
}
else{
echo 'No workday found';
}
$dateFrom = '2018-04-01';
$dateTo = '2018-12-31';
$serviceId = 3;
$performerId = 3;
$qty = 1;
$availableTime = $client->getStartTimeMatrix($dateFrom,$dateTo,$serviceId,$performerId);
// print_r($availableTime);
Regards,
Tebogo
system
2
Anonymous wrote:
Tebogo Moopelwa wrote:
Hi there,
I’m stuck. I need help implementing a calendar based on the following queries.
Here’s my snippet.
$year = 2018;
$month = 4; // April
$performerId = 3; // Can be null
$firstWorkingDay = $client->getFirstWorkingDay($performerId);
//echo $firstWorkingDay;
$workDays = $client->getWorkCalendar($year, $month, $performerId);
//print_r($workDays);
if($workDays){
$days = array();
foreach ($workDays as $workDay){
$days[] = $workDay;
}
//echo json_encode($days);
}
else{
echo 'No workday found';
}
$dateFrom = '2018-04-01';
$dateTo = '2018-12-31';
$serviceId = 3;
$performerId = 3;
$qty = 1;
$availableTime = $client->getStartTimeMatrix($dateFrom,$dateTo,$serviceId,$performerId);
// print_r($availableTime);
Regards,
Tebogo
Basically I’m looking to implement bootstrap date picker along with available time slots. The
system
3
Dmytro Bondarev wrote:
Please checkout the API Explorer.
system
4
Anonymous wrote:
I have looked at the api explorer and the example is in Javascript and not PHP.
Nevertheless, I will bash my way through it.