Skip to content

Invoice Payment

Description

Invoice Payment

Invoice Payment extension allows the merchant to generate an order in Magento and send a request for payment to their customer, which enables them to pay online via credit/debit card.

Features

  • Allows the customer to pay online for their orders placed using offline payment methods (Check / Money Order, for example) that Admin has created on behalf of the customer.
  • Payment Method: Stripe and Braintree
  • Generates invoices and sent to customers upon completion of payment.

Module Demo

Compatibility

The invoice Payment module is compatible with the following Magento platforms:

Community Edition (Open Source) Enterprise Edition (Commerce) Cloud Edition
2.3.0 - 2.4.* 2.3.0 - 2.4.* 2.3.0 - 2.4.*

Installation

Installing module using zip file

  • Unzip and paste the extension file into your root Magento folder.
  • Connect to your server by SSH.
  • Go to your Magento root folder.
  • To install the extension, perform this command:
php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy
  • After installing the module, you will need to install the Stripe SDK using the command:
composer require stripe/stripe-php

Composer installation

If you haven't installed any Aitoc module before, in that case, first, you will need to add your Aitoc composer repository. Please go through the document to see how you can add a composer repository.

To install the module, you will need to run the following commands:

composer require aitoc/module-invoice-payment
php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy -f
  • To switch the extension on/off, perform these commands:
php bin/magento module:enable Aitoc_InvoicePayment
php bin/magento module:disable Aitoc_InvoicePayment
  • To update the module, use below command:
composer update aitoc/module-invoice-payment

Version Compatibility

Invoice Payment is compatible with the following Magento platforms:

Community Edition (Open Source) Enterprise Edition (Commerce) Cloud Edition
2.3.0 - 2.4.* 2.3.0 - 2.4.* 2.3.0 - 2.4.*

Change Log

Version Release Date Changes
1.0.0 30th October 2018 Initial Release

General Usage

Extension Configuration

To access the configuration of the module, select Stores → Configuration → AITOC EXTENSIONS → Invoice Payment from within the admin panel:

Invoice Payment)

Also, you can go to Admin → AITOC → Invoice Payment → Configuration to access module configuration:

Invoice Payment)

The backend administrator can Enable the extension that allows selecting the Payment Integration Method.

Email copy of the invoice to customer if set to Yes, send an email of the invoice to the customers once they make the payment.

Payment Integration Method

One can use two different options here:

1) Braintree

If the Braintree option is selected, the Braintree configuration options will appear below. Please make sure that the setup is done correctly. Use this link to configure Braintree Payment Method for your reference

Invoice Payment)

When Braintree is configured and enabled, the front-end payment option will look like this:

Invoice Payment)

2) Stripe

If selected, the Stripe configuration credentials will appear here:

Invoice Payment)

Publishable Key is the field to enter Publishable Key available in your Stripe Account.

Secret Key is the field to enter the Secret Key available in your Stripe Account.

Both keys are required to be set. Please use this link for reference.

Widget Name, Widget Description, & Widget Image will appear in the popup which will appear on the frontend when you will try to do payment:

Invoice Payment)


As per the above image:

  • Widget Name = Test Name
  • Widget Description = Test Description
  • Widget Image = The Icon appearing in the top-center of your popup.

Email Template Integration

The Order email template needs to be updated to include the payment link in the order confirmation email.

To update the email template, Go to Marketing → Email Template, and select the email template currently being used as a New Order confirmation email.

You can check the current email template which is in use for the New Order confirmation email template at: Stores → Configuration → Sales → Sales Email → Orders:

Invoice Payment)

Once you have opened the email template page, add the code just at the end of the email template (right before the footer template).

The code you need to insert is:

{{layout handle="sales_email_order_pay" order_id=$order.entity_id}}
Invoice Payment)

For more information regarding editing email templates, please visit the Magento guide

You'll need to save the template after making changes. Please make sure that the template you have edited/created is used as a New Order email Confirmation template.

Now, such a link will appear in the Order Confirmation email:

Invoice Payment)

Invoice Payment

Once the customers click the link, they are taken to the website, and they will see a page with details of their Order ID and the email address they've used during the checkout:

Invoice Payment)

The Order Increment Id and Email address fields will be pre-populated. The customer needs to verify the details and then click on the Pay Invoice button.

After that, the popup will appear where the user needs to enter the required details to make a payment

The popup may vary depending upon the selected Integration Method under Module Configuration.


Invoice Payment)

BrainTree Payment Integration



Invoice Payment)

Stripe Payment Integration

After entering the required payment details in the popup, the customer can click the Pay button. The customer will get a confirmation message and the invoice email.

Invoice Payment)

Magento 2 Confirmation Message

Payments For the Complete Orders

If any existing customer wants to make an online payment for the order they have placed using the Offline payment method; they will need to login into their account and go to the My Order / Order Listing section under their Account Dashboard. Then, they will need to select the order for which they want to pay online.

On the selected order/order detail page, there will be a link requesting to Pay online:

Invoice Payment)

The customer needs to click on this link and follow the process mentioned above.

Issues and Support

If you experience any issues with the extension, please do the following:

  • Document in detail what has happened.
  • Include screenshots and error messages.
  • Visit: https://www.aitoc.com/customer/account/create/ and create a new account (if you do not already have one).
  • Once logged in, click on SUPPORT, and then the Submit Request button to create a new support ticket.
Back to top