public function actionIndex() { $systemInfo = EnvUtil::getSystemInfo(); $databaseSize = DatabaseUtil::getDatabaseSize(); list($dataSize, $dataUnit) = explode(" ", $databaseSize); $appClosed = Setting::model()->fetchSettingValueByKey("appclosed"); $newVersion = Ibos::app()->setting->get("newversion"); $getSecurityUrl = Ibos::app()->urlManager->createUrl("dashboard/index/getsecurity"); $mainModule = Module::model()->fetchByPk("main"); $authkey = Ibos::app()->setting->get("config/security/authkey"); $unit = Setting::model()->fetchSettingValueByKey("unit"); $license = Setting::model()->fetchSettingValueByKey("license"); $licenseUrl = $this->getLicenseUrl(unserialize($unit), $authkey); if (isset($_GET["attachsize"])) { $attachSize = Attachment::model()->getTotalFilesize(); $attachSize = is_numeric($attachSize) ? ConvertUtil::sizeCount($attachSize) : Ibos::lang("Unknow"); } else { $attachSize = ""; } $data = array("sys" => $systemInfo, "dataSize" => $dataSize, "dataUnit" => $dataUnit, "appClosed" => $appClosed, "newVersion" => $newVersion, "getSecurityUrl" => $getSecurityUrl, "installDate" => $mainModule["installdate"], "authkey" => $authkey, "license" => unserialize($license), "licenseUrl" => $licenseUrl, "attachSize" => $attachSize); $this->render("index", $data); }