1. Home
  2. Docs
  3. Modules
  4. WooCommerce Module

WooCommerce Module

WooCommerce Module for Easysale ERP

What is WooCommerce?

  1. WooCommerce is an eCommerce or Web Shop plugins for WordPress
  2. It is the most customizable eCommerce platform for building your online business.
  3. The advantage of using WooCommerce is – You can get LOTS of plugins are available which can help you setup different functionality as per your need. Also, lots of payment gateways, shipping gateways are present to help you easily setup payments
  4. WooCommerce is now the most popular eCommerce platform on the web (stats from Built With), so you can rest assured you’re in good company.

What is WooCommerce Module for Easysale ERP ?

WooCommerce module for Easysale ERP is a simple module which when installed in your Easysale ERP software will help you with synchronizing products, stocks & orders. With this module, you open an online shop from your POS software in minutes and stop worrying about adding Products in multiple software, updating stocks, Orders & much more.

Features in WooCommerce module:

  1. Synchronize products categories from POS to your online WooCommerce based webshop. (POS to WooCommerce)
  2. Synchronize products from POS to your online WooCommerce based webshop. (POS to WooCommerce)
  3. Update stock details from POS to WooCommerce (POS to WooCommerce)
  4. Synchronize Orders from WooCommece to POS (WooCommerce to POS)
  5. Assign different price for the webshop. (Using Selling Price Group feature)
  6. Map taxes
  7. Shows the details synchronization logs.
  8. Auto Synchronization based on Cron jobs.
  9. Customizable products field for synchronization during product creation & update.
  10. Synchronize product price Including Tax or Excluding tax.

Sync Product Categories:

Click on this Sync button to synchronize the categories & Sub-Categories present in UtimatePOS to WooCommerce.

Map Tax Rates:

This option is used to map the taxes present in Easysale ERP to that of the taxes present in WooCommerce.

This is useful for adding related tax for a product during creation & updating.

NOTE: You must map the taxes before Synchronizing Products & Orders.

Sync Products:

Synchronizing products is a time-consuming task and take up to 30 minutes or above depending on the number of products. Do not refresh or leave the page while synchronization is under progress.

Simple & Variable products synchronization is supported.

It has 2 options:

Sync only new products:

Using this option only newly created products in POS are created in WooCommerce. This option can be less time consuming, again it depends on the number of products.

Sync All:

Using this option all newly created products are created in POS & existing products are updated. Since it does both the operation of creation & updating it will be more time consuming than the previous option.

Sync Orders:

This option is used to get all orders in WooCommerce website to Easysale ERP.

All newly created or updated orders after the last sync get added to Easysale ERP. A special tag is also added to the order to mark it as an order from WooCommerce.

NOTE: you can automate this process of syncing orders by enabling “Enable Auto Sync” option in settings.  And adding the cron job for this, the update frequency is same as that of cron job frequency. Cron job command is mentioned in API Setting above.

Reset Synced Categories / Reset Synced Products:

When you click on sync Products it creates the product present in POS to WooCommerce. And with this, a link is established between the WooCommerce Products & POS Products.
Technically woocommerce products ID is stored in POS database to create a mapping between them.

After you have Synced the products if you click on “Reset Synced Products” then the link will be broken (technically the woocommerce product id stored in POS is deleted and set to null)
This reset is useful when you’re changing the WooCommerce Website.

After Reset if you click on Sync Products again then it will check for same products SKU present in WooCommerce, if not present then it will create the product and store the product id in POS.

Note: deleting of products in WooCommerce is not required if the SKU for products in WooCommerce & POS is the same.

Same applies to Categories also.

Using Order Webhook:

What is webhook:

Webhook helps you to get live orders from WooCommerce to Easysale ERP. Meaning whenever there is a new order in WooCommerce website it gets send instantly to Easysale ERP. This is a nice feature present in this module.

Setting up Webhook:

  1. Go to WooCommerce -> API settings -> WebHook settings, there you will find Order Created, Order Updated, Order Deleted, Order restored webhook settings containing Webhook Secret & Webhook Delivery URL

  2. Copy the Webhook Delivery URL for Order Created and create a new Webhook in WooCommerce. For creating Webhook in WooCommerce refer to this document: https://docs.woocommerce.com/document/webhooks/#section-3
    1. Name: Give any name which you can recognize.
    2. Status: Active
    3. Topic: Order Created
    4. Delivery URL: Paste the order created delivery URL from Easysale ERP.
    5. Secret: keep it blank.
    6. API version: WP REST API version 2
  3. Click on “Save Webhook” in WooCommerce.
  4. Copy the Generated “Secret” from WooCommerce and paste it to Webhook Secret of Easysale ERP Order Created.
  5. Repeat the above process for all other (Order Updated, Order Deleted, Order restored)

After configuring when a new order comes it will also be updated in Easysale ERP.

Error & Solutions:

Error 1:

Sometime during synchronizing you may get the following message/error

“live.EMERGENCY: File:………\vendor\automattic\woocommerce\src\WooCommerce\HttpClient\HttpClient.phpLine:375Message:Syntax error”

Solution:

In your WooCommerce “API Settings” change the “Woocommerce App URL” by adding “index.php” to it.

Example: Change the URL from
www.myWooCommerceStore.com to www.myWooCommerceStore.com/index.php

Error 2:

Sometimes in WooCommerce API bulk operations (add/edit/delete) are restricted. So it will give a error like
“Sorry, you are not allowed to batch manipulate this resource. [woocommerce_rest_cannot_batch]”

To resolve this error, follow this steps:

  1. Install & activate Code Snippet plugin in wordpress. https://wordpress.org/plugins/code-snippets/
  2. Go to Snippet -> Add New and add a new snippet
  3. The snippet will have below writen codes:add_filter( ‘woocommerce_rest_check_permissions’, ‘allow_bulk_operation’, 10, 4 );
    function allow_bulk_operation( $permission, $context, $object_id, $type ) {
    return true;
    }
  4. Save & Activate it.

Now it will allow the bulk operation from api.

If you want to understand it more better, check this link: https://wordpress.org/support/topic/restrict-endpoint-on-woocommerce-rest-api/

How can we help?