Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author algol.plus

    (@algolplus)

    hi

    yes, you should add some code to your functions.php.
    something like

    add_filter('woe_get_order_product_fields', 'add_product_two_fields', 10, 2);
    function add_product_two_fields($fields,$format) {
    	$fields['qty_name'] = array( 'label' => 'Quantity x Name', 'colname' => 'Quantity x Name', 'checked' => 1 );
    	return $fields;
    }
    
    //for csv/xls
    add_filter('woe_get_order_product_csv_value_qty_name', 'get_product_addon_qty_name', 10, 4);
    add_filter('woe_get_order_product_xls_value_qty_name', 'get_product_addon_qty_name', 10, 4);
    function get_product_addon_qty_name($value,$order, $item, $product) {
    	return $item['qty'] .' x '. $item['name'];
    }
    Thread Starter barbarawsimon

    (@barbarawsimon)

    Thank you so much, It works perfect!!! ??

    Plugin Author algol.plus

    (@algolplus)

    ok, good luck!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘custom product field’ is closed to new replies.