Skip to content
Merged
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
19 changes: 13 additions & 6 deletions .github/workflows/build-master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,19 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
extensions: fileinfo
coverage: xdebug
- name: Install PHP from official repositories
run: |
if [[ "${{ matrix.os }}" == "ubuntu-latest" ]]; then
sudo apt-get update
if [[ "${{ matrix.php-version }}" == "7.1" || "${{ matrix.php-version }}" == "7.4" ]]; then
sudo apt-get install -y php php-cli php-common php-curl php-json php-mbstring php-xml php-zip php-fileinfo php-xdebug
else
sudo apt-get install -y php php-cli php-common php-curl php-json php-mbstring php-xml php-zip php-fileinfo
fi
else
# Windows - usar chocolatey con repositorios oficiales
choco install php --version=${{ matrix.php-version }}
fi

- name: Installed version
run: php -v
Expand Down
16 changes: 10 additions & 6 deletions .github/workflows/build-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,16 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
extensions: fileinfo
coverage: xdebug
- name: Install PHP from official repositories
run: |
sudo apt-get update
if [[ "${{ matrix.php-version }}" == "7.1" || "${{ matrix.php-version }}" == "7.4" ]]; then
# For older versions, use system default
sudo apt-get install -y php php-cli php-common php-curl php-json php-mbstring php-xml php-zip php-fileinfo php-xdebug
else
# For newer versions, install available system packages
sudo apt-get install -y php php-cli php-common php-curl php-json php-mbstring php-xml php-zip php-fileinfo
fi

- name: Composer validate
run: composer validate
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,10 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Setup PHP 7.1
uses: shivammathur/setup-php@v2
with:
php-version: "7.1"
coverage: none
- name: Install PHP 7.1 from official repositories
run: |
sudo apt-get update
sudo apt-get install -y php php-cli php-common php-curl php-json php-mbstring php-xml php-zip php-fileinfo

- name: Installed version
run: php -v
Expand Down
18 changes: 18 additions & 0 deletions lib/Checkout/Payments/AccommodationAddress.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

namespace Checkout\Payments;

class AccommodationAddress
{
/**
* The first line of the accommodation address.
* @var string
*/
public $address_line1;

/**
* The postal/ZIP code of the accommodation.
* @var string
*/
public $zip;
}
74 changes: 74 additions & 0 deletions lib/Checkout/Payments/AccommodationData.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
<?php

namespace Checkout\Payments;

use DateTime;

class AccommodationData
{
/**
* The name of the hotel or accommodation.
* @var string
*/
public $name;

/**
* The booking reference number.
* @var string
*/
public $booking_reference;

/**
* The check-in date.
* @var DateTime
*/
public $check_in_date;

/**
* The check-out date.
* @var DateTime
*/
public $check_out_date;

/**
* The accommodation address.
* @var AccommodationAddress
*/
public $address;

/**
* The state or province of the accommodation.
* @var string
*/
public $state;

/**
* The country of the accommodation.
* @var string
*/
public $country;

/**
* The city of the accommodation.
* @var string
*/
public $city;

/**
* The number of rooms booked.
* @var int
*/
public $number_of_rooms;

/**
* The list of guests staying at the accommodation.
* @var array of AccommodationGuest
*/
public $guests;

/**
* The room details and rates.
* @var array of AccommodationRoom
*/
public $room;
}
26 changes: 26 additions & 0 deletions lib/Checkout/Payments/AccommodationGuest.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<?php

namespace Checkout\Payments;

use DateTime;

class AccommodationGuest
{
/**
* The guest's first name.
* @var string
*/
public $first_name;

/**
* The guest's last name.
* @var string
*/
public $last_name;

/**
* The guest's date of birth.
* @var DateTime
*/
public $date_of_birth;
}
18 changes: 18 additions & 0 deletions lib/Checkout/Payments/AccommodationRoom.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

namespace Checkout\Payments;

class AccommodationRoom
{
/**
* The room rate per night.
* @var string
*/
public $rate;

/**
* The number of nights at this room rate.
* @var string
*/
public $number_of_nights_at_room_rate;
}
56 changes: 56 additions & 0 deletions lib/Checkout/Payments/CustomerSummary.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
<?php

namespace Checkout\Payments;

use DateTime;

class CustomerSummary
{
/**
* The date when the customer registered with the platform.
* @var DateTime
*/
public $registration_date;

/**
* The date of the customer's first transaction.
* @var DateTime
*/
public $first_transaction_date;

/**
* The date of the customer's last payment.
* @var DateTime
*/
public $last_payment_date;

/**
* The total number of orders placed by the customer.
* @var int
*/
public $total_order_count;

/**
* The amount of the customer's last payment.
* @var float
*/
public $last_payment_amount;

/**
* Whether the customer is classified as a premium customer.
* @var bool
*/
public $is_premium_customer;

/**
* Whether the customer is a returning customer.
* @var bool
*/
public $is_returning_customer;

/**
* The lifetime value of the customer.
* @var float
*/
public $lifetime_value;
}
19 changes: 17 additions & 2 deletions lib/Checkout/Payments/FlightLegDetails.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,46 +5,61 @@
class FlightLegDetails
{
/**
* @var int
* The flight number.
* @var string
*/
public $flight_number;

/**
* The two-letter airline code.
* @var string
*/
public $carrier_code;

/**
* The service class of the flight.
* @var string
*/
public $service_class;

/**
* The class of travel (e.g., J for Business).
* @var string
*/
public $class_of_travelling;

/**
* The departure date in YYYY-MM-DD format.
* @var string
*/
public $departure_date;

/**
* The departure time in HH:MM format.
* @var string
*/
public $departure_time;

/**
* The three-letter IATA airport code for departure.
* @var string
*/
public $departure_airport;

/**
* The three-letter IATA airport code for arrival.
* @var string
*/
public $arrival_airport;

/**
* The stop over code (e.g., 'x' for connection).
* @var string
*/
public $stopover_code;
public $stop_over_code;

/**
* The fare basis code.
* @var string
*/
public $fare_basis_code;
Expand Down
18 changes: 18 additions & 0 deletions lib/Checkout/Payments/PartnerCustomerRiskData.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

namespace Checkout\Payments;

class PartnerCustomerRiskData
{
/**
* The key identifier for the partner risk data.
* @var string
*/
public $key;

/**
* The value associated with the partner risk data key.
* @var string
*/
public $value;
}
19 changes: 15 additions & 4 deletions lib/Checkout/Payments/Passenger.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,31 @@

namespace Checkout\Payments;

use DateTime;

class Passenger
{
/**
* @var PassengerName
* The passenger's first name.
* @var string
*/
public $name;
public $first_name;

/**
* The passenger's last name.
* @var string
*/
public $last_name;

/**
* The passenger's date of birth.
* @var DateTime
*/
public $date_of_birth;

/**
* @var string values of Country
* The passenger's address information.
* @var PassengerAddress
*/
public $country_code;
public $address;
}
12 changes: 12 additions & 0 deletions lib/Checkout/Payments/PassengerAddress.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?php

namespace Checkout\Payments;

class PassengerAddress
{
/**
* The two-letter ISO country code of the passenger's address.
* @var string value of Country
*/
public $country;
}
Loading