#661 Allow LPInstructor user to include others lessons in his course
Viewing 6 reply threads
-
AuthorPosts
-
-
April 24, 2024 at 11:05 PM #972078ADAGEParticipant
Hi,
I wonder what permission I can edit with Members plugin, or what PHP hook I may use, in order to Allow LPInstructor user to include others lessons in his course?
Indeed I got a “nothing found” result when trying to associate existing lessons with a new user: https://prnt.sc/WSeW6tDVF9qM
I need him to be able to add others’ lessons in his course.
Thank you. -
April 25, 2024 at 8:58 AM #972130GraceModeratorThis reply has been marked as private.
-
April 25, 2024 at 4:52 PM #972246ADAGEParticipantThis reply has been marked as private.
-
April 25, 2024 at 4:58 PM #972248ADAGEParticipant
function custom_lp_modal_search_items_context_id($context_id, $context) { if (user_can(get_current_user_id(), 'lp_teacher') && $context === 'course-items') { $context_id = false; } return $context_id; } add_filter('learn-press/modal-search-items/context-id', 'custom_lp_modal_search_items_context_id', 10, 2); function custom_lp_modal_search_items_args($args, $context, $context_id) { if (user_can(get_current_user_id(), 'lp_teacher') && $context === 'course-items') { unset($args['author']); } return $args; } add_filter('learn-press/modal-search-items/args', 'custom_lp_modal_search_items_args', 10, 3);
Hello,
I tried this with no success.
Please note I added those to my functions.php
Thank you. -
April 26, 2024 at 10:07 AM #972400GraceModeratorThis reply has been marked as private.
-
April 26, 2024 at 5:19 PM #972511ADAGEParticipant
Working great, thank you very much!
-
May 2, 2024 at 5:27 PM #973309JuliaKeymasterThis reply has been marked as private.
-
-
AuthorPosts
Viewing 6 reply threads
You must be logged in to reply to this topic. You can click here