Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hotel #448

Open
wants to merge 16 commits into
base: master
Choose a base branch
from
Open

Hotel #448

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Release 1.4.0 (UNRELEASED)
* Added support for Seat Request elements in in ``PNR_AddMultiElements`` (https://github.com/amabnl/amadeus-ws-client/issues/64/)
* Implemented ``DocRefund_InitRefund`` (https://github.com/amabnl/amadeus-ws-client/issues/56)
* Implemented ``Hotel_MultiSingleAvailability``
* Implemented ``Hotel_Sell``

# Release 1.3.0 (5 April 2017)
* Added support for Multiple Office ID's in ``Fare_MasterPricerTravelBoardSearch`` (https://github.com/amabnl/amadeus-ws-client/pull/44) - Michal Hernas
Expand Down Expand Up @@ -45,6 +47,7 @@
* Implemented ``PNR_NameChange`` message
* Implemented ``FOP_CreateFormOfPayment`` message
* Implemented ``PointOfRef_Search`` message
* Implemented ``Hotel_Sell`` message
* Request Creator split up in 1 dedicated class per message.
* Response Handler split up in 1 dedicated class per message.

Expand Down
39 changes: 19 additions & 20 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions docs/list-of-supported-messages.rst
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ This is the list of messages that are at least partially supported at this time:
- DocIssuance_IssueCombined
- DocRefund_InitRefund
- Service_IntegratedPricing
- Hotel_MultiSingleAvailability
- Hotel_Sell
- Offer_CreateOffer
- Offer_VerifyOffer
- Offer_ConfirmAirOffer
Expand Down Expand Up @@ -87,10 +89,8 @@ These messages will be implemented at some point in the future. *Pull requests a
- Service_IntegratedCatalogue
- Service_PriceServiceViaCatalogue
- Service_PriceIntegratedMode
- Hotel_MultiSingleAvailability
- Hotel_DescriptiveInfo
- Hotel_EnhancedPricing
- Hotel_Sell
- Hotel_CompleteReservationDetails
- Hotel_Terms
- Car_Availability
Expand Down
8 changes: 8 additions & 0 deletions docs/samples.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2046,6 +2046,14 @@ Assign an account code to a passenger:
])
);

*****
Hotel
*****
----------
Hotel_Sell
----------

*coming soon*

***
FOP
Expand Down
30 changes: 30 additions & 0 deletions src/Amadeus/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -997,6 +997,36 @@ public function fopCreateFormOfPayment(RequestOptions\FopCreateFopOptions $optio
return $this->callMessage($msgName, $options, $messageOptions);
}

/**
* Hotel_MultiSingleAvailability
*
* @param RequestOptions\HotelMultiSingleAvailOptions $options
* @param array $messageOptions (OPTIONAL)
* @return Result
*/
public function hotelMultiSingleAvailability(
RequestOptions\HotelMultiSingleAvailOptions $options,
$messageOptions = []
) {
$msgName = 'Hotel_MultiSingleAvailability';

return $this->callMessage($msgName, $options, $messageOptions);
}

/**
* Hotel_Sell
*
* @param RequestOptions\HotelSellOptions $options
* @param array $messageOptions (OPTIONAL)
* @return Result
*/
public function hotelSell(RequestOptions\HotelSellOptions $options, $messageOptions = [])
{
$msgName = 'Hotel_Sell';

return $this->callMessage($msgName, $options, $messageOptions);
}

/**
* PriceXplorer_ExtremeSearch
*
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?php
/**
* amadeus-ws-client
*
* Copyright 2015 Amadeus Benelux NV
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* @package Amadeus
* @license https://opensource.org/licenses/Apache-2.0 Apache 2.0
*/

namespace Amadeus\Client\RequestCreator\Converter\Hotel;

use Amadeus\Client\RequestCreator\Converter\BaseConverter;
use Amadeus\Client\RequestOptions\HotelMultiSingleAvailOptions;
use Amadeus\Client\Struct;

/**
* Hotel_MultiSingleAvailability request converter
*
* @package Amadeus\Client\RequestCreator\Converter\Hotel
* @author Dieter Devlieghere <[email protected]>
*/
class MultiSingleAvailabilityConv extends BaseConverter
{
/**
* @param HotelMultiSingleAvailOptions $requestOptions
* @param int|string $version
* @return Struct\Hotel\MultiSingleAvailability
*/
public function convert($requestOptions, $version)
{
return new Struct\Hotel\MultiSingleAvailability($requestOptions);
}
}
46 changes: 46 additions & 0 deletions src/Amadeus/Client/RequestCreator/Converter/Hotel/SellConv.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?php
/**
* amadeus-ws-client
*
* Copyright 2015 Amadeus Benelux NV
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* @package Amadeus
* @license https://opensource.org/licenses/Apache-2.0 Apache 2.0
*/

namespace Amadeus\Client\RequestCreator\Converter\Hotel;

use Amadeus\Client\RequestCreator\Converter\BaseConverter;
use Amadeus\Client\RequestOptions\HotelSellOptions;
use Amadeus\Client\Struct;

/**
* Hotel_Sell Request converter
*
* @package Amadeus\Client\RequestCreator\Converter\Hotel
* @author Dieter Devlieghere <[email protected]>
*/
class SellConv extends BaseConverter
{
/**
* @param HotelSellOptions $requestOptions
* @param int|string $version
* @return Struct\Hotel\Sell
*/
public function convert($requestOptions, $version)
{
return new Struct\Hotel\Sell($requestOptions);
}
}
Loading