Class Sensei_Core_Modules
Sensei Modules Class
Sensei Module Functionality
public
|
|
public
|
#
change_module_term_slug( $term_id, $tt_id, $taxonomy )
Alter a module term slug when a new taxonomy term is created This will add the creators user name to the slug for uniqueness. |
public
|
#
modules_metaboxes( string $post_type, WP_Post $post )
Hook in all meta boxes related tot he modules taxonomy |
public
|
|
public
mixed
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
string
|
#
module_archive_template( string $template )
Set lesson archive template to display on module taxonomy archive page |
public
|
|
public
string
|
|
public
|
|
public
|
|
public
|
|
public
|
#
update_lesson_status_module_progress( string $status = '', integer $user_id = 0, integer $lesson_id = 0 )
Trigger save_lesson_module_progress() when a lesson status is updated for a specific user |
public
|
#
save_lesson_module_progress( integer $user_id = 0, integer $lesson_id = 0 )
Save lesson's module progress for a specific user |
public
|
|
public
|
#
save_user_module_progress( integer $module_id = 0, integer $course_id = 0, integer $user_id = 0 )
Save module progess for user |
public
mixed
|
#
get_user_module_progress( integer $module_id = 0, integer $course_id = 0, integer $user_id = 0 )
Get module progress for a user |
public
integer
|
#
calculate_user_module_progress( integer $user_id = 0, integer $module_id = 0, integer $course_id = 0 )
Calculate module progess for user |
public
|
|
public
|
|
public
array
|
|
public
|
#
course_column_content( string $column = '', integer $course_id = 0 )
Load content in 'Module order' column |
public
mixed
|
|
public
array
|
|
public
string
|
#
taxonomy_column_content( string $column_data, string $column_name, integer $term_id )
Manage content in custom module taxonomy columns |
public
array
|
#
analysis_overview_column_title( array $columns )
Add 'Module' columns to Analysis Lesson Overview table |
public
array
|
#
analysis_overview_column_data( array $columns, WP_Post $lesson )
Data for 'Module' column Analysis Lesson Overview table |
public
array
|
|
public
array
|
#
analysis_course_column_data( array $columns, WP_Post $lesson )
Data for 'Module' column in Analysis Course table |
public
object
|
|
public
array
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
#
load_course_module_content_template( )
Display the single course modules content this will only show if the course has modules. |
public
array
|
|
public
WP_Query
|
|
public
array
|
#
get_none_module_lessons( $course_id )
Find the lesson in the given course that doesn't belong to any of the courses modules |
public
|
|
public
|
#
redirect_to_lesson_module_taxonomy_to_course( )
When the wants to edit the lesson modules redirect them to the course modules. |
public
|
|
public
|
|
public static
array
|
#
get_term_authors( string $term_name )
Determine the author of a module term term by looking at the prefixed author id. This function will query the full term object. Will return the admin user author could not be determined. |
public static
WP_User
|
#
get_term_author( $slug = '' )
Looks at a term slug and figures out which author created the slug. The author was appended when the user saved the module term in the course edit screen. |
public
|
|
public static
|
|
public
|
#
filter_module_terms( $terms, $taxonomies, $args )
Limit the course module metabox term list to only those on courses belonging to current teacher. |
public
|
#
filter_course_selected_terms( $terms, $course_ids_array, $taxonomies )
For the selected items on a course module only return those for the current user. This does not apply to admin and super admin users. |
public
array
|
#
filter_terms_by_owner( $terms, $user_id )
Filter the given terms and only return the terms that belong to the given user id. |
public
|
#
append_teacher_name_to_module( $terms, $taxonomies, $args )
Add the teacher name next to modules. Only works in Admin for Admin users. This will not add name to terms belonging to admin user. |
public static
|
#
remove_default_modules_box( )
Remove modules metabox that come by default with the modules taxonomy. We are removing this as we have created our own custom meta box. |
public static
|
#
reset_none_modules_transient( $post_id )
When a course is save make sure to reset the transient set for it when determining the none module lessons. |
public static
|
#
deprecate_sensei_single_course_modules_content( )
This function calls the deprecated hook 'sensei_single_course_modules_content' to fire |
public static
|
|
public static
|
public
|
$taxonomy
|