tools
5 years ago
add_new_instructor.php
5 years ago
addons.php
5 years ago
announcements.php
4 years ago
answer.php
4 years ago
enable_disable_addons.php
4 years ago
get-pro.php
5 years ago
instructors.php
4 years ago
question_answer.php
4 years ago
quiz_attempts.php
4 years ago
students.php
4 years ago
tools.php
5 years ago
tutor-pro-addons.php
5 years ago
uninstall.php
4 years ago
view_attempt.php
4 years ago
withdraw_requests.php
4 years ago
instructors.php
48 lines
| 1 | <?php |
| 2 | |
| 3 | $allowed_sub_pages = array( 'add_new_instructor' ); |
| 4 | $sub_page = sanitize_text_field( tutor_utils()->array_get('sub_page', $_GET, '') ); |
| 5 | |
| 6 | if ( is_string( $sub_page ) && in_array($sub_page, $allowed_sub_pages)){ |
| 7 | $include_file = tutor()->path."views/pages/{$sub_page}.php"; |
| 8 | if (file_exists($include_file)){ |
| 9 | include $include_file; |
| 10 | return; |
| 11 | } |
| 12 | } |
| 13 | /** |
| 14 | * Quiz attempt filters added |
| 15 | * |
| 16 | * @since 1.9.7 |
| 17 | */ |
| 18 | $search_filter = isset( $_GET['search'] ) ? $_GET['search'] : ''; |
| 19 | $course_filter = isset( $_GET['course-id'] ) ? $_GET['course-id'] : ''; |
| 20 | $date_filter = isset( $_GET['date'] ) ? $_GET['date'] : ''; |
| 21 | $order_filter = isset( $_GET['order'] ) ? $_GET['order'] : "ASC"; |
| 22 | |
| 23 | $instructorList = new \TUTOR\Instructors_List(); |
| 24 | $instructorList->prepare_items($search_filter, $course_filter, $date_filter,$order_filter); |
| 25 | ?> |
| 26 | |
| 27 | |
| 28 | <div class="wrap"> |
| 29 | <h1 class="wp-heading-inline"><?php _e('Instructors', 'tutor'); ?></h1> |
| 30 | <?php |
| 31 | if(get_option( 'users_can_register', false ) && current_user_can( 'manage_options' )) { |
| 32 | ?> |
| 33 | <a href="<?php echo add_query_arg(array('sub_page' => 'add_new_instructor')); ?>" class="page-title-action"> |
| 34 | <i class="tutor-icon-plus"></i> <?php _e('Add New Instructor', 'tutor'); ?> |
| 35 | </a> |
| 36 | <?php |
| 37 | } |
| 38 | ?> |
| 39 | <hr class="wp-header-end"> |
| 40 | |
| 41 | <form id="students-filter" method="get"> |
| 42 | <input type="hidden" name="page" value="<?php echo \TUTOR\Instructors_List::INSTRUCTOR_LIST_PAGE; ?>" /> |
| 43 | <?php |
| 44 | //$instructorList->search_box(__('Search', 'tutor'), 'instructors'); |
| 45 | $instructorList->display($enable_sorting_field_with_bulk_action = true); |
| 46 | ?> |
| 47 | </form> |
| 48 | </div> |