2

I have a post type that I set up some capabilities for and I attached them to a new Role, however, the role can not trash them. I'm not sure why though. Here is the portion of my array for the capabilities.

'capabilities' => array(
        'publish_posts' => 'publish_mro_project'
        ,'edit_posts' => 'edit_mro_project'
        ,'edit_others_posts' => 'edit_others_mro_projects'
        ,'delete_posts' => 'delete_mro_projects'
        ,'delete_others_posts' => 'delete_others_mro_projects'
        ,'read_private_posts' => 'read_private_mro_projects'
        ,'edit_post' => 'edit_mro_project'
        ,'delete_post' => 'delete_mro_project'
        ,'read_post' => 'read_mro_project'

As an admin, I can delete and trash the CPT, but when created the project admin and set the capabilities, they can add new ones and edit them, but the trash link does not appear. I'm not sure why this is the case. I used a user role editor plugin to assign all of the capabilities for this CPT if that makes a difference.

2

Try to specify the following capability, it helped in my case:

,'delete_published_posts' => 'delete_published_mro_project'

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.