Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Upendra Kapse

    (@wpupen)

    Hello,

    I am afraid there is no direct setting to add a barcode like this in the print and it will require some custom changes. We do have an example code snippet that helps you add an additional field to the Invoice. Here’s this example function:

    /**
     * Add this code snippet in functions.php file of your currently active theme.
     * An example that adds a 'VAT' field to the end of the list. 
     */
    function example_custom_order_fields( $fields, $order ) {
        $new_fields = array();
            
        if( get_post_meta( $order->id, 'your_meta_field_name', true ) ) {
            $new_fields['your_meta_field_name'] = array( 
                'label' => 'VAT',
                'value' => get_post_meta( $order->id, 'your_meta_field_name', true )
            );
        }
        
        
        return array_merge( $fields, $new_fields );
    }
    add_filter( 'wcdn_order_info_fields', 'example_custom_order_fields', 10, 2 );

    But you will have to make changes to this function based on how the barcode is saved by that plugin.

    Kind Regards,
    Upendra.

    Plugin Support Upendra Kapse

    (@wpupen)

    You can also refer to this forum post in which one customer has posted a solution for this with the same WooCommerce Order Barcodes plugin:
    https://www.ads-software.com/support/topic/woocommerce-barcode/

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Add barcode to the Delivery Note’ is closed to new replies.