| 1 |
<?php |
| 2 |
|
| 3 |
/** |
| 4 |
* Class LP_Submenu_Statistics |
| 5 |
* |
| 6 |
* @since 4.2.5.5 |
| 7 |
* @author khanhbd |
| 8 |
*/ |
| 9 |
class LP_Submenu_Statistics extends LP_Abstract_Submenu { |
| 10 |
/** |
| 11 |
* LP_Submenu_Statistics_Beta constructor. |
| 12 |
*/ |
| 13 |
public function __construct() { |
| 14 |
$this->id = 'learn-press-statistics'; |
| 15 |
$this->menu_title = __( 'Statistics', 'learnpress' ); |
| 16 |
$this->page_title = __( 'LearnPress Statistics', 'learnpress' ); |
| 17 |
$this->priority = 10; |
| 18 |
$this->callback = [ $this, 'display' ]; |
| 19 |
$tabs = array( |
| 20 |
'overview' => __( 'Overview', 'learnpress' ), |
| 21 |
'orders' => __( 'Orders', 'learnpress' ), |
| 22 |
'courses' => __( 'Courses', 'learnpress' ), |
| 23 |
'users' => __( 'Users', 'learnpress' ), |
| 24 |
); |
| 25 |
$this->tabs = apply_filters( |
| 26 |
'learn-press/admin/page-statistic-tabs', |
| 27 |
$tabs |
| 28 |
); |
| 29 |
|
| 30 |
//add_action( 'admin_enqueue_scripts', array( $this, 'scripts' ) ); |
| 31 |
|
| 32 |
parent::__construct(); |
| 33 |
} |
| 34 |
|
| 35 |
public function page_content_courses() { |
| 36 |
learn_press_admin_view( 'statistics/courses' ); |
| 37 |
} |
| 38 |
|
| 39 |
public function page_content_overview() { |
| 40 |
learn_press_admin_view( 'statistics/overview' ); |
| 41 |
} |
| 42 |
|
| 43 |
public function page_content_users() { |
| 44 |
learn_press_admin_view( 'statistics/users' ); |
| 45 |
} |
| 46 |
|
| 47 |
public function page_content_orders() { |
| 48 |
learn_press_admin_view( 'statistics/orders' ); |
| 49 |
} |
| 50 |
} |
| 51 |
|
| 52 |
return new LP_Submenu_Statistics(); |
| 53 |
|