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

This commit is contained in:
Naomi 2013-06-10 15:54:32 -04:00
commit fe0b0b9a65
1 changed files with 9 additions and 2 deletions

View File

@ -116,12 +116,19 @@ function dayClick(date, allDay, jsEvent, view){
// duration in milisec // duration in milisec
var duration = (duration_h * 60 * 60 * 1000) + (duration_m * 60 * 1000); var duration = (duration_h * 60 * 60 * 1000) + (duration_m * 60 * 1000);
var startTime_string, startTime var startTime_string;
var startTime = 0;
// get start time value on the form // get start time value on the form
if(view.name === "month") { if(view.name === "month") {
startTime_string = $("#add_show_start_time").val(); startTime_string = $("#add_show_start_time").val();
var startTime_info = startTime_string.split(':'); var startTime_info = startTime_string.split(':');
startTime = (parseInt(startTime_info[0],10) * 60 * 60 * 1000) + (parseInt(startTime_info[1], 10) * 60 * 1000); if (startTime_info.length == 2) {
var start_time_temp = (parseInt(startTime_info[0],10) * 60 * 60 * 1000)
+ (parseInt(startTime_info[1], 10) * 60 * 1000);
if (!isNaN(start_time_temp)) {
startTime = start_time_temp;
}
}
}else{ }else{
// if in day or week view, selected has all the time info as well // if in day or week view, selected has all the time info as well
// so we don't ahve to calculate it explicitly // so we don't ahve to calculate it explicitly