Banner Logo

🌟 Happy Durga Puja! 🌟 Wishing you a prosperous time ahead!

Our Support Might Experience Slight Delays from October 8th to 14th.

Get 23% discount

Coupon code:

PUJA23

Remove customer details from the vendors

Add the below code in the functions.php file of your current active theme to hide the customer details from the vendor –

add_filter( 'is_vendor_can_see_customer_details', '__return_false' );
add_filter( 'is_vendor_can_see_order_billing_address','__return_false');
add_filter('show_cust_address_field', '__return_false');
add_filter('show_cust_billing_address_field','__return_false');
add_filter('mvx_vendor_order_generate_csv_headers', 'custom_mvx_remove_from_csv');
function custom_mvx_remove_from_csv($headers) {
    unset($headers['buyer_email']);
    unset($headers['buyer_contact']);
    unset($headers['buyer_name']);
    unset($headers['billing_address']);
    return $headers;
}
add_filter('mvx_vendor_order_generate_csv', 'custom_mvx_remove_from_csv_data',10,2);
function custom_mvx_remove_from_csv_data($data, $order_id) {
    if (isset($data['buyer_email'])) {
        unset($data['buyer_email']);
    }
    if (isset($data['buyer_contact'])) {
        unset($data['buyer_contact']);
    }
    if (isset($data['buyer_name'])) {
        unset($data['buyer_name']);
    }
    if (isset($data['billing_address'])) {
        unset($data['billing_address']);
    }
    return $data;
}











Leave a Reply