-
Notifications
You must be signed in to change notification settings - Fork 76
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rework cart button to render alongside other payment types #12
Merged
Conversation
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
Merged
zichicc
pushed a commit
that referenced
this pull request
Jun 6, 2022
Async Error log was full of these. amazonAsyncIpnLogger.ERROR: Exception: Notice: Undefined index: charge_permission_id in /var/www/shop/prod/vendor/amzn/amazon-pay-magento-2-module/Model/AsyncManagement/Charge.php on line 213 in /var/www/shop/prod/vendor/magento/framework/App/ErrorHandler.php:61 Stack trace: #0 /var/www/shop/prod/vendor/amzn/amazon-pay-magento-2-module/Model/AsyncManagement/Charge.php(213): Magento\Framework\App\ErrorHandler->handler() #1 /var/www/shop/prod/vendor/amzn/amazon-pay-magento-2-module/Model/AsyncManagement/Charge.php(167): Amazon\Pay\Model\AsyncManagement\Charge->decline() #2 /var/www/shop/prod/vendor/amzn/amazon-pay-magento-2-module/Model/AsyncUpdater.php(79): Amazon\Pay\Model\AsyncManagement\Charge->processStateChange() #3 /var/www/shop/prod/vendor/amzn/amazon-pay-magento-2-module/Cron/ProcessAsync.php(71): Amazon\Pay\Model\AsyncUpdater->processPending() #4 [internal function]: Amazon\Pay\Cron\ProcessAsync->execute() #5 /var/www/shop/prod/vendor/magento/module-cron/Observer/ProcessCronQueueObserver.php(368): call_user_func_array() #6 /var/www/shop/prod/vendor/magento/module-cron/Observer/ProcessCronQueueObserver.php(879): Magento\Cron\Observer\ProcessCronQueueObserver->_runJob() #7 /var/www/shop/prod/vendor/magento/module-cron/Observer/ProcessCronQueueObserver.php(840): Magento\Cron\Observer\ProcessCronQueueObserver->tryRunJob() #8 /var/www/shop/prod/vendor/magento/module-cron/Observer/ProcessCronQueueObserver.php(280): Magento\Cron\Observer\ProcessCronQueueObserver->processPendingJobs() #9 /var/www/shop/prod/vendor/magento/framework/Event/Invoker/InvokerDefault.php(88): Magento\Cron\Observer\ProcessCronQueueObserver->execute() #10 /var/www/shop/prod/vendor/magento/framework/Event/Invoker/InvokerDefault.php(74): Magento\Framework\Event\Invoker\InvokerDefault->_callObserverMethod() #11 /var/www/shop/prod/vendor/magento/framework/Event/Manager.php(66): Magento\Framework\Event\Invoker\InvokerDefault->dispatch() #12 /var/www/shop/prod/generated/code/Magento/Framework/Event/Manager/Proxy.php(95): Magento\Framework\Event\Manager->dispatch() #13 /var/www/shop/prod/vendor/magento/framework/App/Cron.php(86): Magento\Framework\Event\Manager\Proxy->dispatch() #14 /var/www/shop/prod/vendor/magento/module-cron/Console/Command/CronCommand.php(117): Magento\Framework\App\Cron->launch() #15 /var/www/shop/prod/vendor/symfony/console/Command/Command.php(255): Magento\Cron\Console\Command\CronCommand->execute() #16 /var/www/shop/prod/vendor/magento/framework/Interception/Interceptor.php(58): Symfony\Component\Console\Command\Command->run() #17 /var/www/shop/prod/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Cron\Console\Command\CronCommand\Interceptor->___callParent() #18 /var/www/shop/prod/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Cron\Console\Command\CronCommand\Interceptor->Magento\Framework\Interception\{closure}() #19 /var/www/shop/prod/generated/code/Magento/Cron/Console/Command/CronCommand/Interceptor.php(77): Magento\Cron\Console\Command\CronCommand\Interceptor->___callPlugins() #20 /var/www/shop/prod/vendor/symfony/console/Application.php(1009): Magento\Cron\Console\Command\CronCommand\Interceptor->run() #21 /var/www/shop/prod/vendor/symfony/console/Application.php(273): Symfony\Component\Console\Application->doRunCommand() #22 /var/www/shop/prod/vendor/magento/framework/Console/Cli.php(115): Symfony\Component\Console\Application->doRun() #23 /var/www/shop/prod/vendor/symfony/console/Application.php(149): Magento\Framework\Console\Cli->doRun() #24 /var/www/shop/prod/bin/magento(23): Symfony\Component\Console\Application->run() #25 {main} [] []
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a somewhat tentative PR. The master code injects the Amazon button above most of the minicart contents via layout updates in default.xml.
However, this doesn't work the same way that other payment types inject similar buttons in core Magento. This causes it to be rendered in a different location from other payment buttons and makes more work for styling the buttons together.
This PR replicates this functionality and uses an observer and a ShortcutInterface block defined in the frontend di.xml to inject the block in the same content area.