This commit is contained in:
Yurii Nalivaiko
2018-11-01 12:16:35 +02:00
34 changed files with 913 additions and 690 deletions
+26
View File
@@ -525,6 +525,7 @@ if ( ! class_exists( 'UM' ) ) {
if ( $this->is_request( 'ajax' ) ) {
$this->admin();
$this->ajax_init();
$this->admin_ajax_hooks();
$this->metabox();
$this->admin_upgrade()->init_packages_ajax_handlers();
$this->admin_gdpr();
@@ -638,6 +639,17 @@ if ( ! class_exists( 'UM' ) ) {
}
/**
* @since 2.0.30
*/
function admin_ajax_hooks() {
if ( empty( $this->classes['admin_ajax_hooks'] ) ) {
$this->classes['admin_ajax_hooks'] = new um\admin\core\Admin_Ajax_Hooks();
}
return $this->classes['admin_ajax_hooks'];
}
/**
* @since 2.0
*
@@ -1313,6 +1325,20 @@ if ( ! class_exists( 'UM' ) ) {
}
/**
* @since 2.0
*
* @return um\core\Templates
*/
function templates() {
if ( empty( $this->classes['templates'] ) ) {
$this->classes['templates'] = new um\core\Templates();
}
return $this->classes['templates'];
}
/**
* @since 2.0
*