When you use automatic product imports via WP All import for example, you have to manually init variations every time. As this is quite annoying please add the following code into your functions.php:
function after_xml_import( $import_id, $import ) { $admin = new WooCommerce_Single_Variations_Admin('plugin', '1.3.19'); $admin->init();
$admin->update_variations(false, true);
$admin->reset_transients(false);
} add_action( 'pmxi_after_xml_import', 'after_xml_import', 10, 2 );
This will ensure all variations are reinitiated after import.
Currently When I am manually doing the INIT it is stuck at some point and not showing all the products variations on the front, what will be a quick fix for that? cant do the import again.
The Real Person!
Sometimes there may be some orphaned variations. At least all should show live. Check that.
One more thing is, now i can see the duplicate of the product with same name and sku, on categories pages.
Same here. Now we see duplicate products on category page.
The Real Person!
Please submit a ticket on our website and we will take a look.
I am getting the following error with this hook.
AH01071: Got error ‘PHP message: PHP Fatal error: Uncaught TypeError: call_user_func_array(): Argument #1 ($callback) must be a valid callback, function “_update_posts_count_on_transition_post_status” not found or invalid function name
Could you check it?
Thank you.