In place of manage_options
use the following permission instead: manage_woocommerce
:
add_submenu_page( 'woocommerce', 'Custom Report', 'Custom Report', 'manage_woocommerce', 'report-with-invoice', 'report_with_invoice' );
Related Posts:
- How to filter the role selector?
- Editor and contributor roles not correct after adding function
- How to check if a role has a specific capability
- How to remove sticky post capability for a specific user role?
- How can I have different groups of editors only allowed to edit certain parent+subpages?
- WordPress missing user roles on local dev machine. Live site works fine
- Remove wordpress author’s capability to moderate comments on their own posts
- Programmatically allow a non-author to edit a post based custom meta field
- Can you set a role as author?
- wordpress editor role remove all but ‘menus’ in appearance menu
- Allow an editor to change the author
- allow non logged in user to upload images in media library
- Limit a user to have access to only specified pages?
- how to remove some permissions from a shop “manager role” in woocommmerce?
- Hiding custom theme functionality using capabilities
- Make a single page in WordPress available only for Admin and Subscribers
- Custom Role read_private_posts Not Working
- Block access to plugins.php for custom role
- Trying to get new role to have edit permissions for custom content type
- Force “submit for review” on update?
- New folder and file permissions are not correct
- How might I enable a user to view Draft pages from a different Author, without the ability to edit?
- add_role() run only once?
- wp_update_user not updating
- REST API, get user role?
- Is WordPress’ is_user_logged_in() secure?
- Restrict users on multisite WordPress install
- Allow user to Publish, but not Edit or Delete
- Custom Post Type’s Capabilities map_meta_cap issues
- Reapproval for edits and deletion after post is published
- Adding multiple user roles dynamically
- Author Role – Allow editing of Gallery images
- What is the difference between “create_users” and “add_users” capabilities?
- Conditional Tags for Membership Levels when using Wishlist Member Plugin?
- Can I create users that have access to *some* other users posts instead of all other users posts?
- Allow user to edit specific user with meta key using map_meta_cap
- Let new user role to ‘edit_others_posts’ of other user role, not of its own type
- User registration approval based on role selected
- add_menu_page() for more than one user role
- How do I turn off the Admin Bar for all Subscribers?
- Hide from specific role the top admin bar new button
- exclude roles from overview
- How do I remove the Other Roles field (from User Role Editor plugin) in wp-admin/user-new.php
- How can I disable the update notice for non-administrators?
- How to allow user to edit post in wordpress
- Conditional tag based on the role of author in author.php
- Custom user roles for access to specific parts of the site
- Roles for Custom Post Types
- Assign a role to the user who registers on a form
- How can I add a custom role capability to use in a custom plugin?
- DISALLOW_FILE_EDIT constant being ignored
- How to change user role using hook
- User roles are changing automatically
- User restricted only show posts assigned to current user
- Custom Capabilities for CPT and Problem with current_user_can()
- Which capabilities are available in Gravity Forms Salesforce plugin? [closed]
- Woocommerce Wcvendors – duplicate emails when Vendor approved
- How to trigger an error: “You are not allowed to edit this post.”
- allowing subscriber role to delete their own posts
- Let users edit their role from the frontend
- List of users with email and role
- Preventing role reading others posts
- Subscription list function
- When using a user role editor how to find out any plugins’ or themes’ role?
- Require Capability to View Woocommerce Product
- Is there a capability/User role plugin that lets you specify edit ‘posts’ not ‘custom posts’? [duplicate]
- users in their Role can only their Posts
- Assigning a capability to a user role (code check)
- Adding a role using Members and Formidable Forms [closed]
- wp_update_user very slow
- On action, change user role
- User role and capablities only for 1 plugin
- Add a second role when registering programmatically
- WordPress hide any html element by css when user-role
- What would cause wp_insert_user role to work sporadically?
- How can I add capability to multiple roles?
- underscore not allowed in role slug?
- Blank Screen Edit Page when using Editor Role
- Front-end submitted post is published with admin ID as author
- Can someone help me out? Why isn’t this working?
- dynamic home page according to role user
- Custom site role cannot access Appearance menu
- Set User Role based on age result from Facebook Log-In – WordPress
- Custom Role Allowing Things It Shouldn’t Be
- List users of specific role instead of removing them with specific role
- Frontend view of normal Visitor
- Custom Role accessing the wp-option table
- used code below to allow Editor access to menus – but change permanent, how do I revert?
- Admin Post List Only Show One Category
- Display based on specific user
- How can change 12000 user role into contributor by sql [duplicate]
- Users can only save their draft once before saving for revision
- Is it possible to restrict a specific user to edit a specific custom post.
- Access to option page by role/capability
- Hide user fields based off capability
- Author capabilities: Deleting comments on their own published posts
- Set user role based on invitation code
- How to give access to the particular page in wordpress for specific username/email NOT roles [closed]
- WordPress users roles wp-admin
- User roles empty