v1.7.0
This commit is contained in:
parent
98b1cf0f3b
commit
4402f3570d
20 changed files with 1683 additions and 382 deletions
|
|
@ -7,6 +7,7 @@
|
|||
|
||||
namespace MediaRightsAudit\Core;
|
||||
|
||||
use MediaRightsAudit\Admin\AlertsPage;
|
||||
use MediaRightsAudit\Admin\AttachmentDetailPage;
|
||||
use MediaRightsAudit\Admin\AuditPage;
|
||||
use MediaRightsAudit\Admin\Settings;
|
||||
|
|
@ -27,6 +28,13 @@ use MediaRightsAudit\Privacy\DataExporter;
|
|||
*/
|
||||
class Plugin {
|
||||
|
||||
/**
|
||||
* Alerts page controller.
|
||||
*
|
||||
* @var AlertsPage
|
||||
*/
|
||||
private AlertsPage $alerts_page;
|
||||
|
||||
/**
|
||||
* Settings page handler.
|
||||
*
|
||||
|
|
@ -59,6 +67,7 @@ class Plugin {
|
|||
* Initialises dependencies.
|
||||
*/
|
||||
public function __construct() {
|
||||
$this->alerts_page = new AlertsPage();
|
||||
$this->settings = new Settings();
|
||||
$this->audit_page = new AuditPage();
|
||||
$this->tools_page = new ToolsPage();
|
||||
|
|
@ -127,6 +136,19 @@ class Plugin {
|
|||
array( $this->audit_page, 'render' )
|
||||
);
|
||||
|
||||
$alerts_suffix = add_submenu_page(
|
||||
'robotstxt-mediaaudit',
|
||||
__( 'Alerts', 'robotstxt-mediaaudit' ),
|
||||
__( 'Alerts', 'robotstxt-mediaaudit' ),
|
||||
'edit_others_posts',
|
||||
'robotstxt-mediaaudit-alerts',
|
||||
array( $this->alerts_page, 'render' )
|
||||
);
|
||||
|
||||
if ( is_string( $alerts_suffix ) ) {
|
||||
$this->alerts_page->set_hook_suffix( $alerts_suffix );
|
||||
}
|
||||
|
||||
$tools_suffix = add_submenu_page(
|
||||
'robotstxt-mediaaudit',
|
||||
__( 'Tools', 'robotstxt-mediaaudit' ),
|
||||
|
|
|
|||
Loading…
Reference in a new issue