• Resolved deschle

    (@deschle)


    Hi,

    we added a meta field to woocommerce orders which is not being sent to hubspot (deals). The field is added by a call to wc_add_order_item_meta( $item_id, ‘Trainer’, $trainer_name ) inside the woocommerce “woocommerce_add_order_item_meta” hook.

    Are meta fields automatically sent to hubspot and I am missing something? If not, what would I need to do (e.g. add the meta field via the “hubwoo_map_ecomm_DEAL_properties” filter?

    Thanks
    Daniel

    • This topic was modified 11 months, 3 weeks ago by deschle.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author MakeWebBetter

    (@makewebbetter)

    Hello Daniel,

    By default, we didn’t sync the trainer name. You can use the filter to extent the functionality. For better clarification, Please connect with our support.

    If you have any further queries, feel free to connect with us.

    Best Regards,

    For anyone struggling with the same, here is a working example:

    
        add_filter( 'hubwoo_map_ecomm_DEAL_properties', function( $deal_properties, $order_id ){
            $order = wc_get_order( $order_id );
            // set deal properties
            $deal_properties['some custom property name'] = 'some value';
            ...
            return $deal_properties;
        }, 99, 2 );

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to add order item meta field to hubspot deals’ is closed to new replies.