modified listener stat more
This commit is contained in:
parent
fafc599780
commit
448d9b9e90
2 changed files with 64 additions and 14 deletions
|
@ -1,22 +1,27 @@
|
|||
$(document).ready(function() {
|
||||
showlistenerstat_content = $("#showlistenerstat_content")
|
||||
dateStartId = "#sb_date_start",
|
||||
timeStartId = "#sb_time_start",
|
||||
dateEndId = "#sb_date_end",
|
||||
timeEndId = "#sb_time_end",
|
||||
show_id = "#sb_show_filter";
|
||||
dateStartId = "#his_date_start",
|
||||
timeStartId = "#his_time_start",
|
||||
dateEndId = "#his_date_end",
|
||||
timeEndId = "#his_time_end",
|
||||
show_id = "#his_show_filter";
|
||||
|
||||
console.log(show_id);
|
||||
// set width dynamically
|
||||
var width = $("#showlistenerstat_content").width();
|
||||
width = width * .91;
|
||||
addDatePicker();
|
||||
|
||||
|
||||
showlistenerstat_content.find("#sb_submit").click(function(){
|
||||
var show_id = $("#sb_show_filter").val();
|
||||
console.log(show_id);
|
||||
var oRange = AIRTIME.utilities.fnGetScheduleRange(dateStartId, timeStartId, dateEndId, timeEndId);
|
||||
var start = oRange.start;
|
||||
var end = oRange.end;
|
||||
|
||||
getShowData(start, end, show_id);
|
||||
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -27,6 +32,34 @@ function getShowData(startTimestamp, endTimestamp, show_id) {
|
|||
});
|
||||
}
|
||||
|
||||
function addDatePicker() {
|
||||
|
||||
oBaseDatePickerSettings = {
|
||||
dateFormat: 'yy-mm-dd',
|
||||
//i18n_months, i18n_days_short are in common.js
|
||||
monthNames: i18n_months,
|
||||
dayNamesMin: i18n_days_short,
|
||||
onSelect: function(sDate, oDatePicker) {
|
||||
$(this).datepicker( "setDate", sDate );
|
||||
}
|
||||
};
|
||||
|
||||
oBaseTimePickerSettings = {
|
||||
showPeriodLabels: false,
|
||||
showCloseButton: true,
|
||||
closeButtonText: $.i18n._("Done"),
|
||||
showLeadingZero: false,
|
||||
defaultTime: '0:00',
|
||||
hourText: $.i18n._("Hour"),
|
||||
minuteText: $.i18n._("Minute")
|
||||
};
|
||||
|
||||
showlistenerstat_content.find(dateStartId).datepicker(oBaseDatePickerSettings);
|
||||
showlistenerstat_content.find(timeStartId).timepicker(oBaseTimePickerSettings);
|
||||
showlistenerstat_content.find(dateEndId).datepicker(oBaseDatePickerSettings);
|
||||
showlistenerstat_content.find(timeEndId).timepicker(oBaseTimePickerSettings);
|
||||
}
|
||||
|
||||
function brokeDataTable() {
|
||||
var oRange = AIRTIME.utilities.fnGetScheduleRange(dateStartId, timeStartId, dateEndId, timeEndId);
|
||||
var start = oRange.start;
|
||||
|
@ -74,4 +107,5 @@ function brokeDataTable() {
|
|||
}),
|
||||
"sDom": '<"H"lf<"dt-process-rel"r>><"#user_list_inner_wrapper"t><"F"ip>'
|
||||
});
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue