CC-2807: Remove AIRTIME_VERSION from constants.php and use the value in the database instead

-done
This commit is contained in:
martin 2011-09-23 16:26:19 -04:00
parent e60db9e031
commit cd95170b06
10 changed files with 94 additions and 147 deletions

View file

@ -36,7 +36,7 @@ class ApiController extends Zend_Controller_Action
*
* First checks to ensure the correct API key was
* supplied, then returns AIRTIME_VERSION as defined
* in application/conf.php
* in the database
*
* @return void
*
@ -56,7 +56,7 @@ class ApiController extends Zend_Controller_Action
print 'You are not allowed to access this resource.';
exit;
}
$jsonStr = json_encode(array("version"=>AIRTIME_VERSION));
$jsonStr = json_encode(array("version"=>Application_Model_Preference::GetAirtimeVersion()));
echo $jsonStr;
}
@ -662,7 +662,7 @@ class ApiController extends Zend_Controller_Action
$status = array(
"platform"=>Application_Model_Systemstatus::GetPlatformInfo(),
"airtime_version"=>Application_Model_Systemstatus::GetAirtimeVersion(),
"airtime_version"=>Application_Model_Preference::GetAirtimeVersion(),
"services"=>array(
"icecast2"=>Application_Model_Systemstatus::GetIcecastStatus(),
"rabbitmq"=>Application_Model_Systemstatus::GetRabbitMqStatus(),

View file

@ -83,7 +83,7 @@ class LoginController extends Zend_Controller_Action
$this->view->message = $message;
$this->view->error = $error;
$this->view->form = $form;
$this->view->airtimeVersion = AIRTIME_VERSION;
$this->view->airtimeVersion = Application_Model_Preference::GetAirtimeVersion();
$this->view->airtimeCopyright = AIRTIME_COPYRIGHT_DATE;
}