Updated: Your are confusing order post meta data and order item meta data, which are very different things and located in different database ...
I'm working on a woocommerce plugin. On WC 3.2.6. In my code, I have a WC_Order_Item_Product with variations that I'm getting from $order->get_items().
(can be a product variation too) $product = $item->get_product(); // Get the ...
Following below code according your need. To get the selected variation attributes using get_variation_attributes( ) method. // Get an instance of the WC_Order ...
echo $order_item->get_variation_id(); // or $order_item['variation_id']; echo ...
You cannot set a specific variation to only be sold once per order .
The following will not only save the parent SKU but also the variation SKU to the item meta. add_action( 'woocommerce_add_order_item_meta', ' ...
Order Qty – Customer must purchase no less than this quantity of items to ...
echo '< div class="wc-order-item-variation">' . esc_html__( 'Variation ID:', ...
Get total tax. get_type() : string: Get order item type. get_variation_id() : int: Get variation ID. is_type() : ...