Hi @konnox,
Please find the below sample example which you can use to print the custom extra field on the Print Invoice.
add_filter( 'wcdn_order_info_fields', 'wcdn_order_info_fields_function', 10, 2 );
public static function wcdn_order_info_fields_function( $fields, $order ) {
$new_fields = array();
$locations_label = "Your Custom label";
$output = "Your custom data which you want to output";
$new_fields[ $locations_label ] = array(
'label' => $locations_label,
'value' => $output
);
return array_merge( $fields, $new_fields );
}
I hope the provided sample example helps you to add the custom fields to the Invoices template. Let me know if you need any further assistance.
Regards,
Komal Maru