CC-3590: Calendar GUI->DJ user should not be able to invoke "Add Show" window
-add user type into javascript as a variable so we can check permissions on js side
This commit is contained in:
parent
16f3a331bb
commit
da8a5296b0
3 changed files with 18 additions and 4 deletions
|
@ -76,6 +76,14 @@ class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
|
|||
|
||||
$view->headScript()->appendFile($baseUrl.'/js/airtime/common/common.js?'.$CC_CONFIG['airtime_version'],'text/javascript');
|
||||
|
||||
$user = Application_Model_User::GetCurrentUser();
|
||||
if (!is_null($user)){
|
||||
$userType = $user->getType();
|
||||
} else {
|
||||
$userType = "";
|
||||
}
|
||||
$view->headScript()->appendScript("var userType = '$userType';");
|
||||
|
||||
if (Application_Model_Preference::GetPlanLevel() != "disabled"
|
||||
&& ($_SERVER['REQUEST_URI'] != '/Dashboard/stream-player' || $_SERVER['REQUEST_URI'] != '/audiopreview/audio-preview-player')) {
|
||||
$client_id = Application_Model_Preference::GetClientId();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue