File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed
app/code/Magento/Paypal/view/frontend/web/js/view
dev/tests/integration/testsuite/Magento/Paypal/Block/PayLater Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change 8
8
'ko' ,
9
9
'uiElement' ,
10
10
'Magento_Paypal/js/in-context/paypal-sdk' ,
11
+ 'priceBox' ,
11
12
'domReady!'
12
13
] , function (
13
14
$ ,
@@ -44,8 +45,12 @@ define([
44
45
45
46
if ( this . displayAmount ) {
46
47
priceBox = $ ( this . priceBoxSelector ) ;
47
- this . price = priceBox . priceBox ( 'option' ) . priceConfig . prices . finalPrice . amount ;
48
- priceBox . on ( 'priceUpdated' , this . _onPriceChange . bind ( this ) ) ;
48
+ if ( priceBox . priceBox ( 'option' ) &&
49
+ priceBox . priceBox ( 'option' ) . prices
50
+ ) {
51
+ this . price = priceBox . priceBox ( 'option' ) . prices . finalPrice . amount ;
52
+ priceBox . on ( 'priceUpdated' , this . _onPriceChange . bind ( this ) ) ;
53
+ }
49
54
50
55
qty = $ ( this . qtyFieldSelector ) ;
51
56
qty . on ( 'change' , this . _onQtyChange . bind ( this ) ) ;
Original file line number Diff line number Diff line change 6
6
7
7
declare (strict_types=1 );
8
8
9
- namespace Magento \Paypal \Block \Paylater ;
9
+ namespace Magento \Paypal \Block \PayLater ;
10
10
11
11
use Magento \Framework \View \LayoutInterface ;
12
12
use Magento \TestFramework \Helper \Bootstrap ;
@@ -44,7 +44,7 @@ public function getJsLayoutDataProvider()
44
44
return [
45
45
[
46
46
['data-pp-placement ' => 'test-page ' ],
47
- ['attributes ' => ['data-pp-placement ' => 'test-page ' ]]
47
+ ['attributes ' => ['data-pp-placement ' => 'test-page ' , ' data-pp-style-logo-position ' => ' right ' ]]
48
48
],
49
49
];
50
50
}
You can’t perform that action at this time.
0 commit comments