• akash000ahammed

    (@akash000ahammed)


    Hello, I need a help please. I want to have Payment method for example bKash, Nagad or Rocket written in Woocommerce orders page for each customer orders.

    Also, I want to have their phone number and trxn id on this page for each customer’s order.

    Please help me with this, since I will have big numbers of orders, I need this very much. I can add codes to plugin files if you guys guide me.

    Please see screenshot to understand better what I am looking for.

    https://prnt.sc/I5Cuq86UU0jy

    Thank you so much. Looking forward to hear back from experts.

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Thread Starter akash000ahammed

    (@akash000ahammed)

    Ok I found the solution, in new woo update they intruduced HPOS (?High-performance order storage), for this woo order table was conflicting with this plugin.

    I disabled HPOS from woocommerce->setting->advanced->features-> moved from HPOS to ?WordPress posts storage (legacy). That solved the issue. Now no conflicts, and trns id, phone number all showing perfectly in order page.

    Also I added another custom column to see from which method customers paying, wether it’s bkash, nagad or rocket. Maybe in next update you guys can try to add this. This will be helpful for owners who have big orders everyday.

    add_filter( 'manage_edit-shop_order_columns', 'akash_add_new_order_admin_list_column' );

    function akash_add_new_order_admin_list_column( $columns ) {
    $columns['payment_method'] = 'Payment Method';
    return $columns;
    }

    add_action( 'manage_shop_order_posts_custom_column', 'akash_add_new_order_admin_list_column_content' );

    function akash_add_new_order_admin_list_column_content( $column ) {

    global $post;

    if ( 'payment_method' === $column ) {

    $order = wc_get_order( $post->ID );
    echo $order->get_payment_method_title();

    }

    }

    Thanks.

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.