• I’m testing locally a new role that can only create/modify their own orders, but no matter which ‘shop_order’ capabilities I give it, it can’t create new orders.

    I’ve tried

    add_role( 'affiliate', 'Affiliate', array(
    'read' => true, 
    'level_1' => true,
    'manage_woocommerce' => true,
    'edit_shop_order' => true,
    'read_shop_order' => true,
    'delete_shop_order' => true,
    'edit_shop_orders' => true,
    'edit_others_shop_orders' => true,
    'publish_shop_orders' => true,
    'read_private_shop_orders' => true,
    'delete_shop_orders' => true,
    'delete_private_shop_orders' => true,
    'delete_published_shop_orders' => true,
    'delete_others_shop_orders' => true,
    'edit_private_shop_orders' => true,
    'edit_published_shop_orders' => true,
    'manage_shop_order_terms' => true,
    'edit_shop_order_terms' => true,
    'delete_shop_order_terms' => true,
    'assign_shop_order_terms' => true
    ));

    But, no luck. It’s only working when I add edit_posts => true to the array, but they shouldn’t be able to post new posts.

    Thank you in advance for any help/direction you can provide.

  • The topic ‘User with ‘shop_order’ capabilities can’t create new order’ is closed to new replies.