-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Migrate to ecomm api. * Switcher from ecomm api to epayment. * Update labels for mobile ecomm, allow NOK, EUR currencies. * Extend graphql for pwa mobilepay. * Add license. * Update mobilepay logo. * Update unit tests. * Update phpcs config. * Always capture when mobilepay is selected. * Update links and notes at configuration. * Unlock authorize and capture for mobilepay. * Fix implicit convert to int. --------- Co-authored-by: Oleg Malichenko <[email protected]>
- Loading branch information
1 parent
9be9e1a
commit 0a59dcb
Showing
122 changed files
with
7,975 additions
and
387 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<?php declare(strict_types=1); | ||
|
||
/** | ||
* Copyright 2023 Vipps | ||
* | ||
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated | ||
* documentation files (the "Software"), to deal in the Software without restriction, including without limitation | ||
* the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, | ||
* and to permit persons to whom the Software is furnished to do so, subject to the following conditions: | ||
* | ||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED | ||
* TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON INFRINGEMENT. IN NO EVENT SHALL | ||
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF | ||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS | ||
* IN THE SOFTWARE. | ||
*/ | ||
namespace Vipps\Payment\Api\Fallback; | ||
|
||
use Magento\Framework\App\RequestInterface; | ||
use Vipps\Payment\Api\Data\QuoteInterface; | ||
|
||
interface AuthoriseInterface | ||
{ | ||
public function do(RequestInterface $request, QuoteInterface $vippsQuote): void; | ||
|
||
public function getOrderId(RequestInterface $request): string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
<?php declare(strict_types=1); | ||
|
||
/** | ||
* Copyright 2023 Vipps | ||
* | ||
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated | ||
* documentation files (the "Software"), to deal in the Software without restriction, including without limitation | ||
* the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, | ||
* and to permit persons to whom the Software is furnished to do so, subject to the following conditions: | ||
* | ||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED | ||
* TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON INFRINGEMENT. IN NO EVENT SHALL | ||
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF | ||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS | ||
* IN THE SOFTWARE. | ||
*/ | ||
|
||
namespace Vipps\Payment\Api\Payment; | ||
|
||
use Magento\Payment\Gateway\Command\ResultInterface; | ||
use Magento\Payment\Model\InfoInterface; | ||
use Magento\Sales\Api\Data\OrderInterface; | ||
use Vipps\Payment\Gateway\Exception\VippsException; | ||
|
||
/** | ||
* Interface PaymentCommandManagerInterface | ||
* @package Vipps\Payment\Api | ||
* @api | ||
*/ | ||
interface CommandManagerInterface | ||
{ | ||
/** | ||
* @param string $reference | ||
* @param array $arguments | ||
* | ||
* @return mixed | ||
*/ | ||
public function getPayment($reference, $arguments = []); | ||
|
||
/** | ||
* @param string $orderId | ||
* @param array $arguments | ||
* | ||
* @return mixed | ||
*/ | ||
public function getPaymentEventLog($orderId, $arguments = []); | ||
|
||
/** | ||
* Send Receipt. | ||
* | ||
* @param array $arguments | ||
* | ||
* @return mixed | ||
* @throws VippsException | ||
*/ | ||
public function sendReceipt(OrderInterface $order, $arguments = []); | ||
|
||
/** | ||
* Method to execute cancel Command. | ||
* | ||
* @param InfoInterface $payment | ||
* @param array $arguments | ||
* | ||
* @return mixed | ||
*/ | ||
public function cancel(InfoInterface $payment, $arguments = []); | ||
|
||
/** | ||
* Initiate payment action. | ||
* | ||
* @param InfoInterface $payment | ||
* @param array $arguments | ||
* | ||
* @return ResultInterface|null | ||
*/ | ||
public function initiatePayment(InfoInterface $payment, $arguments); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Vipps\Payment\Api\Transaction; | ||
|
||
interface PaymentDetailsInterface | ||
{ | ||
public function get(string $orderId); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.