Hi,
As Jerome said you need the product_id which is in the order, for the email the product id is in the var: $item->order_product_name.
So you have to add the code:
$product_id = $item->order_product_name;
$productClass = hikashop_get('class.product');
$product = $productClass->get( $product_id );
echo $product->customfield_name;
Where "customfield_name" is the name of your custom field. You just have to replace that and it will display the content of this custom field.
If you want to display all the custom fields values, you can use:
$product_id = $item->order_product_name;
$productClass = hikashop_get('class.product');
$product = $productClass->get( $product_id );
foreach($product as $key => $value){
if(!preg_match('/product/',$key) && !empty($value)){
echo '$key: '.$value;
}
}