From dfd55d9472fbe9ae64f398043782b4d60775e12b Mon Sep 17 00:00:00 2001 From: alext Date: Sat, 8 Jun 2019 16:55:44 +0200 Subject: [PATCH] Added location field in the appointments API parser. --- src/engine/Api/V1/Parsers/Appointments.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/engine/Api/V1/Parsers/Appointments.php b/src/engine/Api/V1/Parsers/Appointments.php index b8f88039..e072a9ba 100644 --- a/src/engine/Api/V1/Parsers/Appointments.php +++ b/src/engine/Api/V1/Parsers/Appointments.php @@ -32,6 +32,7 @@ class Appointments implements ParsersInterface { 'start' => $response['start_datetime'], 'end' => $response['end_datetime'], 'hash' => $response['hash'], + 'location' => $response['location'], 'notes' => $response['notes'], 'customerId' => $response['id_users_customer'] !== NULL ? (int)$response['id_users_customer'] : NULL, 'providerId' => $response['id_users_provider'] !== NULL ? (int)$response['id_users_provider'] : NULL, @@ -98,6 +99,11 @@ class Appointments implements ParsersInterface { $decodedRequest['hash'] = $request['hash']; } + if ( ! empty($request['location'])) + { + $decodedRequest['location'] = $request['location']; + } + if ( ! empty($request['notes'])) { $decodedRequest['notes'] = $request['notes'];