live tv + nuget updates
This commit is contained in:
@@ -75,7 +75,7 @@
|
||||
|
||||
header: "Select Server Cache Path",
|
||||
|
||||
instruction: "Browse or enter the path to use for Media Browser Server cache. The folder must be writeable."
|
||||
instruction: "Browse or enter the path to use for Media Browser Server cache. The folder must be writeable. The location of this folder will directly impact server performance and should ideally be placed on a solid state drive."
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
@@ -26,20 +26,67 @@
|
||||
currentItem = item;
|
||||
|
||||
$('.itemName', page).html(item.Name);
|
||||
$('.channel', page).html('<a href="livetvchannel.html?id=' + item.ChannelId + '">' + item.ChannelName + '</a>').trigger('create');
|
||||
$('.overview', page).html(item.Overview || '');
|
||||
|
||||
$('#txtRequestedPrePaddingSeconds', page).val(item.RequestedPrePaddingSeconds);
|
||||
$('#txtRequestedPostPaddingSeconds', page).val(item.RequestedPostPaddingSeconds);
|
||||
$('#txtRequiredPrePaddingSeconds', page).val(item.RequiredPrePaddingSeconds);
|
||||
$('#txtRequiredPostPaddingSeconds', page).val(item.RequiredPostPaddingSeconds);
|
||||
$('#selectPriority', page).val(item.Priority);
|
||||
|
||||
$('.itemMiscInfo', page).html(LibraryBrowser.getMiscInfoHtml(item));
|
||||
var channelHtml = '';
|
||||
|
||||
if (item.RecurrenceType == 'NewProgramEventsAllChannels' || item.RecurrenceType == 'AllProgramEventsAllChannels') {
|
||||
channelHtml += 'All Channels';
|
||||
}
|
||||
else if (item.ChannelId) {
|
||||
channelHtml += '<a href="livetvchannel.html?id=' + item.ChannelId + '">' + item.ChannelName + '</a>';
|
||||
}
|
||||
|
||||
$('.channel', page).html('Channel: ' + channelHtml).trigger('create');
|
||||
|
||||
$('#selectSeriesType', page).val(item.RecurrenceType).selectmenu('refresh').trigger('change');
|
||||
|
||||
selectDays(page, item.Days);
|
||||
|
||||
|
||||
$('.time', page).html('Time: ' + LiveTvHelpers.getDisplayTime(item.StartDate));
|
||||
|
||||
Dashboard.hideLoadingMsg();
|
||||
}
|
||||
|
||||
function selectDays(page, days) {
|
||||
|
||||
var daysOfWeek = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'];
|
||||
|
||||
for (var i = 0, length = daysOfWeek.length; i < length; i++) {
|
||||
|
||||
var day = daysOfWeek[i];
|
||||
|
||||
$('#chk' + day, page).checked(days.indexOf(day) != -1).checkboxradio('refresh');
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function getDays(page) {
|
||||
|
||||
var daysOfWeek = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'];
|
||||
|
||||
var days = [];
|
||||
|
||||
for (var i = 0, length = daysOfWeek.length; i < length; i++) {
|
||||
|
||||
var day = daysOfWeek[i];
|
||||
|
||||
if ($('#chk' + day, page).checked()) {
|
||||
days.push(day);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return days;
|
||||
}
|
||||
|
||||
function onSubmit() {
|
||||
|
||||
Dashboard.showLoadingMsg();
|
||||
@@ -52,7 +99,9 @@
|
||||
item.RequestedPostPaddingSeconds = $('#txtRequestedPostPaddingSeconds', form).val();
|
||||
item.RequiredPrePaddingSeconds = $('#txtRequiredPrePaddingSeconds', form).val();
|
||||
item.RequiredPostPaddingSeconds = $('#txtRequiredPostPaddingSeconds', form).val();
|
||||
item.Priority = $('#selectPriority', form).val();
|
||||
item.RecurrenceType = $('#selectSeriesType', form).val();
|
||||
|
||||
item.Days = getDays(form);
|
||||
|
||||
ApiClient.updateLiveTvSeriesTimer(item).done(function () {
|
||||
Dashboard.alert('Timer Saved');
|
||||
@@ -70,7 +119,7 @@
|
||||
|
||||
var id = getParameterByName('id');
|
||||
|
||||
apiClient.getLiveTvTimer(id).done(function (result) {
|
||||
apiClient.getLiveTvSeriesTimer(id).done(function (result) {
|
||||
|
||||
renderTimer(page, result);
|
||||
|
||||
@@ -87,6 +136,16 @@
|
||||
|
||||
});
|
||||
|
||||
$('#selectSeriesType', page).on('change', function () {
|
||||
|
||||
if (this.value == 'Manual') {
|
||||
$('#fldDays', page).show();
|
||||
} else {
|
||||
$('#fldDays', page).hide();
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
}).on('pagebeforeshow', "#liveTvSeriesTimerPage", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
@@ -32,9 +32,8 @@
|
||||
html += '<th class="tabletColumn"> </th>';
|
||||
html += '<th>Name</th>';
|
||||
html += '<th class="desktopColumn">Channel</th>';
|
||||
html += '<th>Start</th>';
|
||||
html += '<th>End</th>';
|
||||
html += '<th class="tabletColumn">Days</th>';
|
||||
html += '<th class="tabletColumn">Time</th>';
|
||||
|
||||
html += '</tr>';
|
||||
|
||||
@@ -53,33 +52,15 @@
|
||||
html += '</td>';
|
||||
|
||||
html += '<td class="desktopColumn">';
|
||||
if (timer.ChannelId) {
|
||||
|
||||
if (timer.RecurrenceType == 'NewProgramEventsAllChannels' || timer.RecurrenceType == 'AllProgramEventsAllChannels') {
|
||||
html += 'All Channels';
|
||||
}
|
||||
else if (timer.ChannelId) {
|
||||
html += '<a href="livetvchannel.html?id=' + timer.ChannelId + '">' + timer.ChannelName + '</a>';
|
||||
}
|
||||
html += '</td>';
|
||||
|
||||
var startDate = timer.StartDate;
|
||||
var endDate = timer.StartDate;
|
||||
|
||||
try {
|
||||
|
||||
startDate = parseISO8601Date(startDate, { toLocal: true });
|
||||
|
||||
} catch (err) {
|
||||
|
||||
}
|
||||
|
||||
try {
|
||||
|
||||
endDate = parseISO8601Date(endDate, { toLocal: true });
|
||||
|
||||
} catch (err) {
|
||||
|
||||
}
|
||||
|
||||
html += '<td>' + startDate.toLocaleDateString() + '</td>';
|
||||
html += '<td>' + endDate.toLocaleDateString() + '</td>';
|
||||
|
||||
html += '<td class="tabletColumn">';
|
||||
|
||||
if (timer.DayPattern) {
|
||||
@@ -93,6 +74,8 @@
|
||||
|
||||
html += '</td>';
|
||||
|
||||
html += '<td class="tabletColumn">' + LiveTvHelpers.getDisplayTime(timer.StartDate) + '</td>';
|
||||
|
||||
html += '</tr>';
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user