Skip to content Skip to main navigation Skip to footer

User Capabilities

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #3025
    Kay AtkinsonKay Atkinson
    Participant

    If I want to create a security role for a user for managing the Quizzes and Surveys, which capabilities do I need to give the role in order to perform all quizzes and survey functions?

    #3061
    Kriti SharmaKriti Sharma
    Keymaster

    Hi Kay,

    Welcome to QSM Pro support Forum. Hope you are having a great day.

    I need to talk to the development team regarding this issue. Please expect a little delay as it is weekend over here.

    Regards,
    Kriti

    #3084
    Kriti SharmaKriti Sharma
    Keymaster

    As of QSM 6.4.6 a user having role of “Editor” or “Author” can manage the quizz.
    A user having role of “Author” can only manage the quizzes created by themselves. Whereas a user having a role of “Editor” can manage all quizzes.If you are creating a custom role, you can assign the capabilties corresponding to one of these roles as per your requirements.
    Example:
    For “Editor’ level custom role you can assign {capability_name}
    For “Admin’ level custom role you can assign {capability_name}
    Here is a sample code snippet for the same

    function xx__update_custom_roles() {
    if ( get_option( ‘custom_roles_version’ ) < 1 ) {
    add_role( ‘custom_role’, ‘Custom Subscriber’, get_role( ‘editor’ )->capabilities );
    update_option( ‘custom_roles_version’, 1 );
    }
    if ( get_option( ‘custom_roles_author_version’ ) < 1 ) {
    add_role( ‘custom_author’, ‘Custom Author’, get_role( ‘author’ )->capabilities );
    update_option( ‘custom_roles_author_version’, 1 );
    }
    }
    add_action( ‘init’, ‘xx__update_custom_roles’ );

    #5711
    Maria RichardsonMaria Richardson
    Participant

    This capability allows the user to create new quizzes or uno online surveys. Edit Quizzes/Surveys: This capability enables the user to modify existing quizzes or surveys, such as changing questions, options, or settings.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.