Merge branch 'devel' of dev.sourcefabric.org:airtime into devel
This commit is contained in:
commit
41b072b412
|
@ -41,11 +41,11 @@ class ScheduleController extends Zend_Controller_Action
|
|||
$baseUrl = $request->getBaseUrl();
|
||||
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/contextmenu/jjmenu.js','text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/datatables/js/jquery.dataTables.js','text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/datatables/plugin/dataTables.pluginAPI.js','text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/datatables/js/jquery.dataTables.js','text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/datatables/plugin/dataTables.pluginAPI.js','text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/fullcalendar/fullcalendar.js','text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/timepicker/jquery.ui.timepicker-0.0.6.js','text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/colorpicker/js/colorpicker.js','text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/colorpicker/js/colorpicker.js','text/javascript');
|
||||
|
||||
//full-calendar-functions.js requires this variable, so that datePicker widget can be offset to server time instead of client time
|
||||
$this->view->headScript()->appendScript("var timezoneOffset = ".date("Z")."; //in seconds");
|
||||
|
@ -55,10 +55,10 @@ class ScheduleController extends Zend_Controller_Action
|
|||
$this->view->headScript()->appendFile($baseUrl.'/js/airtime/schedule/schedule.js','text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl.'/js/meioMask/jquery.meio.mask.js','text/javascript');
|
||||
|
||||
$this->view->headLink()->appendStylesheet($baseUrl.'/css/jquery-ui-timepicker.css');
|
||||
$this->view->headLink()->appendStylesheet($baseUrl.'/css/jquery-ui-timepicker.css');
|
||||
$this->view->headLink()->appendStylesheet($baseUrl.'/css/fullcalendar.css');
|
||||
$this->view->headLink()->appendStylesheet($baseUrl.'/css/colorpicker/css/colorpicker.css');
|
||||
$this->view->headLink()->appendStylesheet($baseUrl.'/css/add-show.css');
|
||||
$this->view->headLink()->appendStylesheet($baseUrl.'/css/colorpicker/css/colorpicker.css');
|
||||
$this->view->headLink()->appendStylesheet($baseUrl.'/css/add-show.css');
|
||||
$this->view->headLink()->appendStylesheet($baseUrl.'/css/contextmenu.css');
|
||||
|
||||
Application_Model_Schedule::createNewFormSections($this->view);
|
||||
|
@ -67,6 +67,8 @@ class ScheduleController extends Zend_Controller_Action
|
|||
$user = new Application_Model_User($userInfo->id);
|
||||
$this->view->isAdmin = $user->isAdmin();
|
||||
$this->view->isProgramManager = $user->isUserType('P');
|
||||
|
||||
$this->view->headScript()->appendScript("var weekStart = ".Application_Model_Preference::GetWeekStartDay().";");
|
||||
}
|
||||
|
||||
public function eventFeedAction()
|
||||
|
@ -339,15 +341,15 @@ class ScheduleController extends Zend_Controller_Action
|
|||
return false;
|
||||
}
|
||||
|
||||
$playlists = $show->searchPlaylistsForShow($post);
|
||||
foreach( $playlists['aaData'] as &$data){
|
||||
// calling two functions to format time to 1 decimal place
|
||||
$sec = Application_Model_Playlist::playlistTimeToSeconds($data[4]);
|
||||
$data[4] = Application_Model_Playlist::secondsToPlaylistTime($sec);
|
||||
}
|
||||
$playlists = $show->searchPlaylistsForShow($post);
|
||||
foreach( $playlists['aaData'] as &$data){
|
||||
// calling two functions to format time to 1 decimal place
|
||||
$sec = Application_Model_Playlist::playlistTimeToSeconds($data['length']);
|
||||
$data['length'] = Application_Model_Playlist::secondsToPlaylistTime($sec);
|
||||
}
|
||||
|
||||
//for datatables
|
||||
die(json_encode($playlists));
|
||||
//for datatables
|
||||
die(json_encode($playlists));
|
||||
}
|
||||
|
||||
public function removeGroupAction()
|
||||
|
|
|
@ -405,9 +405,6 @@ function toggleAll() {
|
|||
}
|
||||
$(this).addClass('selected');
|
||||
} else {
|
||||
if (type == "pl") {
|
||||
checkedPLCount--;
|
||||
}
|
||||
$(this).removeClass('selected');
|
||||
}
|
||||
});
|
||||
|
@ -428,7 +425,7 @@ function enableGroupBtn(btnId, func) {
|
|||
btnId = '#' + btnId;
|
||||
if ($(btnId).hasClass('ui-state-disabled')) {
|
||||
$(btnId).removeClass('ui-state-disabled');
|
||||
$(btnId).click(func);
|
||||
$(btnId).unbind("click").click(func);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -476,16 +473,15 @@ function checkBoxChanged() {
|
|||
} else if (!cbAllChecked && checkedCount == size) {
|
||||
cbAll.attr("checked", true);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
function setupGroupActions() {
|
||||
checkedCount = 0;
|
||||
checkedPLCount = 0;
|
||||
$('#library_display tr:nth-child(1)').find(":checkbox").attr("checked", false);
|
||||
$('#library_display thead').find(":checkbox").change(toggleAll);
|
||||
$('#library_display thead').find(":checkbox").unbind('change').change(toggleAll);
|
||||
$('#library_display tbody tr').each(function() {
|
||||
$(this).find(":checkbox").change(checkBoxChanged);
|
||||
$(this).find(":checkbox").unbind('change').change(checkBoxChanged);
|
||||
});
|
||||
|
||||
disableGroupBtn('library_group_add');
|
||||
|
@ -567,7 +563,7 @@ function createDataTable(data) {
|
|||
$(document).ready(function() {
|
||||
$('.tabs').tabs();
|
||||
|
||||
$.ajax({ url: "/Api/library-init/format/json", dataType:"json", success:createDataTable,
|
||||
$.ajax({url: "/Api/library-init/format/json", dataType:"json", success:createDataTable,
|
||||
error:function(jqXHR, textStatus, errorThrown){}});
|
||||
|
||||
checkImportStatus();
|
||||
|
|
|
@ -33,7 +33,8 @@ function createDateInput(el, onSelect) {
|
|||
onSelect: onSelect,
|
||||
dateFormat: 'yy-mm-dd',
|
||||
closeText: 'Close',
|
||||
showButtonPanel: true
|
||||
showButtonPanel: true,
|
||||
firstDay: weekStart
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -190,7 +191,8 @@ function setAddShowEvents() {
|
|||
minDate: adjustDateToServerDate(new Date(), timezoneOffset),
|
||||
dateFormat: 'yy-mm-dd',
|
||||
closeText: 'Close',
|
||||
showButtonPanel: true
|
||||
showButtonPanel: true,
|
||||
firstDay: weekStart
|
||||
});
|
||||
form.find('input[name^="add_show_rebroadcast_time"]').timepicker({
|
||||
amPmText: ['', ''],
|
||||
|
|
|
@ -86,7 +86,7 @@ function setScheduleDialogEvents(dialog) {
|
|||
}
|
||||
|
||||
function dtRowCallback( nRow, aData, iDisplayIndex, iDisplayIndexFull ) {
|
||||
var id = "pl_" + aData[0];
|
||||
var id = "pl_" + aData['id'];
|
||||
|
||||
$(nRow).attr("id", id);
|
||||
|
||||
|
@ -125,12 +125,12 @@ function makeScheduleDialog(dialog, json) {
|
|||
"fnRowCallback": dtRowCallback,
|
||||
"fnDrawCallback": dtDrawCallback,
|
||||
"aoColumns": [
|
||||
/* Id */ { "sName": "pl.id", "bSearchable": false, "bVisible": false },
|
||||
/* Description */ { "sName": "pl.description", "bVisible": false },
|
||||
/* Name */ { "sName": "pl.name" },
|
||||
/* Creator */ { "sName": "pl.creator" },
|
||||
/* Length */ { "sName": "plt.length" },
|
||||
/* Editing */ { "sName": "sub.login" }
|
||||
/* Id */ {"sTitle": "ID", "sName": "pl.id", "bSearchable": false, "bVisible": false, "mDataProp": "id"},
|
||||
/* Description */ {"sTitle": "Description", "sName": "pl.description", "bSearchable": false, "bVisible": false, "mDataProp": "description"},
|
||||
/* Name */ {"sTitle": "Title", "sName": "pl.name", "mDataProp": "name"},
|
||||
/* Creator */ {"sTitle": "Creator", "sName": "pl.creator", "mDataProp": "creator"},
|
||||
/* Length */ {"sTitle": "Length", "sName": "plt.length", "mDataProp": "length"},
|
||||
/* Editing */ {"sTitle": "Editing", "sName": "sub.login", "mDataProp": "login"}
|
||||
],
|
||||
"aaSorting": [[2,'asc']],
|
||||
"sPaginationType": "full_numbers",
|
||||
|
|
Loading…
Reference in New Issue