Skip to content

Commit

Permalink
Add card_token field to NotificationBody
Browse files Browse the repository at this point in the history
  • Loading branch information
piotrjozwiak committed Sep 4, 2019
1 parent 9a0668a commit ed826e3
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Model/Fields/Notification/CardToken.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?php
namespace tpaySDK\Model\Fields\Notification;

use tpaySDK\Model\Fields\Field;

class CardToken extends Field
{
protected $name = 'card_token';

protected $type = self::STRING;

}
7 changes: 7 additions & 0 deletions Model/Objects/NotificationBody/BasicPayment.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<?php
namespace tpaySDK\Model\Objects\NotificationBody;

use tpaySDK\Model\Fields\Notification\CardToken;
use tpaySDK\Model\Fields\Notification\Crc;
use tpaySDK\Model\Fields\Notification\Description;
use tpaySDK\Model\Fields\Notification\Error;
Expand Down Expand Up @@ -37,6 +38,7 @@ class BasicPayment extends Objects
'test_mode' => TestMode::class,
'wallet' => Wallet::class,
'tr_channel' => TransactionChannel::class,
'card_token' => CardToken::class,
];

/**
Expand Down Expand Up @@ -109,6 +111,11 @@ class BasicPayment extends Objects
*/
public $tr_channel;

/**
* @var CardToken
*/
public $card_token;

public function getRequiredFields()
{
return [
Expand Down

0 comments on commit ed826e3

Please sign in to comment.