Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- * Resync a WooCommerce order to WP Fusion.
- *
- * @param int $order_id The order ID.
- */
- function resync_woo_order( $order_id ) {
- if ( ! is_admin() || ! function_exists( 'wp_fusion_ecommerce' ) ) {
- return;
- }
- wp_fusion_ecommerce()->integrations->woocommerce->send_order_data( $order_id );
- }
- add_action( 'woocommerce_process_shop_order_meta', 'resync_woo_order', 100 ); // 100 so it runs after other data is saved,
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement