Code Monkey home page Code Monkey logo

sezzle-magento2's Introduction

Sezzle Extension for Magento 2

Introduction

This document will help you in installing Sezzle's Magento 2 extension. This extension is a certified one and listed here in the marketplace. The plugin can also be downloaded from github.

How to install the extension?

There are two ways of installing and upgrading the extension.

  • By composer.
  • Manual Process.

For all purposes assume [Magento] as your Magento 2 root directory.

Composer

  • Open terminal and navigate to Magento root path.
  • composer require sezzle/sezzlepay
  • php bin/magento setup:upgrade
  • php bin/magento setup:di:compile
  • php bin/magento setup:static-content:deploy
  • php bin/magento cache:clean

Manual

  • Download the .zip or tar.gz file from Sezzle's github repository.
  • Unzip the file and follow the following instructions.
  • Navigate to Magento [Magento]/app/code/ either through SFTP or SSH.
  • Copy Sezzle directory from unzipped folder to [Magento]/app/code/.
  • Open the terminal.
  • Run the following command to enable Sezzle: php bin/magento module:enable Sezzle_Sezzlepay
  • Run the Magento setup upgrade: php bin/magento setup:upgrade
  • Run the Magento Dependencies Injection Compile: php bin/`magento` setup:di:compile
  • Run the Magento Static Content deployment: php bin/magento setup:static-content:deploy
  • Login to Magento Admin and navigate to System > Cache Management.
  • Flush the cache storage by selecting Flush Cache Storage.

You can now directly navigate from the Configuration Page to get signed up for Sezzle. To do so, you need to click on Register for Sezzle which will redirect you to the Sezzle Merchant Signup Page. If you have the details already, you can simply click on I've already setup Sezzle, I want to edit my settings to move ahead.

How to upgrade the extension?

Composer

  • Open terminal and navigate to Magento root path.
  • composer update sezzle/sezzlepay
  • php bin/magento setup:upgrade
  • php bin/magento setup:di:compile
  • php bin/magento setup:static-content:deploy
  • php bin/magento cache:clean

Manual

  • Download the .zip or tar.gz file from Sezzle's github repository.
  • Unzip the file and follow the following instructions.
  • Copy Sezzle directory from unzipped folder to [Magento]/app/code/. Make sure you are overwriting the files.
  • Open the terminal.
  • Run the following command to enable Sezzle: php bin/magento module:enable Sezzle_Sezzlepay
  • Run the Magento setup upgrade: php bin/magento setup:upgrade
  • Run the Magento Dependencies Injection Compile: php bin/`magento` setup:di:compile
  • Run the Magento Static Content deployment: php bin/magento setup:static-content:deploy
  • Login to Magento Admin and navigate to System > Cache Management.
  • Flush the cache storage by selecting Flush Cache Storage.

Configure Sezzle

Payment Configuration

  • Set Enabled as Yes to activate Sezzle as a payment option.
  • Make sure you have the Merchant UUID and the API Keys from the Sezzle Merchant Dashboard. Sign Up if you have not signed up to get the necessities.
  • Navigate to Stores > Configuration > Sales > Payment Methods > Sezzle > Payment Settings in your Magento admin.
  • Set the Payment Mode to Live for LIVE and set it as Sandbox for SANDBOX.
  • Set the Merchant UUID, Public Key and Private Key.
  • Set Payment Action as Authorize only for doing payment authorization only and Authorize and Capture for doing instant capture.
  • Set Min Checkout Amount to restrict Sezzle payment method below that amount.
  • Set Payment from Applicable Countries to Specific Countries.
  • Set Payment from Specific Countries to United States or Canada as Sezzle is currently available for US and Canada only.
  • Set Enable Customer Tokenization to Yes for allowing Sezzle to tokenize the customer account if they approve it. If customer wish to tokenize their account, next time, they don't have to redirect to Sezzle Checkout for completing the purchase, rather it will happen in your website.
  • Set Sort Order to manage the position of Sezzle in the checkout payment options list.
  • Save the configuration and clear the cache.

In-Context Configuration

  • Set Enable In-Context Solution to Yes for the In-Context Checkout to get activated.
  • Set In-Context Checkout Mode to IFrame or PopUp depending on how you want Sezzle Checkout to get hosted.

Settlement Report Configuration

  • Set Enable Settlement Reports to Yes for the Settlement Reports Dashboard to get activated.
  • Set Range to a value based on which you want to fetch the Settlement Reports.
  • Set Enable Automatic Syncing to fetch the Settlement Reports asynchronously.
  • Set Schedule and Time of Day for the above automatic sync to run.

Note : Automatic Syncing requires cron to be enabled.

Widget Configuration

  • Set Enable Widget in PDP to Yes for adding widget script in the Product Display Page which will help in enabling Sezzle Widget Modal in PDP.
  • Set Enable Widget in Cart Page to Yes for adding widget script in the Cart Page which will help in enabling Sezzle Widget Modal in Cart Page.
  • Set Enable Installment Widget in Checkout Page to Yes if you want to show the Sezzle Installment Widget under Sezzle Payment Option in Checkout Page.
  • Set Path to Price Element. This is the path to the element in the Checkout Page where the order total text value will be detected.
  • Save the configuration and clear the cache.

Developer Configuration

  • Enable the log tracker to trace the Sezzle checkout process.
  • Set Send Logs to Sezzle to Yes if you want the logs to be sent to Sezzle in a periodic basic. For this cron needs to be enabled.
  • You can also download the latest logs by clicking on Sezzle Log if any.
  • Save the configuration and clear the cache.

Your store is now ready to accept payments through Sezzle.

Frontend Functionality

  • If you have correctly set up Sezzle, you will see Sezzle as a payment method in the checkout page.
  • Select Sezzle and move forward.
  • Once you click Continue to Sezzle or Place Order, you will be redirected to Sezzle Checkout to complete the checkout.
  • In the final page of Sezzle Checkout, check the Approve {Website Name} to process payments from your Sezzle account for future transactions. You may revoke this authorization at any time in your Sezzle Dashboard to tokenize your account. And, then click on Complete Order to complete your purchase.
  • If your account is already tokenized, order will be placed without redirection otherwise you will be redirected to Sezzle Checkout for completing the purchase.
  • On successful order placement, you will be redirected to the order confirmation page.

Capture Payment

  • If Payment Action is set to Authorize and Capture, capture will be performed instantly from the extension after order is created and validated in Magento.
  • If Payment Action is set to Authorize, capture needs to be performed manually from the Magento admin. Follow the below steps to do so.
    • Go the order and click on Invoice.
    • Verify your input in the Create Invoice page and click on Save to create the invoice.
    • This will automatically capture the payment in Sezzle.
    • Payment can also be captured via Magento 2 Invoice API.

Refund Payment

  • Go to Sales > Orders in the Magento admin.
  • Select the order for which you want to refund the payment.
  • Go to Invoices and select the invoice for which you to refund.
  • Click on Credit Memo and verify your input in the Create Credit Memo page.
  • Save it and the refunded will be initiated in Sezzle.
  • In Sezzle Merchant Dashboard, Order Status as Refunded means payment has been fully refunded and Order Status as Partially Refunded means payment has been partially refunded.
  • Payment can also be refunded via Magento 2 Refund API.

Release Payment

  • Go to Sales > Orders in the Magento admin.
  • Select the order for which you want to release the payment.
  • Click on Void and confirm your action.
  • In Sezzle Merchant Dashboard, Order Status as Deleted due to checkout not being captured before expiration means payment has been fully released.
  • Only Full Release is supported from Magento.
  • Payment can also be released via Magento 2 Void API.

Order Verification in Magento Admin

  • Login to Magento admin and navigate to Sales > Orders.
  • Proceed into the corresponding order.
  • If Order Status is Processing and Total Paid is equals to Grand Total, payment is successfully captured by Sezzle.
  • If Order Status is Pending and Total Paid is not equals to Grand Total, payment is authorized but yet not captured.
  • If Order Status is Closed, payment is refunded.
  • If Order Status is Canceled, payment is released.

Order Verification in Sezzle Merchant Dashboard

  • Login to Sezzle Merchant Dashboard and navigate to Orders.
  • Proceed into the corresponding order.
  • Status as Approved means payment is successfully captured by Sezzle.
  • Status as Authorized, uncaptured means payment is authorized but yet not captured.
  • Status as Refunded means payment is refunded.
  • Status as Deleted due to checkout not being captured before expiration means either payment was not captured in time or the payment is released.

Customer Tokenization Details

  • Login to Magento admin and navigate to Customers > All Customers.
  • Go inside a customer for which you want to see the tokenization details.
  • Sezzle tab will appear if the customer is tokenized.
  • Customer UUID, Expiration Date and Status will appear.

Settlement Reports

  • Login to Magento admin and navigate to Reports > Sales > Sezzle Settlement.
  • List of the latest Settlement Reports will be shown.
  • To make a quick sync, enter the From and To Date and click on Sync.
  • Click on Download from the Action column for downloading a Settlement Report.
  • For viewing the details of a particular Settlement Report, click on View from Action column.
  • Settlement Report details can also be downloaded by entering the Settlement Report view.
  • Settlement Report can be downloaded via CSV or Excel and Settlement Report Details will be downloaded via CSV.

How Sandbox works?

  • In the Sezzle configuration page of your Magento admin, enter the Sandbox API Keys from your Sezzle Merchant Sandbox Dashboard and set the Payment Mode to Sandbox, then save the configuration. Make sure you are doing this on your dev/staging website.
  • On your website, add an item to the cart, then proceed to Checkout and select Sezzle as the payment method.
  • To pay with Sezzle:
    • If customer is not tokenized, click Continue to Sezzle.
    • If customer is tokenized, click Place Order. However, if the customer tokenization is expired, Sezzle will create a new checkout on clicking Place Order.
    • If In-Context checkout, click Pay with Sezzle.
  • For In-Context checkout, the Sezzle checkout will be hosted in the configured mode, iFrame or Popup. Otherwise, you will be redirected to the Sezzle checkout.
  • Sign In or Sign Up to continue.
  • Enter the payment details using test data, then move to final page.
  • Check the Approve {Website Name} to process payments from your Sezzle account for future transactions. You may revoke this authorization at any time in your Sezzle Dashboard to tokenize your account.
  • If your account is already tokenized, order will be placed without redirection otherwise you will be redirected to Sezzle Checkout for completing the purchase.
  • After payment is completed at Sezzle, you will be directed to your site's successful payment page.
  • Sandbox testing is complete. You can login to your Sezzle Merchant Sandbox Dashboard to see the test order you just placed.

Troubleshooting/Debugging

  • There is logging enabled by Sezzle for tracing the Sezzle actions.
  • In case merchant is facing issues which is unknown to Merchant Success and Support team, they can ask for this logs and forward to the Platform Integrations team.
  • Name of the log will be sezzlepay.log.It is always recommended to send the system.log and exception.log for better tracing of issues.

Docker Environment Set Up

Start

  • Clone the repo.
  • Execute docker-compose up -d --build to start the Magento server.
  • Server will be up at localhost:8085. If you want to change that, edit the docker-compose.yml.

Install Magento

docker exec -it sezzle_magento2 process install

Sezzle will be installed alongside.

Sample Data Deploy

docker exec -it sezzle_magento2 process install-sampledata

Database Upgrade

docker exec -it sezzle_magento2 process upgrade

Compile

docker exec -it sezzle_magento2 process compile

Deploy Static Files

docker exec -it sezzle_magento2 process deploy

Set Developer Mode

docker exec -it sezzle_magento2 process developer

Cache Clear

docker exec -it sezzle_magento2 process clear

Cleanup Environment

docker-compose down --rmi local -v --remove-orphans

sezzle-magento2's People

Contributors

aholdahl avatar arijit-codilar avatar arijit-de avatar arijit-sezzle avatar carlodekker avatar rishimukherjee avatar sitikanthasezzle avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sezzle-magento2's Issues

Change introduced in release 5.2 breaks sandbox connection

The update to the file Model/System/Config/Container/SezzleIdentity.php which changes the sandboxGatewayUrl from https://sandbox.gateway.sezzle.com to https://staging.gateway.sezzle.com causes my authentication requests to have a 401 response. It would appear that the API keys generated from https://sandbox.dashboard.sezzle.com/merchant/settings/apikeys are not valid for the staging.gateway.sezzle.com domain.

As a result I have to force composer to install version 5.1.1, which does work.

Magento 2.3.1 compatibility

The Sezzle M2 extension is not compatible with Magento version 2.3.1 because it requires "magento/framework": ">=100.0.4 <=102".

Do you have a release schedule for adjusting the requirements and compatibility?

Error in Graphql when executing createSezzleCheckout mutation

When we execute this mutation
mutation createSezzleCheckout($cart_id: String!) {
action:createSezzleCheckout(input: { cart_id: $cart_id }) {
success
checkout_url
}
}
We always get "Internal server error"
and in the log we have
main.ERROR: Sezzle\Sezzlepay\Gateway\Request\Session\OrderRequestBuilder::getPriceObject(): Argument #1 ($amount) must be of type float, null given

we are using Postman to re-produce this issue
do you have any idea?
in other hand this mutaton is working as expected "createSezzleCustomerOrder"

Class 'Zend\Log\Writer\Stream' not found

Preconditions (*)

Magento 2.4.3

Steps to reproduce (*)

  • payment/sezzlepay/log_tracker config has to be enabled
  • save the payment admin config for Sezzle payment

Expected result (*)

Admin config is saved

Actual result (*)

An error is thrown. Class 'Zend\Log\Writer\Stream' not found

In Magento 2.4.3 'laminas-log' has been removed. So the laminas-zendframework-bridge doesn't work anymore for the Log.

This is the magento commit that deleted the composer dependency:
magento/magento2@f0840b1#diff-d2ab9925cad7eac58e0ff4cc0d251a937ecf49e4b6bf57f8b95aab76648a9d34

This is the problematic line in sezzle-magento2:
https://github.com/sezzle/sezzle-magento2/blob/master/Helper/Data.php#L18

Magento 2.4.2-P1 Sezzle Error The requested qty is not available

Team,

When Configurable Child Last Item into Cart It is throwing error The requested qty is not available.

Senario,
Add Product Configurable with Simple Product into cart Which Simple Product (Child) have qty "1" (Last Item).
Process For Checkout Payment with Sezzle it is throwing Error "The requested qty is not available"

Screen Shot 2021-08-27 at 4 36 21 PM

Screen Shot 2021-08-27 at 4 56 27 PM

For Example there is Configurable Child Product 2 qty & add to Cart 2 qty. It is also given Same Error.

https://test.com/checkout/?deliveryType=ship#payment

image

image

Sezzle Trying Both Version 5.5.1 & 5.5.2 But Still Same issue.
image

Other Magento Default Payment Method working Fine with successful Order Placed ( Like PayPal, Amazon Pay, Check / Money Order etc)

Please Help me with that..

Order view plugin does not call proceed so prevents after plugins added to the execute method

We have a custom plugin that runs afterExecute on the order view controller. However your module adds a plugin aroundExecute on the same class that does not call proceed and thus stops our plugin from firing.

When reading this code it seems like the only requirement is setting a specific flag on the order before the page is rendered.
https://github.com/sezzle/sezzle-magento2/blob/master/Plugin/Sales/Controller/Adminhtml/Order/ViewPlugin.php

If that is the case, there is no need to us an around plugin, and especially not to have the plugin also extend the class it is plugging into. Could you not instead use a before plugin like so?:

<?php

namespace Sezzle\Sezzlepay\Plugin\Sales\Controller\Adminhtml\Order;

use Magento\Framework\Exception\NoSuchEntityException;
use Magento\Sales\Api\OrderRepositoryInterface;
use Magento\Sales\Controller\Adminhtml\Order\View;
use Magento\Sales\Model\Order;
use Sezzle\Sezzlepay\Model\Sezzle;
use Sezzle\Sezzlepay\Model\System\Config\Container\SezzleConfigInterface;

class CheckAuthExpiry
{
    private $sezzleModel;
    private $sezzleConfig;
    private $orderRepository;

    /**
     * @param OrderRepositoryInterface $orderRepository
     * @param Sezzle $sezzleModel
     * @param SezzleConfigInterface $sezzleConfig
     */
    public function __construct(
        OrderRepositoryInterface $orderRepository,
        Sezzle $sezzleModel,
        SezzleConfigInterface $sezzleConfig
    ) {
        $this->orderRepository = $orderRepository;
        $this->sezzleModel = $sezzleModel;
        $this->sezzleConfig = $sezzleConfig;
    }

    public function beforeExecute(
        View $subject
    ) {
        try {
            $order = $this->orderRepository->get($subject->getRequest()->getParam('order_id'));
        } catch (NoSuchEntityException $e) {
            //Early exit, this exception will be thrown later in the request and exit before any of this
            //plugin's modifications are required
            return;
        }
        $isTokenizedAllowed = $this->sezzleConfig->isTokenizationAllowed();
        $order->setActionFlag(
            Order::ACTION_FLAG_INVOICE,
            $this->sezzleModel->canInvoice($order)
            || $isTokenizedAllowed
        );
    }
}

This would set the flag at the correct time without requiring you to extend the view controller or block other plugins. Thoughts?

Cheers
Luke

Product Detail Page (PDP) Widget is not working

Magento ver. 2.4.2
Sezzle - 5.5.5

Product Detail Page (PDP) Widget is not working.

I debugged JS. It seems they ignore path and use hardcoded in widget-renderer.js one.

<div id="sezzle-widget"/> after the price element in the PDP is present.

Issue With Merchant Id Validation

We have our merchant id a mix of Characters and Numbers .
Ex: tp0g0ovtiu1m2ci1 (this is not a real merchant_id )

When we configured the extension in our Magento 2.3.2-p2 site .
And set this two options to Yes :
Add Widget Script in Pdp
Add Widget Script in Cart Page
https://cl.ly/3a4ad49ab33c

Going into product page and cart page , we faced a js issue :
uncaught SyntaxError: Unexpected token b in JSON at position 91
https://cl.ly/3cbd743bdfca

This issue was related to the merchant_id being a mixed chars and int , while in templates :
https://github.com/sezzle/sezzle-magento2/blob/master/view/frontend/templates/product.phtml
https://github.com/sezzle/sezzle-magento2/blob/master/view/frontend/templates/cart.phtml
It want to be an integer.

I added "" on the merchant id value , and it removed the js issue .

Public repo has higher version than private repo causing composer errors in 2.4.3

In Magento 2.4.3, a new composer plugin was added: magento/composer-dependency-version-audit-plugin

This plugin only does one thing and that is to check if there are any versions of a package on a public repo (https://repo.packagist.org/) that have a version number that is higher than that package on the private repo (https://repo.magento.com/).

Running composer update sezzle/sezzlepay results in the following error message being displayed:

 [Exception]                                                                                                                                   
  Higher matching version 5.5.3 of sezzle/sezzlepay was found in public repository packagist.org                                                
                               than 5.5.2 in private https://repo.magento.com. Public package might've been taken over by a malicious entity,   
                               please investigate and update package requirement to match the version from the private repository         

The this is a major problem for any Magento store on 2.4.3 currently running sezzle as it prevents us from running any composer commands while this package is installed via composer. The immediate fix would be to publish the 5.5.3 upgrade to the magento marketplace and to avoid publishing the public releases before the private releases.

Auth Expires after 30 min.

Sezzle : 5.0.0
Magento: 2.3.3-p1

STR

Configuration :

  • Payment action : Authorize only
  1. Place an order and wait, don't capture it right away.
  2. After 30 min the order will be cancelled because it was not captured.

Issue

It might be that the merchant can not process or ship the order right away. There could be a delay up to even a few days if there is no stock. Hence this should be configurable in the admin or the min increased to at least two weeks.

I believe the API does offer this option to set the expiration time under https://docs.sezzle.com/#create-a-session under Order object and checkout_expiration. This should be added when building the order payload based on an admin config or a minimum of 7 days if not more.

Solution

Add the checkout_expiration to the payload returned by this method.

private function buildOrderPayload($quote, $reference)
{
$orderPayload = [
"intent" => "AUTH",
"reference_id" => $reference,
"description" => $this->storeManager->getStore()->getName(),
"requires_shipping_info" => false,
"items" => $this->buildItemPayload($quote),
"discounts" => [$this->getPriceObject($quote->getShippingAddress()->getBaseDiscountAmount())],
"shipping_amount" => $this->getPriceObject($quote->getShippingAddress()
->getBaseShippingAmount()),
"tax_amount" => $this->getPriceObject($quote->getShippingAddress()->getBaseTaxAmount()),
"order_amount" => $this->getPriceObject($quote->getBaseGrandTotal()),
];
if ($this->sezzleConfig->isInContextCheckout()) {
return array_merge($orderPayload, ['checkout_mode' => $this->sezzleConfig->getInContextMode()]);
}
return $orderPayload;
}

PHP 7.2 compatibility

When I try to install the extension via composer I get this error:
[InvalidArgumentException]
Package sezzle/sezzlepay at version has a PHP requirement incompatible with your PHP version (7.1.25)

Undefined index: pdp_widget_enabled or Undefined index: sezzle_enabled - Sezzle 7.0.7

Magento 2.4.3-p3
Sezzle: 7.0.7

When saving payment methods on anything other than the Scope: Default config I am receiving the error undefined index: pdp_widget_enabled or Undefined index: sezzle_enabled.

Output of one of Payment method configuration changes made when within a site level scope.

{"0":"Notice: Undefined index: pdp_widget_enabled in /vendor/sezzle/sezzlepay/Plugin/Config/Controller/Adminhtml/System/Config/SavePlugin.php on line 257","1":"#1 Sezzle\Sezzlepay\Plugin\Config\Controller\Adminhtml\System\Config\SavePlugin->getNewConfig() called at [vendor/sezzle/sezzlepay/Plugin/Config/Controller/Adminhtml/System/Config/SavePlugin.php:122]\n#2 Sezzle\Sezzlepay\Plugin\Config\Controller\Adminhtml\System\Config\SavePlugin->aroundExecute() called at [vendor/magento/framework/Interception/Interceptor.php:135]\n#3 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]\n#4 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->___callPlugins() called at [generated/code/Magento/Config/Controller/Adminhtml/System/Config/Save/Interceptor.php:23]\n#5 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->execute() called at [vendor/magento/framework/App/Action/Action.php:111]\n#6 Magento\Framework\App\Action\Action->dispatch() called at [vendor/magento/module-backend/App/AbstractAction.php:151]\n#7 Magento\Backend\App\AbstractAction->dispatch() called at [vendor/magento/module-config/Controller/Adminhtml/System/AbstractConfig.php:69]\n#8 Magento\Config\Controller\Adminhtml\System\AbstractConfig->dispatch() called at [vendor/magento/framework/Interception/Interceptor.php:58]\n#9 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]\n#10 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/module-backend/App/Action/Plugin/Authentication.php:143]\n#11 Magento\Backend\App\Action\Plugin\Authentication->aroundDispatch() called at [vendor/magento/framework/Interception/Interceptor.php:135]\n#12 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]\n#13 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->___callPlugins() called at [generated/code/Magento/Config/Controller/Adminhtml/System/Config/Save/Interceptor.php:32]\n#14 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->dispatch() called at [vendor/magento/framework/App/FrontController.php:245]\n#15 Magento\Framework\App\FrontController->getActionResponse() called at [vendor/magento/framework/App/FrontController.php:212]\n#16 Magento\Framework\App\FrontController->processRequest() called at [vendor/magento/framework/App/FrontController.php:147]\n#17 Magento\Framework\App\FrontController->dispatch() called at [vendor/magento/framework/Interception/Interceptor.php:58]\n#18 Magento\Framework\App\FrontController\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]\n#19 Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]\n#20 Magento\Framework\App\FrontController\Interceptor->___callPlugins() called at [generated/code/Magento/Framework/App/FrontController/Interceptor.php:23]\n#21 Magento\Framework\App\FrontController\Interceptor->dispatch() called at [vendor/magento/framework/App/Http.php:116]\n#22 Magento\Framework\App\Http->launch() called at [generated/code/Magento/Framework/App/Http/Interceptor.php:23]\n#23 Magento\Framework\App\Http\Interceptor->launch() called at [vendor/magento/framework/App/Bootstrap.php:264]\n#24 Magento\Framework\App\Bootstrap->run() called at [pub/index.php:30]\n","url":"/a0725885fc_admin/admin/system_config/save/key/4ab8aa3235981acca390c525584bb8ddfe0c5881b172020869313045db5ebad5/section/payment/website/2/","script_name":"/

Guest checkout with tokenization - Error - Customer is charged but order is not saved in M2

Sezzle version : 5.0.0
Magento version : 2.3.3-p1

STR:

  1. enable customer tokenization
  2. in-context checkout disabled
  3. Place an order as a guest
  4. You will be redirected to Sezzle
  5. Note the Option to "Approve STORE to process payments from your Sezzle account for future transactions. You may revoke this authorization at any time in your Sezzle Dashboard." is showing on the "You're approved" page.
  6. Check the option to "Approve .... future transactions...."
  7. Complete the order.
  8. It will fail to save the data and cause an error.

This is due to the fact that there is not check if the customer is logged in when creating preparing the customer payload.
See :

$tokenize = $this->sezzleConfig->isInContextCheckout()
? false
: $this->sezzleConfig->isTokenizationAllowed();

This will fail when the response is returned on this line :

$customer->setCustomAttributes($tokenAttributes);

because there is no customer id hence no customer.

I will submit a PR for this in a minute.

Sezzle payment option at checkout not working

Sezzle payment is not working, the option is showing at checkout but when you click place order nothing is happening. no error in log.
Magento ver. 2.2.3
Amasty One Step Checkout ( I tried with default checkout but to no avail)

Sizzle url: https://gateway.sezzle.com
I entered public and private key as per dashboard.
Did I missed something? What gives?

Undefined array key sezzlepay

Hello everyone.

I am having problems with Sezzle, because it is giving me an error when I give it "save configuration" in the store configuration, when I review the error, it indicates this message:

{"0":"Warning: Undefined array key "sezzlepay" in /var/www/vhosts/dev9.sbmedicaldeveloper.com/httpdocs/vendor/sezzle/sezzlepay/Plugin/Config/Controller/Adminhtml/System/Config/SavePlugin.php on line 113","1":"#1 Sezzle\Sezzlepay\Plugin\Config\Controller\Adminhtml\System\Config\SavePlugin->aroundExecute() called at [vendor/magento/framework/Interception/Interceptor.php:135]\n#2 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]\n#3 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->___callPlugins() called at [generated/code/Magento/Config/Controller/Adminhtml/System/Config/Save/Interceptor.php:23]\n#4 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->execute() called at [vendor/magento/framework/App/Action/Action.php:111]\n#5 Magento\Framework\App\Action\Action->dispatch() called at [vendor/magento/module-backend/App/AbstractAction.php:151]\n#6 Magento\Backend\App\AbstractAction->dispatch() called at [vendor/magento/module-config/Controller/Adminhtml/System/AbstractConfig.php:69]\n#7 Magento\Config\Controller\Adminhtml\System\AbstractConfig->dispatch() called at [vendor/magento/framework/Interception/Interceptor.php:58]\n#8 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]\n#9 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/module-backend/App/Action/Plugin/Authentication.php:145]\n#10 Magento\Backend\App\Action\Plugin\Authentication->aroundDispatch() called at [vendor/magento/framework/Interception/Interceptor.php:135]\n#11 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]\n#12 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->___callPlugins() called at [generated/code/Magento/Config/Controller/Adminhtml/System/Config/Save/Interceptor.php:32]\n#13 Magento\Config\Controller\Adminhtml\System\Config\Save\Interceptor->dispatch() called at [vendor/magento/framework/App/FrontController.php:245]\n#14 Magento\Framework\App\FrontController->getActionResponse() called at [vendor/magento/framework/App/FrontController.php:212]\n#15 Magento\Framework\App\FrontController->processRequest() called at [vendor/magento/framework/App/FrontController.php:147]\n#16 Magento\Framework\App\FrontController->dispatch() called at [vendor/magento/framework/Interception/Interceptor.php:58]\n#17 Magento\Framework\App\FrontController\Interceptor->___callParent() called at [vendor/magento/framework/Interception/Interceptor.php:138]\n#18 Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor/magento/framework/Interception/Interceptor.php:153]\n#19 Magento\Framework\App\FrontController\Interceptor->___callPlugins() called at [generated/code/Magento/Framework/App/FrontController/Interceptor.php:23]\n#20 Magento\Framework\App\FrontController\Interceptor->dispatch() called at [vendor/magento/framework/App/Http.php:116]\n#21 Magento\Framework\App\Http->launch() called at [vendor/magento/framework/App/Bootstrap.php:264]\n#22 Magento\Framework\App\Bootstrap->run() called at [pub/index.php:30]\n","url":"/admin_baiq83FNQt2d26W2K6Vuw5AQ6UVqua/admin/system_config/save/key/c8424a6fca5604a6f8bac98cabeb55424e271fce658a2890457c4584c5e07240/section/themecore/","script_name":"/pub/index.php","report_id":"6a808a4b9d2b1113b9c6d01d87c134e8744d2fe859318c16c1b134aec2bd319f"}

I am running magento 2.4.5-p1 and php 8.1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.