private function handleGeneralSettingsAdmin($view)
{
// Whether to display or not the general settings (cron, beta, smtp)
$view->isGeneralSettingsAdminEnabled = self::isGeneralSettingsAdminEnabled();
if ($view->isGeneralSettingsAdminEnabled) {
$this->displayWarningIfConfigFileNotWritable();
}
$enableBrowserTriggerArchiving = Rules::isBrowserTriggerEnabled();
$todayArchiveTimeToLive = Rules::getTodayArchiveTimeToLive();
$showWarningCron = false;
if (!$enableBrowserTriggerArchiving && $todayArchiveTimeToLive < 3600) {
$showWarningCron = true;
}
$view->showWarningCron = $showWarningCron;
$view->todayArchiveTimeToLive = $todayArchiveTimeToLive;
$view->todayArchiveTimeToLiveDefault = Rules::getTodayArchiveTimeToLiveDefault();
$view->enableBrowserTriggerArchiving = $enableBrowserTriggerArchiving;
$releaseChannels = $this->makeReleaseChannels();
$activeChannelId = $releaseChannels->getActiveReleaseChannel()->getId();
$allChannels = array();
foreach ($releaseChannels->getAllReleaseChannels() as $channel) {
$allChannels[] = array('id' => $channel->getId(), 'name' => $channel->getName(), 'description' => $channel->getDescription(), 'active' => $channel->getId() === $activeChannelId);
}
$view->releaseChannels = $allChannels;
$view->mail = Config::getInstance()->mail;
$pluginUpdateCommunication = new UpdateCommunication();
$view->canUpdateCommunication = $pluginUpdateCommunication->canBeEnabled();
$view->enableSendPluginUpdateCommunication = $pluginUpdateCommunication->isEnabled();
}