<?php
/**
 * @package embed-sharepoint-onedrive-documents
 * @author miniOrange
 * @link https://plugins.miniorange.com
 */


namespace MoSharePointObjectSync\LicenseLibrary\Views;

use MoSharePointObjectSync\LicenseLibrary\Classes\Mo_License_Constants;
use MoSharePointObjectSync\LicenseLibrary\Classes\Mo_License_Dao;
use MoSharePointObjectSync\LicenseLibrary\Mo_License_Config;
use MoSharePointObjectSync\LicenseLibrary\Mo_License_Service;
use MoSharePointObjectSync\LicenseLibrary\Utils\Mo_License_View_Utility;
if (defined("\101\102\123\x50\x41\x54\110")) {
    goto lz;
}
exit;
lz:
class Mo_License_Notice_Views
{
    protected $expiry_date;
    protected $remaining_days;
    protected $content_options;
    private function get_content_options()
    {
        $d6 = Mo_License_Service::get_expiry_date();
        $Mw = array("\43\43\x65\x78\x70\x69\x72\x79\x5f\144\x61\x74\145\43\43" => $d6, "\43\43\162\145\x6d\141\x69\156\151\156\x67\x5f\144\x61\x79\x73\x23\x23" => Mo_License_Service::get_expiry_remaining_days($d6), "\x23\43\x64\x69\x73\141\x62\154\x65\137\x64\141\x74\145\43\x23" => Mo_License_Service::get_disable_date($d6), "\x23\43\x67\x72\141\x63\145\x5f\x64\x61\171\x73\x5f\154\145\146\164\43\x23" => Mo_License_Service::get_grace_days_left($d6), "\43\x23\143\165\x73\x74\x6f\155\145\162\x5f\145\155\x61\151\154\x23\x23" => Mo_License_Dao::mo_get_option(Mo_License_Config::CUSTOMER_EMAIL_OPTION));
        if (empty(Mo_License_Config::$notice_options)) {
            goto Em;
        }
        foreach (Mo_License_Config::$notice_options as $Oz => $Zg) {
            $Mw["\43\x23" . $Oz . "\43\43"] = Mo_License_Dao::mo_get_option($Zg);
            HK:
        }
        UK:
        Em:
        return $Mw;
    }
    public function get_license_notice()
    {
        $F4 = '';
        $Dv = $this->get_content_options();
        if (Mo_License_Constants::EPOCH_DATE === $Dv["\43\43\x65\x78\x70\x69\x72\x79\137\x64\141\x74\145\x23\43"]) {
            goto pP;
        }
        if (Mo_License_View_Utility::show_expiry_notice($Dv["\x23\x23\x72\x65\x6d\x61\x69\x6e\151\x6e\147\137\x64\141\171\x73\43\43"])) {
            goto V2;
        }
        goto Df;
        pP:
        $F4 = $this->get_tampered_license_notice();
        goto Df;
        V2:
        $F4 = $this->get_expired_license_notice();
        Df:
        return $F4;
    }
    public function display_dashboard_widget()
    {
        $Dv = $this->get_content_options();
        $P8 = Mo_License_View_Utility::get_widget_notice($Dv);
        $Qw = "\15\xa\11\x9\74\x64\151\166\x20\x63\154\141\x73\163\x3d\42\x6d\157\x2d\154\x69\x63\55\x64\141\163\150\142\157\141\162\144\x2d\x77\151\x64\x67\145\164\42\76\15\xa\11\x9\x9\x3c\x64\x69\166\40\163\x74\171\154\x65\75\x22\167\x69\144\164\x68\x3a\61\x32\45\42\x3e\15\xa\x9\11\11\40\40\40\x20\x3c\151\155\x67\40\163\162\x63\75\42" . esc_attr(plugins_url("\166\x69\145\167\x73\134\x69\156\143\x6c\165\144\145\163\x5c\151\x6d\141\x67\145\163\x5c\155\x69\x6e\x69\x6f\x72\x61\x6e\x67\x65\55\x6c\x6f\x67\157\56\160\156\x67", dirname(__FILE__))) . "\42\40\x61\154\x74\75\x22\x6d\x69\x6e\151\117\162\141\156\x67\145\x20\114\x6f\147\157\x22\x20\167\151\x64\x74\x68\75\x22\x35\60\x70\x78\x22\x2f\x3e\15\12\x9\x9\x9\74\57\x64\151\x76\76\15\12\x9\x9\11\x3c\x64\x69\x76\40\x73\164\x79\154\145\75\x22\x77\151\144\x74\x68\x3a\40\70\x35\45\73\146\157\156\x74\x2d\163\151\172\x65\72\40\61\x2e\x35\x65\x6d\x3b\42\x3e" . Mo_License_Config::PLUGIN_NAME . "\74\x2f\144\x69\166\76\xd\12\11\x9\74\57\x64\x69\x76\x3e";
        if (empty($P8)) {
            goto yn;
        }
        $Qw .= "\15\12\40\40\x20\x20\x20\x20\40\x20\40\x20\40\x20\x3c\144\151\x76\40\x63\x6c\x61\163\x73\x3d\x22\155\x6f\x2d\x6c\151\x63\55\x77\151\x64\147\x65\164\x2d\143\157\156\164\x61\151\156\x65\162\42\76\xd\12\x9\x9\11\x20\x20\x20\x20\74\x70\40\x63\x6c\141\163\163\x3d\x22\x6d\x6f\55\x6c\151\x63\x2d\167\151\x64\147\145\164\55\164\x65\x78\x74\42\76" . $P8 . "\x3c\57\160\x3e\15\xa\11\x9\40\40\x20\40\x3c\57\x64\151\x76\x3e";
        yn:
        $Qw .= "\15\12\40\40\40\40\40\x20\x20\x20\x3c\x64\x69\x76\40\x73\164\171\154\145\x3d\x22\x74\145\x78\164\55\141\154\x69\147\x6e\x3a\143\x65\156\164\x65\x72\42\76\15\xa\11\11\11\74\164\x61\142\x6c\x65\x20\143\154\141\x73\x73\x3d\x22\155\157\x2d\x6c\x69\x63\x2d\x77\151\x64\147\x65\x74\55\x74\x61\142\154\145\42\x3e\15\xa\11\x9\11\11\x3c\164\162\76\15\12\x9\11\11\11\11\x3c\x74\144\x20\x63\154\141\x73\x73\x3d\42\x6d\157\x2d\x6c\x69\143\55\x77\x69\x64\x67\145\x74\55\x74\x61\x62\154\x65\55\164\145\x78\x74\55\x63\x6f\x6c\x31\x22\x3e\74\142\76\155\151\156\x69\x4f\162\x61\156\147\x65\x20\101\x63\x63\x6f\x75\x6e\x74\x20\105\155\141\151\x6c\x3c\57\x62\76\74\57\x74\x64\x3e\xd\xa\x9\11\x9\11\x9\74\x74\x64\40\x63\154\x61\x73\x73\75\x22\x6d\x6f\x2d\x6c\x69\143\x2d\x77\x69\144\147\x65\x74\x2d\x74\141\x62\x6c\145\x2d\x74\x65\170\x74\x2d\143\x6f\154\x32\x22\x3e" . esc_html($Dv["\x23\x23\x63\x75\x73\164\157\155\145\x72\x5f\x65\155\x61\x69\x6c\43\x23"]) . "\x3c\x2f\164\144\x3e\15\xa\11\x9\x9\11\x3c\57\164\x72\76\xd\xa\x9\11\11\11\74\164\x72\x3e\15\xa\x9\11\x9\x9\11\x3c\164\144\x20\143\x6c\141\163\163\x3d\x22\x6d\x6f\x2d\x6c\151\x63\x2d\x77\151\x64\147\145\x74\x2d\164\x61\142\154\145\x2d\x74\x65\170\164\x2d\143\x6f\154\x31\42\x3e\x3c\142\x3e\x50\154\165\147\x69\x6e\x20\x4c\151\x63\145\156\163\145\x20\x45\170\x70\151\x72\x79\40\104\141\164\145\74\x2f\142\76\x3c\x2f\164\144\76\xd\12\x9\11\11\x9\11\74\x74\x64\40\x63\154\x61\163\x73\x3d\x22\x6d\157\55\x6c\x69\143\55\x77\x69\x64\x67\145\164\55\164\x61\142\154\145\x2d\x74\145\x78\x74\55\143\157\x6c\x32\x22\76\xd\xa\x9\11\x9\11\11\40\40\x20\x20\x3c\x66\157\x72\x6d\40\x6e\x61\x6d\145\75\x22\x6d\157\137\163\x61\x6d\x6c\137\x72\145\x66\x72\145\x73\x68\137\145\170\160\151\x72\171\42\x20\151\144\75\x22" . Mo_License_Constants::DASHBOARD_WIDGET_REFRESH_ID . "\x22\40\155\145\164\150\x6f\x64\75\42\120\117\123\124\42\76\15\xa\40\x20\40\x20\40\40\x20\40\x20\x20\40\40\40\40\x20\40\40\40\40\x20\x20\40\40\40\x20\40\x20\40" . wp_nonce_field(Mo_License_Constants::DASHBOARD_WIDGET_REFRESH_ID) . "\xd\xa\40\x20\40\40\40\x20\40\x20\x20\40\40\40\x20\x20\40\x20\x20\40\x20\x20\40\40\40\40\40\40\40\40\x3c\151\156\x70\165\164\40\164\171\160\145\75\42\150\x69\144\x64\145\x6e\x22\x20\x6e\141\155\145\x3d\42\157\160\x74\x69\157\x6e\x22\40\x76\x61\154\x75\x65\75\x22" . Mo_License_Constants::DASHBOARD_WIDGET_REFRESH_ID . "\x22\76\15\12\x20\40\40\x20\40\40\x20\x20\x20\40\x20\x20\x20\x20\x20\40\x20\40\x20\40\x20\x20\40\40\40\40\40\40\74\142\x3e\40" . esc_html($Dv["\43\43\145\170\160\x69\x72\x79\137\144\141\x74\x65\43\x23"]) . "\40\x3c\x2f\142\76\15\12\x20\x20\x20\40\x20\x20\x20\40\x20\x20\40\40\40\40\x20\40\40\40\40\40\x20\40\40\x20\40\40\40\x20\74\x62\165\164\164\157\x6e\40\x74\x79\x70\x65\x3d\x22\x73\165\x62\x6d\x69\x74\x22\x20\x63\154\x61\x73\163\x3d\42\155\x6f\55\x6c\151\x63\x2d\167\151\144\x67\145\x74\55\162\145\146\x72\x65\163\x68\42\76\46\43\170\62\61\142\142\x3b\74\x2f\x62\165\164\164\x6f\x6e\76\xd\12\x20\x20\x20\40\x20\x20\40\40\40\40\40\40\x20\40\40\40\40\40\40\40\40\x20\x20\40\74\57\146\x6f\x72\155\76\xd\12\11\11\11\11\x9\40\40\x20\x20\xd\12\11\x9\x9\11\11\74\57\164\144\x3e\xd\12\x9\x9\11\x9\x3c\57\x74\162\76\xd\12\x9\x9\11\x3c\57\164\x61\x62\154\x65\76\15\12\x9\11\74\57\x64\x69\166\76\xd\xa\11\11\74\144\151\166\x20\x63\x6c\141\x73\x73\75\42\x6d\x6f\55\154\x69\143\55\x77\x69\x64\147\x65\x74\55\x73\165\x70\160\x6f\162\164\x2d\x6c\x69\x6e\153\163\42\x3e\xd\xa\x20\40\40\x20\40\40\40\40\40\x20\x20\x20\x3c\144\x69\166\76\15\12\40\x20\x20\x20\x20\40\x20\40\x20\x20\40\40\x20\x20\x20\x20\x3c\x61\x20\150\x72\145\x66\75\x22\x61\x64\155\x69\x6e\x2e\160\150\x70\x3f\160\141\147\145\x3d" . esc_attr(Mo_License_Config::PLUGIN_SLUG) . "\42\40\163\164\x79\154\145\75\42\143\157\154\157\x72\x3a\167\150\x69\164\x65\73\x22\76\xd\12\40\40\x20\x20\40\x20\40\x20\x20\40\x20\x20\40\x20\40\40\74\142\x75\164\x74\157\x6e\40\x63\x6c\141\163\x73\75\x22\142\165\x74\x74\x6f\156\x20\x62\x75\x74\x74\x6f\x6e\55\x70\162\x69\x6d\x61\162\171\x20\142\165\164\164\157\x6e\55\154\x61\x72\147\145\42\76\x3c\x62\x3e\x47\157\40\x74\x6f\x20\x70\154\165\x67\x69\156\40\163\145\x74\164\151\156\147\163\x3c\x2f\142\76\74\x2f\142\165\x74\x74\x6f\x6e\x3e\xd\12\40\x20\x20\40\x20\x20\40\x20\x20\40\40\x20\40\x20\40\x20\74\57\141\76\xd\12\x20\x20\40\x20\40\x20\x20\40\40\40\40\40\x3c\57\144\x69\166\76\15\12\x20\x20\x20\x20\40\x20\x20\x20\40\x20\40\x20\x3c\x64\151\x76\76\xd\xa\x20\x20\40\x20\x20\40\x20\x20\x20\x20\x20\x20\x20\40\40\x20\x4e\145\x65\x64\40\141\156\x79\40\x68\x65\154\x70\77\40\x43\x6f\156\164\x61\143\164\40\x75\163\x20\157\156\x20\15\12\40\40\40\40\x20\x20\40\x20\x20\40\40\40\x20\x20\40\40\74\141\x20\x68\162\145\x66\x3d\42\x6d\x61\151\x6c\164\x6f\x3a" . esc_attr(Mo_License_Config::SUPPORT_EMAIL) . "\42\76\15\12\x20\x20\x20\x20\x20\x20\40\40\x20\x20\x20\x20\x20\x20\40\x20\40\x20\40\x20\74\x62\76" . esc_html(Mo_License_Config::SUPPORT_EMAIL) . "\x3c\x2f\142\x3e\xd\xa\x20\40\40\x20\x20\x20\x20\x20\40\x20\x20\40\40\40\40\x20\74\57\x61\x3e\15\12\x20\40\40\40\x20\40\x20\40\x20\x20\x20\40\74\x2f\x64\151\166\76\15\xa\11\x9\x3c\x2f\x64\x69\166\76";
        echo $Qw;
    }
    private function get_tampered_license_notice()
    {
        $F4 = "\15\xa\11\11\11\x3c\x64\x69\x76\x20\163\x74\x79\154\145\x3d\x22\x64\x69\x73\x70\x6c\x61\171\x3a\146\x6c\145\170\x3b\42\40\143\x6c\x61\x73\163\75\42\156\157\x74\x69\x63\145\x20\156\x6f\x74\x69\143\x65\55\145\162\x72\157\162\x22\x3e\xd\xa\x20\40\x20\40\x20\x20\x20\40\40\x20\40\40\x20\40\x20\40\74\160\40\x63\x6c\x61\163\x73\x3d\x22\x6d\157\55\x6c\151\143\55\141\x64\155\151\156\55\x6e\x6f\164\x69\143\x65\x2d\x74\x65\170\x74\42\76\xd\12\x9\11\11\11\x9\x3c\x62\x3e\101\114\105\122\x54\72\x3c\x2f\x62\76\x20\x49\x74\40\163\145\x65\x6d\163\40\164\150\x61\x74\x20\x79\157\165\x72\x20\x3c\x62\76\74\x61\40\x68\x72\145\146\x3d\42\141\x64\x6d\151\x6e\56\160\150\160\77\x70\x61\147\145\75" . Mo_License_Config::PLUGIN_SLUG . "\42\x3e" . Mo_License_Config::PLUGIN_NAME . "\74\57\x61\76\x3c\57\142\76\40\154\151\x63\x65\156\163\x65\40\150\141\163\x20\x62\x65\x65\x6e\x20\xd\12\x9\x9\11\x9\11\164\x61\x6d\x70\x65\x72\145\144\x20\x61\156\x64\x20\x68\145\156\x63\x65\x20\164\x68\x65\40\160\154\165\x67\x69\156\40\x68\141\163\40\163\x74\x6f\x70\x70\145\144\x20\x77\157\x72\x6b\x69\156\147\56\74\142\x72\x3e\40" . $this->get_escaped_notice(Mo_License_Config::$tampered_notice_content) . "\xd\12\x9\11\x9\11\x3c\57\x70\x3e\15\xa\40\40\40\x20\x20\40\x20\x20\x20\40\40\40\x3c\x2f\x64\x69\166\x3e";
        return $F4;
    }
    private function get_expired_license_notice()
    {
        $Dv = $this->get_content_options();
        $aB = Mo_License_View_Utility::get_admin_notice_html(Mo_License_View_Utility::get_notice_day_key($Dv["\x23\43\x72\145\x6d\x61\151\156\151\156\x67\137\x64\141\x79\163\x23\x23"]), $Dv);
        $F4 = "\xd\xa\x20\x20\40\40\x20\40\x20\40\x20\40\40\40\x3c\144\151\x76\x20\x73\164\x79\154\x65\75\42\x64\151\163\x70\x6c\141\x79\x3a\x66\154\145\170\x3b\42\x20\x63\x6c\x61\163\163\x3d\x22\x6e\x6f\x74\x69\143\145\x20" . esc_attr(Mo_License_View_Utility::get_expiry_admin_notice_class($Dv["\43\x23\x72\145\155\141\x69\156\x69\x6e\147\137\144\141\x79\x73\x23\x23"])) . "\42\x3e\15\12\x20\x20\40\40\x20\x20\40\x20\40\x20\40\40\x20\x20\40\x20\x3c\144\151\166\76\xd\xa\x20\40\40\40\40\x20\x20\40\40\40\40\40\x20\x20\40\40\40\x20\40\40\x3c\151\155\x67\40\163\162\x63\x3d\42" . esc_attr(plugins_url("\x76\151\x65\x77\163\x5c\x69\x6e\143\154\x75\144\145\x73\134\x69\x6d\x61\147\x65\x73\x5c\155\151\x6e\x69\157\162\141\156\147\145\55\x6c\157\147\x6f\x2e\x70\x6e\x67", dirname(__FILE__))) . "\x22\x20\x63\x6c\x61\163\x73\x3d\42\x61\x6c\x69\x67\x6e\x6c\x65\146\x74\40\x6d\x6f\x2d\154\x69\x63\55\x61\144\x6d\151\156\55\x6e\157\x74\x69\x63\x65\42\x20\141\154\x74\x3d\42\x6d\x69\x6e\151\117\x72\x61\x6e\147\x65\x20\x6c\157\147\157\x22\x3e\15\xa\40\40\40\x20\x20\x20\40\40\x20\x20\x20\40\40\40\40\x20\74\x2f\144\151\166\x3e\xd\12\x20\40\x20\40\40\x20\x20\x20\40\x20\x20\40\40\x20\x20\x20\x3c\x64\x69\x76\x3e\15\12\x9\11\x9\11\11\x3c\144\151\166\x20\x63\154\x61\x73\163\x3d\x22\141\154\x69\x67\156\162\151\x67\x68\164\42\40\x73\164\x79\154\145\x3d\x22\x70\x61\144\144\x69\156\x67\x2d\x74\x6f\x70\72\40\61\62\x70\170\x3b\x22\76\xd\xa\11\x9\x9\x9\11\11\x3c\141\x20\150\162\145\146\75\42\x61\x64\155\x69\156\56\x70\150\160\77\160\141\147\145\x3d" . esc_attr(Mo_License_Config::PLUGIN_SLUG) . "\42\x3e\15\12\11\11\x9\x9\x9\11\x20\40\x20\x20\x3c\142\165\x74\164\x6f\156\40\x63\154\141\x73\x73\x3d\x22\x62\x75\x74\x74\157\x6e\40\x62\165\164\x74\157\x6e\55\160\x72\x69\155\141\162\x79\x22\40\x74\x79\160\145\75\x22\142\x75\164\x74\x6f\156\42\x3e\x47\x6f\x20\164\157\40\x50\x6c\x75\x67\x69\x6e\x20\x53\145\164\x74\151\156\x67\163\x3c\x2f\x62\165\164\x74\x6f\x6e\76\15\12\x9\11\x9\11\11\x9\x3c\x2f\141\76\15\12\x9\x9\11\x9\11\74\x2f\144\151\x76\76\15\xa\x9\x9\x9\x9\x9\74\150\62\x20\x63\154\x61\x73\163\75\42\x6d\157\x2d\154\151\143\x2d\x61\x64\155\x69\x6e\x2d\156\x6f\164\151\143\145\x2d\x68\x65\141\144\x69\x6e\147\x22\x3e" . esc_html($aB["\150\x65\141\144\151\156\147"]) . "\74\x2f\150\x32\76\xd\12\11\x9\11\x9\x9\74\x64\151\x76\x20\x63\154\x61\163\163\x3d\42\x61\x6c\x69\x67\156\154\x65\146\164\42\76" . $aB["\143\x6f\x6e\x74\x65\156\164"];
        if (!($Dv["\x23\43\162\145\155\141\151\x6e\151\x6e\x67\137\x64\x61\x79\163\43\43"] > 10)) {
            goto cp;
        }
        $F4 .= "\15\xa\11\x9\x9\x9\x9\x9\x3c\x66\x6f\162\155\40\155\145\164\x68\x6f\144\x3d\x22\160\157\x73\x74\42\40\x6e\141\155\145\x3d\x22\x22\x20\141\143\164\151\157\x6e\x3d\42\42\x20\x69\144\x3d\x22" . Mo_License_Constants::ADMIN_NOTICE_DISMISS_ID . "\42\76\40" . wp_nonce_field(Mo_License_Constants::ADMIN_NOTICE_DISMISS_ID) . "\x20\xd\12\x9\11\x9\x9\x9\x9\11\74\x69\156\x70\x75\x74\x20\x74\x79\x70\x65\75\42\150\151\x64\x64\x65\156\42\x20\156\141\x6d\x65\x3d\x22\x6f\160\164\151\x6f\156\42\40\166\x61\x6c\x75\x65\75\42" . Mo_License_Constants::ADMIN_NOTICE_DISMISS_ID . "\x22\x2f\x3e\15\12\x20\40\x20\x20\x20\40\40\x20\40\x20\40\x20\x20\40\x20\40\x20\x20\x20\40\40\x20\40\x20\11\74\151\156\160\165\164\40\164\x79\x70\145\75\42\x73\165\142\x6d\x69\164\x22\x20\x76\141\154\165\145\75\x22\104\x69\163\x6d\x69\x73\163\x22\40\151\x64\x3d\x22" . Mo_License_Constants::ADMIN_NOTICE_DISMISS_ID . "\x22\40\143\x6c\x61\163\163\x3d\x22\x61\154\x69\x67\x6e\x72\151\x67\150\164\40\142\165\x74\x74\x6f\156\40\x62\165\164\x74\x6f\156\55\154\x69\156\x6b\42\40\57\x3e\xd\12\11\x9\11\11\11\11\x9\74\144\151\x76\x20\x63\154\x61\x73\x73\x3d\42\143\154\x65\141\162\x22\x3e\74\57\x64\x69\x76\x3e\xd\xa\x9\x9\11\11\x9\11\74\57\146\x6f\x72\155\x3e";
        cp:
        $F4 .= "\15\12\x20\x20\x20\40\x20\40\40\x20\40\x20\40\40\40\x20\40\x20\40\40\40\40\x3c\57\144\x69\x76\x3e\xd\xa\x9\x9\11\11\74\x2f\x64\151\x76\76\15\xa\x20\40\x20\40\x20\x20\x20\40\40\x20\x20\x20\x3c\57\x64\x69\x76\76";
        return $F4;
    }
    private function get_escaped_notice($F4)
    {
        return wp_kses($F4, array("\x62" => array(), "\141" => array("\x68\162\x65\146" => array())));
    }
}
