Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
Adyen Magento2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Shared Libs
Adyen Magento2
Commits
04a2db14
Commit
04a2db14
authored
Oct 09, 2020
by
Marcos Garcia
Committed by
GitHub
Oct 09, 2020
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #847 from Adyen/develop
Release 6.6.1
parents
45278ee7
329eb7a3
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
168 additions
and
16 deletions
+168
-16
Model/AdyenThreeDS2Process.php
Model/AdyenThreeDS2Process.php
+3
-1
Plugin/GuestPaymentInformationResetOrderId.php
Plugin/GuestPaymentInformationResetOrderId.php
+81
-0
Plugin/PaymentInformationResetOrderId.php
Plugin/PaymentInformationResetOrderId.php
+70
-0
composer.json
composer.json
+1
-1
etc/config.xml
etc/config.xml
+0
-12
etc/di.xml
etc/di.xml
+8
-0
view/frontend/web/js/view/payment/method-renderer/adyen-google-pay-method.js
...s/view/payment/method-renderer/adyen-google-pay-method.js
+4
-1
view/frontend/web/template/payment/google-pay-form.html
view/frontend/web/template/payment/google-pay-form.html
+1
-1
No files found.
Model/AdyenThreeDS2Process.php
View file @
04a2db14
...
...
@@ -173,7 +173,9 @@ class AdyenThreeDS2Process implements AdyenThreeDS2ProcessInterface
// Save the payments response because we are going to need it during the place order flow
$payment
->
setAdditionalInformation
(
"paymentsResponse"
,
$result
);
$this
->
vaultHelper
->
saveRecurringDetails
(
$payment
,
$result
[
'additionalData'
]);
if
(
!
empty
(
$result
[
'additionalData'
]))
{
$this
->
vaultHelper
->
saveRecurringDetails
(
$payment
,
$result
[
'additionalData'
]);
}
// To actually save the additional info changes into the quote
$order
->
save
();
...
...
Plugin/GuestPaymentInformationResetOrderId.php
0 → 100644
View file @
04a2db14
<?php
/**
* ######
* ######
* ############ ####( ###### #####. ###### ############ ############
* ############# #####( ###### #####. ###### ############# #############
* ###### #####( ###### #####. ###### ##### ###### ##### ######
* ###### ###### #####( ###### #####. ###### ##### ##### ##### ######
* ###### ###### #####( ###### #####. ###### ##### ##### ######
* ############# ############# ############# ############# ##### ######
* ############ ############ ############# ############ ##### ######
* ######
* #############
* ############
*
* Adyen Payment module (https://www.adyen.com/)
*
* Copyright (c) 2019 Adyen BV (https://www.adyen.com/)
* See LICENSE.txt for license details.
*
* Author: Adyen <magento@adyen.com>
*/
namespace
Adyen\Payment\Plugin
;
use
Magento\Quote\Api\CartRepositoryInterface
;
class
GuestPaymentInformationResetOrderId
{
/**
* Quote repository.
*
* @var \Magento\Quote\Api\CartRepositoryInterface
*/
protected
$quoteRepository
;
/**
* @var \Adyen\Payment\Logger\AdyenLogger
*/
protected
$adyenLogger
;
/**
* @var \Magento\Quote\Model\QuoteIdMaskFactory
*/
protected
$quoteIdMaskFactory
;
/**
* GuestPaymentInformationResetOrderId constructor.
* @param CartRepositoryInterface $quoteRepository
* @param \Adyen\Payment\Logger\AdyenLogger $adyenLogger
* @param \Magento\Quote\Model\QuoteIdMaskFactory $quoteIdMaskFactory
*/
public
function
__construct
(
CartRepositoryInterface
$quoteRepository
,
\Adyen\Payment\Logger\AdyenLogger
$adyenLogger
,
\Magento\Quote\Model\QuoteIdMaskFactory
$quoteIdMaskFactory
)
{
$this
->
quoteRepository
=
$quoteRepository
;
$this
->
adyenLogger
=
$adyenLogger
;
$this
->
quoteIdMaskFactory
=
$quoteIdMaskFactory
;
}
/**
* @param \Magento\Checkout\Api\GuestPaymentInformationManagementInterface $subject
* @param $cartId
* @return null
*/
public
function
beforeSavePaymentInformationAndPlaceOrder
(
\Magento\Checkout\Api\GuestPaymentInformationManagementInterface
$subject
,
$cartId
)
{
try
{
$quoteIdMask
=
$this
->
quoteIdMaskFactory
->
create
()
->
load
(
$cartId
,
'masked_id'
);
$quoteId
=
$quoteIdMask
->
getQuoteId
();
$this
->
quoteRepository
->
get
(
$quoteId
)
->
setReservedOrderId
(
null
);
}
catch
(
\Exception
$e
)
{
$this
->
adyenLogger
->
error
(
"Failed to reset reservedOrderId for guest shopper"
.
$e
->
getMessage
());
}
return
null
;
}
}
Plugin/PaymentInformationResetOrderId.php
0 → 100644
View file @
04a2db14
<?php
/**
* ######
* ######
* ############ ####( ###### #####. ###### ############ ############
* ############# #####( ###### #####. ###### ############# #############
* ###### #####( ###### #####. ###### ##### ###### ##### ######
* ###### ###### #####( ###### #####. ###### ##### ##### ##### ######
* ###### ###### #####( ###### #####. ###### ##### ##### ######
* ############# ############# ############# ############# ##### ######
* ############ ############ ############# ############ ##### ######
* ######
* #############
* ############
*
* Adyen Payment module (https://www.adyen.com/)
*
* Copyright (c) 2019 Adyen BV (https://www.adyen.com/)
* See LICENSE.txt for license details.
*
* Author: Adyen <magento@adyen.com>
*/
namespace
Adyen\Payment\Plugin
;
use
Magento\Quote\Api\CartRepositoryInterface
;
class
PaymentInformationResetOrderId
{
/**
* Quote repository.
*
* @var \Magento\Quote\Api\CartRepositoryInterface
*/
protected
$quoteRepository
;
/**
* @var \Adyen\Payment\Logger\AdyenLogger
*/
protected
$adyenLogger
;
/**
* PaymentInformationResetOrderId constructor.
* @param CartRepositoryInterface $quoteRepository
* @param \Adyen\Payment\Logger\AdyenLogger $adyenLogger
*/
public
function
__construct
(
CartRepositoryInterface
$quoteRepository
,
\Adyen\Payment\Logger\AdyenLogger
$adyenLogger
)
{
$this
->
quoteRepository
=
$quoteRepository
;
$this
->
adyenLogger
=
$adyenLogger
;
}
/**
* @param \Magento\Checkout\Api\PaymentInformationManagementInterface $subject
* @param $cartId
*/
public
function
beforeSavePaymentInformationAndPlaceOrder
(
\Magento\Checkout\Api\PaymentInformationManagementInterface
$subject
,
$cartId
)
{
try
{
$this
->
quoteRepository
->
get
(
$cartId
)
->
setReservedOrderId
(
null
);
}
catch
(
\Exception
$e
)
{
$this
->
adyenLogger
->
error
(
"Failed to reset reservedOrderId "
.
$e
->
getMessage
());
}
return
null
;
}
}
composer.json
View file @
04a2db14
...
...
@@ -2,7 +2,7 @@
"name"
:
"adyen/module-payment"
,
"description"
:
"Official Magento2 Plugin to connect to Payment Service Provider Adyen."
,
"type"
:
"magento2-module"
,
"version"
:
"6.6.
0
"
,
"version"
:
"6.6.
1
"
,
"license"
:
[
"OSL-3.0"
,
"AFL-3.0"
...
...
etc/config.xml
View file @
04a2db14
...
...
@@ -230,17 +230,5 @@
<group>
adyen
</group>
</adyen_google_pay>
</payment>
<dev>
<js>
<minify_exclude>
<adyen_payment>
adyen.com/checkoutshopper
</adyen_payment>
</minify_exclude>
</js>
<css>
<minify_exclude>
<adyen_payment>
adyen.com/checkoutshopper
</adyen_payment>
</minify_exclude>
</css>
</dev>
</default>
</config>
etc/di.xml
View file @
04a2db14
...
...
@@ -1028,6 +1028,14 @@
<type
name=
"Magento\Vault\Api\PaymentTokenRepositoryInterface"
>
<plugin
name=
"AdyenPaymentVaultDeleteToken"
type=
"Adyen\Payment\Plugin\PaymentVaultDeleteToken"
sortOrder=
"10"
/>
</type>
<type
name=
"Magento\Checkout\Api\PaymentInformationManagementInterface"
>
<plugin
name=
"AdyenPaymentInformationResetOrderId"
type=
"Adyen\Payment\Plugin\PaymentInformationResetOrderId"
sortOrder=
"10"
/>
</type>
<type
name=
"Magento\Checkout\Api\GuestPaymentInformationManagementInterface"
>
<plugin
name=
"GuestAdyenPaymentInformationResetOrderId"
type=
"Adyen\Payment\Plugin\GuestPaymentInformationResetOrderId"
sortOrder=
"10"
/>
</type>
<!--Notifications overview-->
<type
name=
"Magento\Framework\View\Element\UiComponent\DataProvider\CollectionFactory"
>
...
...
view/frontend/web/js/view/payment/method-renderer/adyen-google-pay-method.js
View file @
04a2db14
...
...
@@ -215,7 +215,10 @@ define(
return
window
.
checkoutConfig
.
payment
.
adyen
.
originKey
;
},
getCheckoutEnvironment
:
function
()
{
return
window
.
checkoutConfig
.
payment
.
adyen
.
checkoutEnvironment
;
return
window
.
checkoutConfig
.
payment
.
adyenGooglePay
.
checkoutEnvironment
;
},
onPaymentMethodContentChange
:
function
(
data
,
event
)
{
$
(
this
.
googlePayNode
).
find
(
'
button
'
).
prop
(
'
disabled
'
,
!
this
.
validate
());
}
});
}
...
...
view/frontend/web/template/payment/google-pay-form.html
View file @
04a2db14
...
...
@@ -45,7 +45,7 @@
<!--/ko-->
</div>
<div
class=
"checkout-agreements-block"
afterRender=
"bindDomEventListener"
>
<div
class=
"checkout-agreements-block"
>
<!-- ko foreach: $parent.getRegion('before-place-order') -->
<!-- ko template: getTemplate() --><!-- /ko -->
<!--/ko-->
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment