Exemplo n.º 1
0
if (cfr('REPORTTARIFFS')) {
    $altCfg = $ubillingConfig->getAlter();
    $chartsCache = new UbillingCache();
    show_window(__('Popularity of tariffs among users'), web_TariffShowReport());
    show_window(__('Planned tariff changes'), web_TariffShowMoveReport());
    if (!isset($altCfg['GCHARTS_ENABLED'])) {
        $chartsEnabled = true;
    } else {
        if ($altCfg['GCHARTS_ENABLED']) {
            $chartsEnabled = true;
        } else {
            $chartsEnabled = false;
        }
    }
    //google charts
    if ($chartsEnabled) {
        $cachingTime = 3600;
        $moveCharts = $chartsCache->getCallback('REPORT_TARIFFS_MOVECHART', function () {
            return web_TariffShowMoveCharts();
        }, $cachingTime);
        $tariffCharts = $chartsCache->getCallback('REPORT_TARIFFS_TARIFFHCHART', function () {
            return web_TariffShowTariffCharts();
        }, $cachingTime);
        //rendering charts
        show_window(__('Graphs'), $tariffCharts . wf_delimiter() . $moveCharts);
        zb_BillingStats(true);
    }
} else {
    show_error(__('You cant control this module'));
}
Exemplo n.º 2
0
<?php

if (cfr('SYSLOAD')) {
    if (wf_CheckGet(array('checkupdates'))) {
        zb_BillingCheckUpdates();
    }
    if (wf_CheckGet(array('phpinfo'))) {
        phpinfo();
        die;
    }
    zb_BillingStats(false);
    //ajax data loaders
    //database check
    if (wf_CheckGet(array('ajaxdbcheck'))) {
        die(zb_DBCheckRender());
    }
    //database stats
    if (wf_CheckGet(array('ajaxdbstats'))) {
        die(zb_DBStatsRender());
    }
    $globconf = $ubillingConfig->getBilling();
    $alterconf = $ubillingConfig->getAlter();
    $monit_url = $globconf['PHPSYSINFO'];
    //custom scripts output handling. We must run this before all others.
    if (isset($alterconf['SYSLOAD_CUSTOM_SCRIPTS'])) {
        if (!empty($alterconf['SYSLOAD_CUSTOM_SCRIPTS'])) {
            $customScriptsData = web_ReportSysloadCustomScripts($alterconf['SYSLOAD_CUSTOM_SCRIPTS']);
        }
    }
    $sysInfoData = '';
    //phpinfo()