Merge branch '2.5.x' of dev.sourcefabric.org:airtime into 2.5.x

This commit is contained in:
Albert Santoni 2013-09-25 16:41:35 -04:00
commit a1f3309cf7
27 changed files with 232 additions and 298 deletions

View file

@ -30,6 +30,21 @@ var i18n_months = [
$.i18n._("December")
];
var i18n_months_short = [
$.i18n._("Jan"),
$.i18n._("Feb"),
$.i18n._("Mar"),
$.i18n._("Apr"),
$.i18n._("May"),
$.i18n._("Jun"),
$.i18n._("Jul"),
$.i18n._("Aug"),
$.i18n._("Sep"),
$.i18n._("Oct"),
$.i18n._("Nov"),
$.i18n._("Dec")
];
var i18n_days_short = [
$.i18n._("Su"),
$.i18n._("Mo"),

View file

@ -466,6 +466,13 @@ var AIRTIME = (function(AIRTIME) {
}
];
//set the locale names for the bootstrap calendar.
$.fn.datetimepicker.dates = {
daysMin: i18n_days_short,
months: i18n_months,
monthsShort: i18n_months_short
};
$historyContentDiv = $("#history_content");

View file

@ -481,6 +481,13 @@ function setAddShowEvents() {
event.preventDefault();
//when editing a show, the record option is disabled
//we have to enable it to get the correct value when
//we call serializeArray()
if (form.find("#add_show_record").attr("disabled", true)) {
form.find("#add_show_record").attr("disabled", false);
}
var data = $("form").serializeArray();
var hosts = $('#add_show_hosts-element input').map(function() {
@ -504,7 +511,7 @@ function setAddShowEvents() {
});
var action = baseUrl+"Schedule/"+String(addShowButton.attr("data-action"));
$.post(action, {format: "json", data: data, hosts: hosts, days: days}, function(json){
//addShowButton.removeClass("disabled");
$('#schedule-add-show').unblock();

View file

@ -178,7 +178,12 @@ var AIRTIME = (function(AIRTIME){
};
mod.checkToolBarIcons = function() {
AIRTIME.library.checkAddButton();
//library may not be on the page.
if (AIRTIME.library !== undefined) {
AIRTIME.library.checkAddButton();
}
mod.checkSelectButton();
mod.checkTrimButton();
mod.checkDeleteButton();

View file

@ -186,7 +186,11 @@ AIRTIME = (function(AIRTIME) {
AIRTIME.showbuilder.fnServerData.start = oRange.start;
AIRTIME.showbuilder.fnServerData.end = oRange.end;
AIRTIME.library.libraryInit();
//the user might not have the library on the page (guest user)
if (AIRTIME.library !== undefined) {
AIRTIME.library.libraryInit();
}
AIRTIME.showbuilder.builderDataTable();
setWidgetSize();