diff options
author | yehudah <yehudah@b8457f37-d9ea-0310-8a92-e5e31aec5664> | 2019-11-25 09:25:43 +0000 |
---|---|---|
committer | yehudah <yehudah@b8457f37-d9ea-0310-8a92-e5e31aec5664> | 2019-11-25 09:25:43 +0000 |
commit | b5fd728e37aa2a9c7a5f37e8dead0a95117d541b (patch) | |
tree | a7158edc5e4e576e0377f078dabc87c699315c62 /Postman/Extensions/Admin/PostmanAdmin.php | |
parent | c61784411988d36d9bbd93cd3a97e773990af342 (diff) | |
download | Post-SMTP-b5fd728e37aa2a9c7a5f37e8dead0a95117d541b.zip |
phpmailer delivery improvments
bug fixes
add option to disable notifications
fix Invalid “Reply-To” e-mail address
Diffstat (limited to 'Postman/Extensions/Admin/PostmanAdmin.php')
-rw-r--r-- | Postman/Extensions/Admin/PostmanAdmin.php | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/Postman/Extensions/Admin/PostmanAdmin.php b/Postman/Extensions/Admin/PostmanAdmin.php new file mode 100644 index 0000000..3b61a0a --- /dev/null +++ b/Postman/Extensions/Admin/PostmanAdmin.php @@ -0,0 +1,31 @@ +<?php +if ( ! defined( 'ABSPATH' ) ) exit; + +class PostmanAdmin { + + public function __construct() + { + $PostmanLicenseManager = PostmanLicenseManager::get_instance(); + $extensions = $PostmanLicenseManager->get_extensions(); + + if ( count( $extensions ) > 0 ) { + add_action('admin_menu', [ $this, 'add_menu' ], 20 ); + } + + } + + public function add_menu() { + add_submenu_page( + PostmanViewController::POSTMAN_MENU_SLUG, + __('Extensions', 'post-smtp'), + __('Extensions', 'post-smtp'), + 'manage_options', + 'post-smtp-extensions', + [ $this, 'render_menu' ] + ); + } + + public function render_menu() { + include_once 'PostmanAdminView.php'; + } +} |