(function ($, document) { var query = { SortBy: "SortName", SortOrder: "Ascending" }; function deleteSeriesTimer(page, id) { Dashboard.confirm(Globalize.translate('MessageConfirmSeriesCancellation'), Globalize.translate('HeaderConfirmSeriesCancellation'), function (result) { if (result) { Dashboard.showLoadingMsg(); ApiClient.cancelLiveTvSeriesTimer(id).done(function () { Dashboard.alert(Globalize.translate('MessageSeriesCancelled')); reload(page); }); } }); } function renderTimers(page, timers) { var html = ''; html += '
'; if (timer.DayPattern) { html += timer.DayPattern; } else { var days = timer.Days || []; html += days.join(', '); } if (timer.RecordAnyTime) { html += ' - ' + Globalize.translate('LabelAnytime'); } else { html += ' - ' + LiveTvHelpers.getDisplayTime(timer.StartDate); } html += '
'; html += ''; if (timer.RecordAnyChannel) { html += Globalize.translate('LabelAllChannels'); } else if (timer.ChannelId) { html += timer.ChannelName; } html += '
'; html += ''; html += '' + Globalize.translate('ButtonCancelSeries') + ''; html += '