$36 GRAYBYTE WORDPRESS FILE MANAGER $78

SERVER : vnpttt-amd7f72-h1.vietnix.vn #1 SMP Fri May 24 12:42:50 UTC 2024
SERVER IP : 103.200.23.149 | ADMIN IP 216.73.216.22
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/usr/local/lsws/add-ons/webcachemgr/src/View/Model/

HOME
Current File : /usr/local/lsws/add-ons/webcachemgr/src/View/Model//DataFileMsgViewModel.php
<?php

/** ******************************************
 * LiteSpeed Web Server Cache Manager
 *
 * @author    Michael Alegre
 * @copyright 2018-2025 LiteSpeed Technologies, Inc.
 * ******************************************* */

namespace Lsc\Wp\View\Model;

use Lsc\Wp\Context\Context;
use Lsc\Wp\LSCMException;
use Lsc\Wp\WPInstallStorage;

class DataFileMsgViewModel
{

    const FLD_TITLE    = 'title';
    const FLD_DISCOVER = 'discover';

    /**
     * @var WPInstallStorage
     */
    private $wpInstallStorage;

    /**
     * @var string[]
     */
    private $tplData = array();

    /**
     *
     * @param WPInstallStorage  $wpInstallStorage
     */
    public function __construct( WPInstallStorage $wpInstallStorage )
    {
        $this->wpInstallStorage = $wpInstallStorage;

        $this->init();
    }

    private function init()
    {
        $this->setTitleAndDiscover();
    }

    /**
     *
     * @param string  $field
     * @return null|string
     */
    public function getTplData( $field )
    {
        if ( !isset($this->tplData[$field]) ) {
            return null;
        }

        return $this->tplData[$field];
    }

    private function setTitleAndDiscover()
    {
        switch ( $this->wpInstallStorage->getError() ) {

            case WPInstallStorage::ERR_NOT_EXIST:
                $title    = 'No Scan Data Found';
                $discover = 'discover';
                break;

            case WPInstallStorage::ERR_CORRUPTED:
                $title    = 'Scan Data Corrupted';
                $discover = 're-discover';
                break;

            default:
                $title    = 'Scan Data Needs To Be Updated';
                $discover = 're-discover';
        }

        $this->tplData[self::FLD_TITLE]    = $title;
        $this->tplData[self::FLD_DISCOVER] = $discover;
    }

    /**
     *
     * @return string
     *
     * @throws LSCMException  Thrown indirectly by Context::getOption() call.
     */
    public function getTpl()
    {
        return Context::getOption()->getSharedTplDir() . '/DataFileMsg.tpl';
    }

}

Current_dir [ NOT WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
11 Sep 2025 10.22 PM
root / root
0775
Ajax
--
11 Sep 2025 10.22 PM
root / root
0775
CacheRootNotSetViewModel.php
0.682 KB
11 Sep 2025 10.22 PM
root / root
0664
DashNotifierViewModel.php
2.567 KB
11 Sep 2025 10.22 PM
root / root
0664
DataFileMsgViewModel.php
2.052 KB
11 Sep 2025 10.22 PM
root / root
0664
FlagUnflagAllProgressViewModel.php
2.822 KB
11 Sep 2025 10.22 PM
root / root
0664
ManageViewModel.php
14.199 KB
11 Sep 2025 10.22 PM
root / root
0664
MassDashDisableProgressViewModel.php
2.123 KB
11 Sep 2025 10.22 PM
root / root
0664
MassDashNotifyProgressViewModel.php
2.163 KB
11 Sep 2025 10.22 PM
root / root
0664
MassEnableDisableProgressViewModel.php
3.308 KB
11 Sep 2025 10.22 PM
root / root
0664
MassEnableDisableViewModel.php
2.783 KB
11 Sep 2025 10.22 PM
root / root
0664
MissingTplViewModel.php
1.008 KB
11 Sep 2025 10.22 PM
root / root
0664
RefreshStatusProgressViewModel.php
1.672 KB
11 Sep 2025 10.22 PM
root / root
0664
ScanProgressStepViewModel.php
3.62 KB
11 Sep 2025 10.22 PM
root / root
0664
ScanProgressViewModel.php
2.685 KB
11 Sep 2025 10.22 PM
root / root
0664
UnflagAllProgressViewModel.php
2.049 KB
11 Sep 2025 10.22 PM
root / root
0664
VersionChangeViewModel.php
1.74 KB
11 Sep 2025 10.22 PM
root / root
0664
VersionManageViewModel.php
5.289 KB
11 Sep 2025 10.22 PM
root / root
0664

GRAYBYTE WORDPRESS FILE MANAGER @ 2026 CONTACT ME
Static GIF