diff --git a/dashboard-ui/edititemmetadata.html b/dashboard-ui/edititemmetadata.html index 2c1c2f742f..f5442e784c 100644 --- a/dashboard-ui/edititemmetadata.html +++ b/dashboard-ui/edititemmetadata.html @@ -37,7 +37,7 @@
@@ -48,7 +48,7 @@
diff --git a/dashboard-ui/livetvchannel.html b/dashboard-ui/livetvchannel.html index aa1c651ba9..cd1319bfee 100644 --- a/dashboard-ui/livetvchannel.html +++ b/dashboard-ui/livetvchannel.html @@ -9,7 +9,8 @@ Guide Channels Recordings - Timers + Upcoming Timers + Series Timers
diff --git a/dashboard-ui/livetvchannels.html b/dashboard-ui/livetvchannels.html index 22155c7837..b24ab31d35 100644 --- a/dashboard-ui/livetvchannels.html +++ b/dashboard-ui/livetvchannels.html @@ -9,7 +9,8 @@ Guide Channels Recordings - Timers + Upcoming Timers + Series Timers
diff --git a/dashboard-ui/livetvguide.html b/dashboard-ui/livetvguide.html index d18ce51915..34bb20c307 100644 --- a/dashboard-ui/livetvguide.html +++ b/dashboard-ui/livetvguide.html @@ -9,7 +9,8 @@ Guide Channels Recordings - Timers + Upcoming Timers + Series Timers
diff --git a/dashboard-ui/livetvrecording.html b/dashboard-ui/livetvrecording.html index eaf51d9c7c..e0c80f0fdc 100644 --- a/dashboard-ui/livetvrecording.html +++ b/dashboard-ui/livetvrecording.html @@ -9,7 +9,8 @@ Guide Channels Recordings - Timers + Upcoming Timers + Series Timers
diff --git a/dashboard-ui/livetvrecordings.html b/dashboard-ui/livetvrecordings.html index 90234b4f40..a737d1dd28 100644 --- a/dashboard-ui/livetvrecordings.html +++ b/dashboard-ui/livetvrecordings.html @@ -9,7 +9,8 @@ Guide Channels Recordings - Timers + Upcoming Timers + Series Timers
diff --git a/dashboard-ui/livetvseriestimer.html b/dashboard-ui/livetvseriestimer.html new file mode 100644 index 0000000000..3dac91d204 --- /dev/null +++ b/dashboard-ui/livetvseriestimer.html @@ -0,0 +1,21 @@ + + + + Media Browser + + + + + diff --git a/dashboard-ui/livetvseriestimers.html b/dashboard-ui/livetvseriestimers.html new file mode 100644 index 0000000000..6abd9ec36d --- /dev/null +++ b/dashboard-ui/livetvseriestimers.html @@ -0,0 +1,21 @@ + + + + Media Browser + + + + + diff --git a/dashboard-ui/livetvtimer.html b/dashboard-ui/livetvtimer.html index 77ae9c6994..9a4548b142 100644 --- a/dashboard-ui/livetvtimer.html +++ b/dashboard-ui/livetvtimer.html @@ -9,16 +9,22 @@ Guide Channels Recordings - Timers + Upcoming Timers + Series Timers
-

Timer Info

+

-

+

+ + Cancel Timer + +

+

diff --git a/dashboard-ui/livetvtimers.html b/dashboard-ui/livetvtimers.html index d4b3346209..3044dbc72d 100644 --- a/dashboard-ui/livetvtimers.html +++ b/dashboard-ui/livetvtimers.html @@ -9,7 +9,8 @@ Guide Channels Recordings - Timers + Upcoming Timers + Series Timers

diff --git a/dashboard-ui/scripts/livetvseriestimer.js b/dashboard-ui/scripts/livetvseriestimer.js new file mode 100644 index 0000000000..5f282702bb --- /dev/null +++ b/dashboard-ui/scripts/livetvseriestimer.js @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/dashboard-ui/scripts/livetvseriestimers.js b/dashboard-ui/scripts/livetvseriestimers.js new file mode 100644 index 0000000000..5f282702bb --- /dev/null +++ b/dashboard-ui/scripts/livetvseriestimers.js @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/dashboard-ui/scripts/livetvtimer.js b/dashboard-ui/scripts/livetvtimer.js index 6a649a4bfd..766d33bcb3 100644 --- a/dashboard-ui/scripts/livetvtimer.js +++ b/dashboard-ui/scripts/livetvtimer.js @@ -2,6 +2,25 @@ var currentItem; + function deleteTimer(page, id) { + + Dashboard.confirm("Are you sure you wish to cancel this timer?", "Confirm Timer Cancellation", function (result) { + + if (result) { + + Dashboard.showLoadingMsg(); + + ApiClient.cancelLiveTvTimer(id).done(function () { + + Dashboard.alert('Timer deleted'); + + reload(page); + }); + } + + }); + } + function renderTimer(page, item) { currentItem = item; @@ -15,6 +34,17 @@ $('#txtRequiredPrePaddingSeconds', page).val(item.RequiredPrePaddingSeconds); $('#txtRequiredPostPaddingSeconds', page).val(item.RequiredPostPaddingSeconds); + $('.itemMiscInfo', page).html(LibraryBrowser.getMiscInfoHtml(item)); + $('.status', page).html('Status:   ' + item.Status); + + if (item.SeriesTimerId) { + + $('.seriesTimerLink', page).html('View Series').show().trigger('create'); + + } else { + $('.seriesTimerLink', page).hide(); + } + Dashboard.hideLoadingMsg(); } @@ -35,6 +65,12 @@ var page = this; + $('#btnCancelTimer', page).on('click', function () { + + deleteTimer(page, currentItem.Id); + + }); + }).on('pagebeforeshow', "#liveTvTimerPage", function () { var page = this; diff --git a/dashboard-ui/scripts/livetvtimers.js b/dashboard-ui/scripts/livetvtimers.js index c2bd486761..fbd42aa7f6 100644 --- a/dashboard-ui/scripts/livetvtimers.js +++ b/dashboard-ui/scripts/livetvtimers.js @@ -1,9 +1,5 @@ (function ($, document, apiClient) { - function editTimer(page, id) { - - } - function deleteTimer(page, id) { Dashboard.confirm("Are you sure you wish to cancel this timer?", "Confirm Timer Cancellation", function (result) { @@ -40,7 +36,7 @@ html += 'Start'; html += 'Length'; html += 'Status'; - html += 'Recurring'; + html += 'Series'; html += ''; @@ -86,9 +82,10 @@ html += ''; - if (timer.IsRecurring) { - html += ' '; - html += '✓'; + if (timer.SeriesTimerId) { + html += ''; + html += 'View'; + html += ''; } html += ''; @@ -100,13 +97,6 @@ var elem = $('#items', page).html(html).trigger('create'); - $('.btnEditTimer', elem).on('click', function () { - - var id = this.getAttribute('data-timerid'); - - editTimer(page, id); - }); - $('.btnDeleteTimer', elem).on('click', function () { var id = this.getAttribute('data-timerid'); @@ -120,7 +110,7 @@ function reload(page) { Dashboard.showLoadingMsg(); - + apiClient.getLiveTvTimers().done(function (result) { renderTimers(page, result.Items);