feat(01-03): register ddhh_provider role with restricted capabilities
- Add DDHH_JM_Roles class with add_roles() and remove_roles() methods - Role 'ddhh_provider' (Anbieter) can edit/delete own job_offers only - Jobs go to pending status (publish_job_offers: false) - No access to regular posts/pages (edit_posts/edit_pages: false) - Can upload files for logos - Integrated with Activator and Deactivator hooks
This commit is contained in:
@@ -30,6 +30,9 @@ class DDHH_JM_Activator {
|
||||
// Store plugin version
|
||||
update_option( 'ddhh_jm_version', DDHH_JM_VERSION );
|
||||
|
||||
// Register custom roles
|
||||
DDHH_JM_Roles::add_roles();
|
||||
|
||||
// Set flag to flush rewrite rules on next init
|
||||
set_transient( 'ddhh_jm_flush_rewrite_rules', 1, 60 );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user