我创建了一个称为警报的自定义帖子类型。我希望编辑器用户能够拥有发布和编辑警报的完全权限。我复制了管理员的所有功能以满足此要求。然而,拥有自定义帖子类型的所有功能已经删除了发布权限,这是出乎意料的。这是我的自定义帖子类型配置。删除发布和编辑警报的功能是我做错了什么?
register_post_type(\'alert\', array(
\'label\' => \'Alerts\',
\'public\' => true,
\'capability_type\' => \'alert\',
\'capabilities\' => array(
\'delete_others_pages\' => \'delete_others_pages\',
\'delete_others_posts\' => \'delete_others_posts\',
\'delete_pages\' => \'delete_pages\',
\'delete_posts\' => \'delete_posts\',
\'delete_private_pages\' => \'delete_private_pages\',
\'delete_private_posts\' => \'delete_private_posts\',
\'delete_published_pages\' => \'delete_published_pages\',
\'delete_published_posts\' => \'delete_published_posts\',
\'edit_others_pages\' => \'edit_others_pages\',
\'edit_others_posts\' => \'edit_others_posts\',
\'edit_pages\' => \'edit_pages\',
\'edit_posts\' => \'edit_posts\',
\'edit_private_pages\' => \'edit_private_pages\',
\'edit_private_posts\' => \'edit_private_posts\',
\'edit_published_pages\' => \'edit_published_pages\',
\'edit_published_posts\' => \'edit_published_posts\',
\'publish_pages\' => \'publish_pages\',
\'publish_posts\' => \'publish_posts\',
\'read_private_pages\' => \'read_private_pages\',
\'read_private_posts\' => \'read_private_posts\',
\'read\' => \'read\',
\'activate_plugins\' => \'activate_plugins\',
\'edit_dashboard\' => \'edit_dashboard\',
\'edit_theme_options\' => \'edit_theme_options\',
\'export\' => \'export\',
\'import\' => \'import\',
\'list_users\' => \'list_users\',
\'manage_categories\' => \'manage_categories\',
\'manage_links\' => \'manage_links\',
\'manage_options\' => \'manage_options\',
\'moderate_comments\' => \'moderate_comments\',
\'promote_users\' => \'promote_users\',
\'remove_users\' => \'remove_users\',
\'switch_themes\' => \'switch_themes\',
\'upload_files\' => \'upload_files\',
\'customize\' => \'customize\',
\'delete_site\' => \'delete_site\'
)
));