Merge branch 'saas-installer-albert' into saas-dev
This commit is contained in:
commit
c18e728583
336 changed files with 5144 additions and 10180 deletions
|
@ -344,7 +344,7 @@ class ApiController extends Zend_Controller_Action
|
|||
* variables in the result to reflect the given timezone.
|
||||
*
|
||||
* @param object $result reference to the object to send back to the user
|
||||
* @param string $timezone the user's timezone parameter value
|
||||
* @param string $timezone the user's timezone parameter value
|
||||
* @param boolean $upcase whether the timezone output should be upcased
|
||||
*/
|
||||
private function applyLiveTimezoneAdjustments(&$result, $timezone, $upcase)
|
||||
|
|
|
@ -38,9 +38,12 @@ class ErrorController extends Zend_Controller_Action {
|
|||
}
|
||||
|
||||
// Log exception, if logger available
|
||||
/* No idea why this doesn't work or why it was implemented like this. Disabling it -- Albert
|
||||
if (($log = $this->getLog())) {
|
||||
$log->crit($this->view->message, $errors->exception);
|
||||
}
|
||||
}*/
|
||||
//Logging that actually works: -- Albert
|
||||
Logging::error($this->view->message . ": " . $errors->exception);
|
||||
|
||||
// conditionally display exceptions
|
||||
if ($this->getInvokeArg('displayExceptions') == true) {
|
||||
|
|
|
@ -13,18 +13,9 @@ class SystemstatusController extends Zend_Controller_Action
|
|||
|
||||
public function indexAction()
|
||||
{
|
||||
/*
|
||||
$services = array(
|
||||
"pypo"=>Application_Model_Systemstatus::GetPypoStatus(),
|
||||
"liquidsoap"=>Application_Model_Systemstatus::GetLiquidsoapStatus(),
|
||||
//"media-monitor"=>Application_Model_Systemstatus::GetMediaMonitorStatus(),
|
||||
);
|
||||
*/
|
||||
|
||||
$partitions = Application_Model_Systemstatus::GetDiskInfo();
|
||||
|
||||
$this->view->status = new StdClass;
|
||||
//$this->view->status->services = $services;
|
||||
$this->view->status->partitions = $partitions;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,45 +13,25 @@ class UpgradeController extends Zend_Controller_Action
|
|||
return;
|
||||
}
|
||||
|
||||
$upgraders = array();
|
||||
array_push($upgraders, new AirtimeUpgrader253());
|
||||
array_push($upgraders, new AirtimeUpgrader254());
|
||||
array_push($upgraders, new AirtimeUpgrader255());
|
||||
array_push($upgraders, new AirtimeUpgrader259());
|
||||
array_push($upgraders, new AirtimeUpgrader2510());
|
||||
array_push($upgraders, new AirtimeUpgrader2511());
|
||||
array_push($upgraders, new AirtimeUpgrader2512());
|
||||
|
||||
$didWePerformAnUpgrade = false;
|
||||
try
|
||||
{
|
||||
for ($i = 0; $i < count($upgraders); $i++)
|
||||
{
|
||||
$upgrader = $upgraders[$i];
|
||||
if ($upgrader->checkIfUpgradeSupported())
|
||||
{
|
||||
// pass __DIR__ to the upgrades, since __DIR__ returns parent dir of file, not executor
|
||||
$upgrader->upgrade(__DIR__); //This will throw an exception if the upgrade fails.
|
||||
$didWePerformAnUpgrade = true;
|
||||
$this->getResponse()
|
||||
->setHttpResponseCode(200)
|
||||
->appendBody("Upgrade to Airtime " . $upgrader->getNewVersion() . " OK<br>");
|
||||
$i = 0; //Start over, in case the upgrade handlers are not in ascending order.
|
||||
}
|
||||
}
|
||||
try {
|
||||
$upgradeManager = new UpgradeManager();
|
||||
$didWePerformAnUpgrade = $upgradeManager->doUpgrade();
|
||||
|
||||
if (!$didWePerformAnUpgrade)
|
||||
{
|
||||
if (!$didWePerformAnUpgrade) {
|
||||
$this->getResponse()
|
||||
->setHttpResponseCode(200)
|
||||
->appendBody("No upgrade was performed. The current Airtime version is " . AirtimeUpgrader::getCurrentVersion() . ".<br>");
|
||||
->setHttpResponseCode(200)
|
||||
->appendBody("No upgrade was performed. The current schema version is " . Application_Model_Preference::GetSchemaVersion() . ".<br>");
|
||||
} else {
|
||||
$this->getResponse()
|
||||
->setHttpResponseCode(200)
|
||||
->appendBody("Upgrade to Airtime schema version " . Application_Model_Preference::GetSchemaVersion() . " OK<br>");
|
||||
}
|
||||
}
|
||||
catch (Exception $e)
|
||||
{
|
||||
$this->getResponse()
|
||||
->setHttpResponseCode(400)
|
||||
->appendBody($e->getMessage());
|
||||
->setHttpResponseCode(400)
|
||||
->appendBody($e->getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
-- Replacing system_version with schema_version
|
||||
DELETE FROM cc_pref WHERE keystr = 'system_version';
|
||||
INSERT INTO cc_pref (keystr, valstr) VALUES ('schema_version', '2.5.2');
|
||||
|
||||
ALTER TABLE cc_show ADD COLUMN image_path varchar(255) DEFAULT '';
|
||||
ALTER TABLE cc_show_instances ADD COLUMN description varchar(255) DEFAULT '';
|
Loading…
Add table
Add a link
Reference in a new issue