Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi,

    You can use the example snippet provided for Get all groups the current user belongs to.
    Regarding the positioning you can add extra columns in the Admin orders overview( WooCommerce > Orders ) by using these filter hooks:
    manage_edit-shop_order_columns // adds column
    manage_shop_order_posts_custom_column // adds custom field meta data for new column.

    Hope these help you.

    Kind regards,
    George

    Thread Starter emmaekoncept

    (@emmaekoncept)

    Hi and thanks for your replay!

    Im not very good at codes… But you mean that i can add:

    $groups_user = new Groups_User( get_current_user_id() );
    // get group objects
    $user_groups = $groups_user->groups;
    // get group ids (user is direct member)
    $user_group_ids = $groups_user->group_ids;
    // get group ids (user is direct member or by group inheritance)
    $user_group_ids_deep = $groups_user->group_ids_deep;

    but to where?

    Is it a easier way to get the information about the customer? Like add some shortcode that will display the group belongin in the order confirmation email?

    Thank you!

    Hi,

    Then you can use this free plugin. You can download the zip file and install it as any other plugin. After activation, upon a new order the customer group(s) will be displayed in the notification email.

    Hope it helps.

    Cheers,
    George

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How see the group belonging in order’ is closed to new replies.