Incorrect tax status on product import
-
I have a seller who has both taxable and non-taxable items. I have created a custom hook upon product creation to get it to reflect the proper tax status. Is this the recommended way of doing or could there be something added to the core plugin to better reflect the taxes in Square. Square is the main record in this case.
add_action( 'woocommerce_square_create_product', [$this, 'action_update_product_tax_status'], 10, 2 ); /** * Updates product tax status when item is created from Square. */ public function action_update_product_tax_status($product_id, $data) { // Non-taxable item. if (!property_exists($data, 'tax_ids')) { update_post_meta($product_id, '_tax_status', 'none'); } }
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Incorrect tax status on product import’ is closed to new replies.