Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

Commit

Permalink
feat(Payment): add change amount planned update action
Browse files Browse the repository at this point in the history
  • Loading branch information
Jens Schulze committed Mar 8, 2016
1 parent 0c6f36d commit 2815f98
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions src/Request/Payments/Command/PaymentChangeAmountPlannedAction.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<?php
/**
* @author @jayS-de <jens.schulze@commercetools.de>
*/

namespace Commercetools\Core\Request\Payments\Command;

use Commercetools\Core\Model\Common\Context;
use Commercetools\Core\Request\AbstractAction;
use Commercetools\Core\Model\Common\Money;

/**
* @package Commercetools\Core\Request\Payments\Command
* @link http://dev.commercetools.com/http-api-projects-payments.html#change-amount-planned
* @method string getAction()
* @method PaymentChangeAmountPlannedAction setAction(string $action = null)
* @method Money getAmount()
* @method PaymentChangeAmountPlannedAction setAmount(Money $amount = null)
*/
class PaymentChangeAmountPlannedAction extends AbstractAction
{
public function fieldDefinitions()
{
return [
'action' => [static::TYPE => 'string'],
'amount' => [static::TYPE => '\Commercetools\Core\Model\Common\Money'],
];
}

/**
* @param array $data
* @param Context|callable $context
*/
public function __construct(array $data = [], $context = null)
{
parent::__construct($data, $context);
$this->setAction('changeAmountPlanned');
}
}

0 comments on commit 2815f98

Please # to comment.