Woocommerce - woocommerce connector does not sync 2 ways

Hi everyone
I have installed woocommerce connector and hopefully entered all settings correctly. See screenshots below. The standard/integrated woocommerce sync option is switched off and only the wc connector is turned on.

erpnext -> wc sync worked. Products and their stock quantity showed up in Wordpress

wc -> erpnext syncs successful but without data being transferred. After 20 competed test purchases not a single one purchase order, customer, stock inventory change got synced back from wc to erpnext.

erpnext -> wc adding more items into stock does not get updated in wc.

What could be the reason?

Error Log shows entries with:

SELECT tabItem.name,
tabItem.item_code,
tabItem.item_name,
tabItem.item_group,
tabItem.description,
tabItem.woocommerce_description,
tabItem.has_variants,
tabItem.variant_of,
tabItem.stock_uom,
tabItem.image,
tabItem.woocommerce_product_id,
tabItem.woocommerce_variant_id,
tabItem.sync_qty_with_woocommerce,
tabItem.weight_per_unit,
tabItem.weight_uom
FROM tabItem, tabItem Price
WHERE tabItem Price.price_list = ‘Standard Selling’
AND tabItem.name = tabItem Price.item_code
AND tabItem.sync_with_woocommerce = 1
AND (tabItem.disabled IS NULL OR tabItem.disabled = 0) AND tabItem Price.modified >= ‘2021-02-01 20:00:49.775984’

1 Like

Hi, I just tested this plugin tonight. Took some time to check everything.
I’m still trying to figure everything out as we speak. I found that when I updated the item price in the price list and afterwards synced, Woocommerce and ERPnext were updated. Maybe this will work for you as well?

The price gets updated. Also descriptions. But stock updates do not get updated in both ways (sell 1 piece in WC does not result in -1 piece in erpnext stock - or adding stock in erpnext does not update the stock shown in WC).

Also no orders are shown in erpnext. No customer is added either when selling an item in Wordpress WC.
I tried with all kinds of sales statuses in WC (till “completed”). For every status in WC I did a manual sync in erpnext.

I do not have any Webhooks or so added in WC. As far as I understand the erpnext WC connector I do not have to add webhooks.

Some other peculiarity that I have to test more:
I am not sure when or because of what it happens but erpnext seems to add the same product a second time with a different ID as draft. After that the already existing product in WC can be deleted as it shows in the sync log, that an ID is missing for it.
I have to test more to find out when and why that happens.

But the general feeling of the woocommerce connector at the moment is, that it is not that robust. But I really, really, really want the connector to work. Would make our life so much easier.

I turned on the erpnext integrated woocommerce and turned off the woocommerce connector.

That works fine as it should: Order and customer gets sent to erpnext

But of course I want the stock also being changed both ways. So back to the connector.

Hi, I have the same error, when deleting the product in erpnext, or creating, it does not sync me in woocommerce. I really appreciate your support. @lasalesi

Is this a custom error that you have inserted for debug purposes? The sync does take into account change timestamps to be more resource efficient… Can you elaborate what the problem at hand is?

Hi, the app at the moment in the product part works for me only that it is not deleting the products, example, if I delete an item without erpnext movement, it will also delete it in Woo automatically.

Thanks again for everything.

1 Like

Yes, deletion is not a feature that was taken into account (also because it could go terribly wrong, in WooCommerce, you can easily delete items, whereas in ERPNext this is - which is good - more restricted).

Short conclusion:

  1. sync works now.
  2. issue 1 was: database table tabItem field “woocommerce_id” got filled properly. But field “woocommerce_product_id” did not. That resulted in the sync error “product_id” not found. Sync works by manually filling the “woocommerce_product_id” fields with the id from “woocommerce_id” in the table tabitem.
  3. issue 2 was: wordpress firewall plugin blocked ssl verification. All ok after adjusting firewall.