Merge branch 'devel' of dev.sourcefabric.org:airtime into devel

This commit is contained in:
denise 2013-01-14 17:02:05 -05:00
commit a85b394d63
35 changed files with 138 additions and 165 deletions

View file

@ -48,7 +48,7 @@ class ApiController extends Zend_Controller_Action
public function checkAuth()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$api_key = $this->_getParam('api_key');
if (!in_array($api_key, $CC_CONFIG["apiKey"]) &&

View file

@ -19,7 +19,7 @@ class AudiopreviewController extends Zend_Controller_Action
*/
public function audioPreviewAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$audioFileID = $this->_getParam('audioFileID');
$audioFileArtist = $this->_getParam('audioFileArtist');
@ -73,7 +73,7 @@ class AudiopreviewController extends Zend_Controller_Action
*/
public function playlistPreviewAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$playlistIndex = $this->_getParam('playlistIndex');
$playlistID = $this->_getParam('playlistID');
@ -99,7 +99,7 @@ class AudiopreviewController extends Zend_Controller_Action
public function blockPreviewAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$blockIndex = $this->_getParam('blockIndex');
$blockId = $this->_getParam('blockId');
@ -226,7 +226,7 @@ class AudiopreviewController extends Zend_Controller_Action
*/
public function showPreviewAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$showID = $this->_getParam('showID');
$showIndex = $this->_getParam('showIndex');

View file

@ -96,7 +96,7 @@ class DashboardController extends Zend_Controller_Action
public function streamPlayerAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$baseUrl = Application_Common_OsPath::getBaseDir();

View file

@ -25,7 +25,7 @@ class LibraryController extends Zend_Controller_Action
public function indexAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$request = $this->getRequest();
$baseUrl = Application_Common_OsPath::getBaseDir();

View file

@ -12,7 +12,7 @@ class ListenerstatController extends Zend_Controller_Action
public function indexAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$request = $this->getRequest();
$baseUrl = Application_Common_OsPath::getBaseDir();

View file

@ -9,7 +9,7 @@ class LoginController extends Zend_Controller_Action
public function indexAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$request = $this->getRequest();
@ -102,7 +102,7 @@ class LoginController extends Zend_Controller_Action
public function passwordRestoreAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$baseUrl = Application_Common_OsPath::getBaseDir();

View file

@ -12,7 +12,7 @@ class PlayouthistoryController extends Zend_Controller_Action
public function indexAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$request = $this->getRequest();

View file

@ -13,7 +13,7 @@ class PluploadController extends Zend_Controller_Action
public function indexAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$baseUrl = Application_Common_OsPath::getBaseDir();
$locale = Application_Model_Preference::GetLocale();

View file

@ -20,7 +20,7 @@ class PreferenceController extends Zend_Controller_Action
public function indexAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$request = $this->getRequest();
$isSaas = Application_Model_Preference::GetPlanLevel() == 'disabled'?false:true;
@ -80,7 +80,7 @@ class PreferenceController extends Zend_Controller_Action
public function supportSettingAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$request = $this->getRequest();
@ -136,7 +136,7 @@ class PreferenceController extends Zend_Controller_Action
public function directoryConfigAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
if(Application_Model_Preference::GetPlanLevel() == 'disabled'){
@ -153,7 +153,7 @@ class PreferenceController extends Zend_Controller_Action
public function streamSettingAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$request = $this->getRequest();

View file

@ -40,7 +40,7 @@ class ScheduleController extends Zend_Controller_Action
public function indexAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$baseUrl = Application_Common_OsPath::getBaseDir();
@ -879,8 +879,6 @@ class ScheduleController extends Zend_Controller_Action
public function contentContextMenuAction()
{
global $CC_CONFIG;
$id = $this->_getParam('id');
$params = '/format/json/id/#id#/';
@ -922,8 +920,6 @@ class ScheduleController extends Zend_Controller_Action
public function calculateDurationAction()
{
global $CC_CONFIG;
$startParam = $this->_getParam('startTime');
$endParam = $this->_getParam('endTime');

View file

@ -19,7 +19,7 @@ class ShowbuilderController extends Zend_Controller_Action
public function indexAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$request = $this->getRequest();

View file

@ -4,7 +4,7 @@ class SystemstatusController extends Zend_Controller_Action
{
public function init()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$baseUrl = Application_Common_OsPath::getBaseDir();

View file

@ -16,7 +16,7 @@ class UserController extends Zend_Controller_Action
public function addUserAction()
{
global $CC_CONFIG;
$CC_CONFIG = Config::getConfig();
$request = $this->getRequest();
$baseUrl = Application_Common_OsPath::getBaseDir();
@ -48,8 +48,8 @@ class UserController extends Zend_Controller_Action
if ($form->isValid($formData)) {
if (isset($CC_CONFIG['demo']) && $CC_CONFIG['demo'] == 1
&& $formData['login'] == 'admin'
if (isset($CC_CONFIG['demo']) && $CC_CONFIG['demo'] == 1
&& $formData['login'] == 'admin'
&& $formData['user_id'] != 0) {
$this->view->form = $form;
$this->view->successMessage = "<div class='errors'>"._("Specific action is not allowed in demo version!")."</div>";
@ -131,12 +131,12 @@ class UserController extends Zend_Controller_Action
if ($request->isPost()) {
$formData = $request->getPost();
if (isset($CC_CONFIG['demo']) && $CC_CONFIG['demo'] == 1
if (isset($CC_CONFIG['demo']) && $CC_CONFIG['demo'] == 1
&& $formData['cu_login'] == 'admin') {
$this->view->form = $form;
$this->view->successMessage = "<div class='errors'>"._("Specific action is not allowed in demo version!")."</div>";
die(json_encode(array("html"=>$this->view->render('user/edit-user.phtml'))));
} else if ($form->isValid($formData) &&
} else if ($form->isValid($formData) &&
$form->validateLogin($formData['cu_login'], $formData['cu_user_id'])) {
$user = new Application_Model_User($formData['cu_user_id']);
$user->setFirstName($formData['cu_first_name']);
@ -186,7 +186,7 @@ class UserController extends Zend_Controller_Action
# only delete when valid action is selected for the owned files
if (! in_array($files_action, $valid_actions) ) {
return;
}
}
$userInfo = Zend_Auth::getInstance()->getStorage()->read();
$userId = $userInfo->id;