1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

add playback of in-progress recordings

This commit is contained in:
Luke Pulverenti 2016-10-09 03:18:43 -04:00
parent ca36b18094
commit 2077019d9a
20 changed files with 88 additions and 395 deletions

View file

@ -355,7 +355,7 @@
}
else if (item.TimerId) {
status = item.TimerStatus;
status = item.Status;
}
else if (item.Type == 'Timer') {

View file

@ -105,7 +105,7 @@ define(['css!./indicators.css', 'material-icons'], function () {
}
else if (item.TimerId) {
status = item.TimerStatus;
status = item.Status;
}
else if (item.Type == 'Timer') {

View file

@ -58,7 +58,7 @@ define(['apphost', 'globalize', 'connectionManager', 'itemHelper', 'embyRouter',
}
}
if (itemHelper.canEdit(user, item.Type)) {
if (itemHelper.canEdit(user, item)) {
if (options.edit !== false && item.Type != 'SeriesTimer') {
@ -71,7 +71,7 @@ define(['apphost', 'globalize', 'connectionManager', 'itemHelper', 'embyRouter',
}
}
if (itemHelper.canEditImages(user, item.Type)) {
if (itemHelper.canEditImages(user, item)) {
if (options.editImages !== false) {
commands.push({
@ -81,9 +81,9 @@ define(['apphost', 'globalize', 'connectionManager', 'itemHelper', 'embyRouter',
}
}
if (itemHelper.canEdit(user, item.Type)) {
if (itemHelper.canEdit(user, item)) {
if (item.MediaType == 'Video' && item.Type != 'TvChannel' && item.Type != 'Program' && item.LocationType != 'Virtual') {
if (item.MediaType == 'Video' && item.Type != 'TvChannel' && item.Type != 'Program' && item.LocationType != 'Virtual' && !(item.Type == 'Recording' && item.Status != 'Completed')) {
if (options.editSubtitles !== false) {
commands.push({
name: globalize.translate('sharedcomponents#EditSubtitles'),
@ -176,7 +176,7 @@ define(['apphost', 'globalize', 'connectionManager', 'itemHelper', 'embyRouter',
if (user.Policy.IsAdministrator) {
if (item.Type != 'Timer' && item.Type != 'SeriesTimer' && item.Type != 'Program') {
if (item.Type != 'Timer' && item.Type != 'SeriesTimer' && item.Type != 'Program' && !(item.Type == 'Recording' && item.Status != 'Completed')) {
commands.push({
name: globalize.translate('sharedcomponents#Refresh'),
id: 'refresh'

View file

@ -56,6 +56,12 @@ define(['apphost'], function (appHost) {
var invalidTypes = ['Person', 'Genre', 'MusicGenre', 'Studio', 'GameGenre', 'BoxSet', 'Playlist', 'UserView', 'CollectionFolder', 'Audio', 'TvChannel', 'Program', 'MusicAlbum', 'Timer'];
if (item.Type == 'Recording') {
if (item.Status != 'Completed') {
return false;
}
}
return !item.CollectionType && invalidTypes.indexOf(item.Type) == -1 && item.MediaType != 'Photo';
}
@ -70,10 +76,19 @@ define(['apphost'], function (appHost) {
if (item.Type == 'SeriesTimer') {
return false;
}
if (item.Type == 'Recording') {
if (item.Status != 'Completed') {
return false;
}
}
return item.MediaType || item.IsFolder || item.Type == "Genre" || item.Type == "MusicGenre" || item.Type == "MusicArtist";
}
function canEdit(user, itemType) {
function canEdit(user, item) {
var itemType = item.Type;
if (itemType == "UserRootFolder" || /*itemType == "CollectionFolder" ||*/ itemType == "UserView") {
return false;
@ -83,12 +98,13 @@ define(['apphost'], function (appHost) {
return false;
}
if (user.Policy.IsAdministrator) {
return true;
if (item.Type == 'Recording') {
if (item.Status != 'Completed') {
return false;
}
}
return false;
return user.Policy.IsAdministrator;
}
return {
@ -119,7 +135,9 @@ define(['apphost'], function (appHost) {
canEdit: canEdit,
canEditImages: function (user, itemType) {
canEditImages: function (user, item) {
var itemType = item.Type;
if (itemType == 'UserView') {
if (user.Policy.IsAdministrator) {
@ -130,7 +148,13 @@ define(['apphost'], function (appHost) {
return false;
}
return itemType != 'Timer' && itemType != 'SeriesTimer' && canEdit(user, itemType);
if (item.Type == 'Recording') {
if (item.Status != 'Completed') {
return false;
}
}
return itemType != 'Timer' && itemType != 'SeriesTimer' && canEdit(user, item);
},
canSync: function (user, item) {
@ -150,6 +174,11 @@ define(['apphost'], function (appHost) {
if (item.Type == 'SeriesTimer') {
return false;
}
if (item.Type == 'Recording') {
if (item.Status != 'Completed') {
return false;
}
}
return user.Policy.EnablePublicSharing && appHost.supports('sharing');
}
};

View file

@ -9,7 +9,7 @@ define(['datetime', 'globalize', 'embyRouter', 'itemHelper', 'material-icons', '
}
else if (item.TimerId) {
status = item.TimerStatus;
status = item.Status;
}
else if (item.Type == 'Timer') {

View file

@ -117,7 +117,7 @@
parent.querySelector('.seriesRecordingButton .buttonText').innerHTML = globalize.translate('sharedcomponents#RecordSeries');
}
if (program.TimerId && program.TimerStatus != 'Cancelled') {
if (program.TimerId && program.Status != 'Cancelled') {
parent.querySelector('.btnManageRecording').classList.remove('visibilityHide');
parent.querySelector('.singleRecordingButton .recordingIcon').classList.add('recordingIcon-active');
parent.querySelector('.singleRecordingButton .buttonText').innerHTML = globalize.translate('sharedcomponents#DoNotRecord');
@ -138,7 +138,7 @@
return apiClient.getLiveTvProgram(options.programId, apiClient.getCurrentUserId()).then(function (program) {
instance.TimerId = program.TimerId;
instance.TimerStatus = program.TimerStatus;
instance.Status = program.Status;
instance.SeriesTimerId = program.SeriesTimerId;
loadData(options.parent, program, apiClient);
@ -162,7 +162,7 @@
var options = this.options;
if (!this.TimerId || this.TimerStatus == 'Cancelled') {
if (!this.TimerId || this.Status == 'Cancelled') {
return;
}
@ -213,7 +213,7 @@
var button = dom.parentWithTag(e.target, 'BUTTON');
var isChecked = !button.querySelector('i').classList.contains('recordingIcon-active');
var hasEnabledTimer = this.TimerId && this.TimerStatus != 'Cancelled';
var hasEnabledTimer = this.TimerId && this.Status != 'Cancelled';
if (isChecked) {
if (!hasEnabledTimer) {

View file

@ -86,7 +86,7 @@
var html = '';
html += '<div class="listItem ' + cssClass + '" data-type="' + type + '" data-path="' + path + '" style="border-bottom:1px solid #e0e0e0;">';
html += '<div class="listItemBody" style="min-height:2em;padding-left:0;">';
html += '<div class="listItemBody" style="padding-left:0;padding-top:.5em;padding-bottom:.5em;">';
html += '<div class="listItemBodyText">';
html += name;
html += '</div>';

View file

@ -171,7 +171,7 @@ progress {
.adminDrawer .sidebarLink {
color: #333 !important;
font-weight: 400 !important;
padding: .7em 0 .7em 1.5em;
padding: .7em 0 .7em 2em;
}
.adminDrawer .sidebarHeader {
@ -215,137 +215,12 @@ progress {
}
}
/* A
-----------------------------------------------------------------------------------------------------------*/
/* Bar: Toolbars, dividers, slider track */
.ui-bar-a,
.ui-page-theme-a .ui-bar-inherit,
html .ui-bar-a .ui-bar-inherit,
html .ui-body-a .ui-bar-inherit,
html body .ui-group-theme-a .ui-bar-inherit {
background-color: #e9e9e9 /*{a-bar-background-color}*/;
border-color: #ddd /*{a-bar-border}*/;
color: #333 /*{a-bar-color}*/;
font-weight: bold;
}
.ui-bar-a {
border-width: 1px;
border-style: solid;
}
/* Page and overlay */
.ui-page-theme-a .ui-panel-wrapper {
background-color: #f9f9f9 /*{a-page-background-color}*/;
border-color: #bbb /*{a-page-border}*/;
color: #333 /*{a-page-color}*/;
}
/* Body: Read-only lists, text inputs, collapsible content */
.ui-page-theme-a .ui-body-inherit,
html .ui-bar-a .ui-body-inherit,
html .ui-body-a .ui-body-inherit,
html body .ui-group-theme-a .ui-body-inherit,
html .ui-panel-page-container-a {
background-color: #fff /*{a-body-background-color}*/;
border-color: #ddd /*{a-body-border}*/;
color: #333 /*{a-body-color}*/;
}
/* Links */
.ui-page-theme-a a,
html .ui-bar-a a,
html .ui-body-a a,
html body .ui-group-theme-a a {
.ui-body-a a {
color: #388E3C /*{a-link-color}*/;
font-weight: 500;
}
.ui-page-theme-a a:visited,
html .ui-bar-a a:visited,
html .ui-body-a a:visited,
html body .ui-group-theme-a a:visited {
color: #388E3C /*{a-link-visited}*/;
}
.ui-page-theme-a a:hover,
html .ui-bar-a a:hover,
html .ui-body-a a:hover,
html body .ui-group-theme-a a:hover {
color: #1B5E20 /*{a-link-hover}*/;
}
.ui-page-theme-a a:active,
html .ui-bar-a a:active,
html .ui-body-a a:active,
html body .ui-group-theme-a a:active {
color: #1B5E20 /*{a-link-active}*/;
}
/* Button up */
.ui-page-theme-a .ui-btn,
html .ui-bar-a .ui-btn,
html .ui-body-a .ui-btn,
html body .ui-group-theme-a .ui-btn,
html head + body .ui-btn.ui-btn-a,
/* Button visited */
.ui-page-theme-a .ui-btn:visited,
html .ui-bar-a .ui-btn:visited,
html .ui-body-a .ui-btn:visited,
html body .ui-group-theme-a .ui-btn:visited,
html head + body .ui-btn.ui-btn-a:visited,
ul[data-role="listview"] a + a {
background-color: #f6f6f6 /*{a-bup-background-color}*/;
border-color: #ddd /*{a-bup-border}*/;
color: #333 /*{a-bup-color}*/;
}
/* Button hover */
.ui-page-theme-a .ui-btn:hover,
html .ui-bar-a .ui-btn:hover,
html .ui-body-a .ui-btn:hover,
html body .ui-group-theme-a .ui-btn:hover,
html head + body .ui-btn.ui-btn-a:hover {
background-color: #ededed /*{a-bhover-background-color}*/;
border-color: #ddd /*{a-bhover-border}*/;
color: #333 /*{a-bhover-color}*/;
}
/* Button down */
.ui-page-theme-a .ui-btn:active,
html .ui-bar-a .ui-btn:active,
html .ui-body-a .ui-btn:active,
html body .ui-group-theme-a .ui-btn:active,
html head + body .ui-btn.ui-btn-a:active {
background-color: #e8e8e8 /*{a-bdown-background-color}*/;
border-color: #ddd /*{a-bdown-border}*/;
color: #333 /*{a-bdown-color}*/;
}
/* Active button */
.ui-page-theme-a .ui-btn.ui-btn-active,
html .ui-bar-a .ui-btn.ui-btn-active,
html .ui-body-a .ui-btn.ui-btn-active,
html body .ui-group-theme-a .ui-btn.ui-btn-active,
html head + body .ui-btn.ui-btn-a.ui-btn-active,
/* Active checkbox icon */
.ui-page-theme-a .ui-checkbox-on:after,
html .ui-bar-a .ui-checkbox-on:after,
html .ui-body-a .ui-checkbox-on:after,
html body .ui-group-theme-a .ui-checkbox-on:after,
.ui-btn.ui-checkbox-on.ui-btn-a:after {
background-color: #3388cc /*{a-active-background-color}*/;
border-color: #3388cc /*{a-active-border}*/;
color: #fff /*{a-active-color}*/;
}
/* Active radio button icon */
.ui-page-theme-a .ui-radio-on:after,
html .ui-bar-a .ui-radio-on:after,
html .ui-body-a .ui-radio-on:after,
html body .ui-group-theme-a .ui-radio-on:after,
.ui-btn.ui-radio-on.ui-btn-a:after {
border-color: #3388cc /*{a-active-background-color}*/;
}
div[data-role="controlgroup"] a[data-role='button'] {
display: inline-block !important;
margin: 0 !important;
@ -375,26 +250,6 @@ div[data-role="controlgroup"] a.ui-btn-active {
color: #fff !important;
}
.ui-listview li h3 {
font-weight: 400;
}
.ui-listview > .ui-li-divider {
line-height: 1.5;
line-height: initial;
}
.ui-slider-track.ui-mini .ui-slider-handle {
height: 18px;
width: 18px;
margin: -10px 0 0 -10px;
}
.ui-btn {
font-family: inherit;
font-weight: 500 !important;
}
a[data-role='button'], .type-interior button:not([data-role='none']):not(.clearButton):not([is]) {
-webkit-font-smoothing: antialiased;
-webkit-user-select: none;
@ -530,10 +385,6 @@ a[data-role='button'], .type-interior button:not([data-role='none']):not(.clearB
margin-left: 2em;
min-width: 300px;
}
.firstDashboardHomeRightColumn .ui-collapsible-content {
min-height: 585px;
}
}
@media all and (min-width: 1580px) {
@ -544,11 +395,6 @@ a[data-role='button'], .type-interior button:not([data-role='none']):not(.clearB
width: 300px;
min-width: 300px;
}
.dashboardHomeRightColumn .ui-collapsible-content {
height: auto;
min-height: 585px;
}
}
@media all and (min-width: 1680px) {
@ -670,10 +516,6 @@ a[data-role='button'], .type-interior button:not([data-role='none']):not(.clearB
opacity: .95;
}
.activeDevicesCollapsible .ui-collapsible-content {
padding: .5em .5em !important;
}
.activeSession:not(.playingSession) .sessionNowPlayingContent {
display: none;
}
@ -814,39 +656,6 @@ a[data-role='button'], .type-interior button:not([data-role='none']):not(.clearB
height: 36px;
}
/*
Media Library Page
*/
.mediaFolderButtons {
margin-top: 10px;
}
.mediaFolderLocations {
margin: 1em .25em !important;
}
.mediaLocationsHeader {
padding-top: .75em !important;
padding-bottom: .75em !important;
}
.mediaLocationsHeader .ui-btn {
position: absolute;
right: -3px;
margin-top: 0 !important;
margin-bottom: 0 !important;
top: 4px;
}
.btnShowStatusMessage {
font-weight: normal !important;
text-decoration: none;
}
.btnShowStatusMessage:hover {
text-decoration: underline;
}
.supporterMembershipDisabled .tabSupporterMembership {
display: none;
}

View file

@ -938,7 +938,7 @@ span.itemCommunityRating:not(:empty) + .userDataIcons {
@media all and (min-width: 1000px) {
.itemDetailPage .portraitCard-scalable {
width: 25% !important;
width: 20% !important;
}
.itemDetailPage .squareCard-scalable {

View file

@ -239,7 +239,7 @@ body:not(.dashboardDocument) .btnNotifications {
}
i.sidebarLinkIcon {
font-size: 120%;
font-size: 114%;
height: auto;
width: auto;
}

View file

@ -123,43 +123,6 @@ h1 a:hover {
background-color: #fff;
}
input:not([type='checkbox']):not([type='radio']):not([type='file']):not([type='range']):not([is='emby-input']) {
-webkit-appearance: none;
-webkit-font-smoothing: antialiased;
-webkit-rtl-ordering: logical;
-webkit-user-select: text;
box-sizing: border-box;
font-family: inherit;
font-size: inherit;
height: 28.5938px;
letter-spacing: normal;
line-height: 18.2px;
list-style-image: none;
list-style-position: outside;
list-style-type: none;
min-height: 28.6px;
padding-bottom: 5.2px;
padding-left: 5.2px;
padding-right: 5.2px;
padding-top: 5.2px;
text-align: left;
text-indent: 0px;
text-rendering: auto;
text-shadow: none;
text-transform: none;
white-space: nowrap;
word-spacing: 0px;
writing-mode: lr-tb;
-webkit-writing-mode: horizontal-tb;
background: white;
width: 100%;
border: 1px solid #ccc;
color: #000;
margin: 0 0 3px 0;
border-radius: 4px;
display: block;
}
.ui-body-a select, .ui-body-a [is="emby-input"], .ui-body-a [is="emby-textarea"] {
background: none;
border-color: #ccc !important;

View file

@ -50,13 +50,6 @@
<select is="emby-select" id="selectUser" data-mini="true" label="${LabelDefaultUser}"></select>
<div class="fieldDescription">${LabelDefaultUserHelp}</div>
</div>
<div class="checkboxContainer checkboxContainer-withDescription">
<label>
<input type="checkbox" is="emby-checkbox" id="chkEnableMovieFolders" />
<span>${LabelEnableEnhancedMovies}</span>
</label>
<div class="fieldDescription checkboxFieldDescription">${LabelEnableEnhancedMoviesHelp}</div>
</div>
<div>
<button is="emby-button" type="submit" class="raised button-submit block">
<span>${ButtonSave}</span>

View file

@ -135,7 +135,7 @@
</div>
<div id="similarCollapsible" class="detailSection hide">
<h1>${HeaderMoreLikeThis}</h1>
<div id="similarContent"></div>
<div class="similarContent"></div>
</div>
<div id="criticReviewsCollapsible" class="detailSection hide">
<h1>

View file

@ -83,7 +83,7 @@
<div class="pageTabContent ehsContent" id="recordingsTab" data-index="3">
<div id="activeRecordings" class="homePageSection hide">
<h1 class="listHeader">${HeaderActiveRecordings}</h1>
<div class="recordingItems"></div>
<div is="emby-itemscontainer" class="recordingItems itemsContainer"></div>
<br />
</div>
<div id="latestRecordings" class="homePageSection hide">
@ -148,7 +148,7 @@
</div>
</div>
<div class="pageTabContent ehsContent" id="seriesTab" data-index="5">
<div is="emby-itemscontainer" class="vertical-wrap itemsContainer" id="items"></div>
<div is="emby-itemscontainer" class="vertical-wrap itemsContainer centered" id="items"></div>
</div>
<div data-role="content">

View file

@ -11,8 +11,6 @@
$('#chkBlastAliveMessages', page).checked(config.BlastAliveMessages);
$('#txtBlastInterval', page).val(config.BlastAliveMessageIntervalSeconds);
$('#chkEnableMovieFolders', page).checked(config.EnableMovieFolders);
var usersHtml = users.map(function (u) {
return '<option value="' + u.Id + '">' + u.Name + '</option>';
}).join('');
@ -40,8 +38,6 @@
config.BlastAliveMessageIntervalSeconds = $('#txtBlastInterval', form).val();
config.DefaultUserId = $('#selectUser', form).val();
config.EnableMovieFolders = $('#chkEnableMovieFolders', form).checked();
ApiClient.updateNamedConfiguration("dlna", config).then(Dashboard.processServerConfigurationUpdateResult);
});

View file

@ -239,9 +239,9 @@
}
var itemBirthLocation = page.querySelector('#itemBirthLocation');
if (item.Type == "Person" && item.PlaceOfBirth) {
if (item.Type == "Person" && item.ProductionLocations && item.ProductionLocations.length) {
var gmap = '<a class="textlink" target="_blank" href="https://maps.google.com/maps?q=' + item.PlaceOfBirth + '">' + item.PlaceOfBirth + '</a>';
var gmap = '<a class="textlink" target="_blank" href="https://maps.google.com/maps?q=' + item.ProductionLocations[0] + '">' + item.ProductionLocations[0] + '</a>';
itemBirthLocation.classList.remove('hide');
itemBirthLocation.innerHTML = Globalize.translate('BirthPlaceValue').replace('{0}', gmap);
@ -899,7 +899,7 @@
var options = {
userId: Dashboard.getCurrentUserId(),
limit: 8,
limit: item.Type == "MusicAlbum" || item.Type == "MusicArtist" ? 8 : 10,
fields: "PrimaryImageAspectRatio,UserData,CanDelete"
};
@ -942,7 +942,7 @@
});
html += '</div>';
var similarContent = page.querySelector('#similarContent');
var similarContent = similarCollapsible.querySelector('.similarContent');
similarContent.innerHTML = html;
ImageLoader.lazyChildren(similarContent);
});

View file

@ -88,7 +88,6 @@
showAirTime: true,
showAirEndTime: true,
showChannelName: true,
lazy: true,
cardLayout: true,
vibrant: true,
action: 'edit',

View file

@ -93,6 +93,10 @@
ImageLoader.lazyChildren(recordingItems);
}
function getBackdropShape() {
return enableScrollX() ? 'overflowBackdrop' : 'backdrop';
}
function renderActiveRecordings(context, promise) {
promise.then(function (result) {
@ -102,8 +106,18 @@
result.Items = [];
}
renderTimers(context.querySelector('#activeRecordings'), result.Items, {
indexByDate: false
renderRecordings(context.querySelector('#activeRecordings'), result.Items, {
shape: getBackdropShape(),
showParentTitle: false,
showTitle: true,
showAirTime: true,
showAirEndTime: true,
showChannelName: true,
cardLayout: true,
vibrant: true,
preferThumb: true,
coverImage: true,
overlayText: false
});
});
}
@ -162,29 +176,11 @@
});
}
function renderTimers(context, timers, options) {
LiveTvHelpers.getTimersHtml(timers, options).then(function (html) {
var elem = context;
if (html) {
elem.classList.remove('hide');
} else {
elem.classList.add('hide');
}
elem.querySelector('.recordingItems').innerHTML = html;
ImageLoader.lazyChildren(elem);
});
}
function onMoreClick(e) {
var type = this.getAttribute('data-type');
switch(type) {
switch (type) {
case 'latest':
Dashboard.navigate('livetvitems.html?type=Recordings');
break;
@ -230,8 +226,14 @@
});
self.preRender = function () {
activeRecordingsPromise = ApiClient.getLiveTvTimers({
IsActive: true
activeRecordingsPromise = ApiClient.getLiveTvRecordings({
UserId: Dashboard.getCurrentUserId(),
IsInProgress: true,
Fields: 'CanDelete,PrimaryImageAspectRatio,BasicSyncInfo',
EnableTotalRecordCount: false,
EnableImageTypes: "Primary,Thumb,Backdrop"
});
latestPromise = ApiClient.getLiveTvRecordings({

View file

@ -1,4 +1,4 @@
define(['datetime', 'cardBuilder', 'paper-icon-button-light', 'emby-button'], function (datetime, cardBuilder) {
define(['datetime', 'cardBuilder', 'imageLoader', 'paper-icon-button-light', 'emby-button'], function (datetime, cardBuilder, imageLoader) {
var query = {
@ -6,26 +6,6 @@
SortOrder: "Ascending"
};
function deleteSeriesTimer(context, id) {
require(['confirm'], function (confirm) {
confirm(Globalize.translate('MessageConfirmSeriesCancellation'), Globalize.translate('HeaderConfirmSeriesCancellation')).then(function () {
Dashboard.showLoadingMsg();
ApiClient.cancelLiveTvSeriesTimer(id).then(function () {
require(['toast'], function (toast) {
toast(Globalize.translate('MessageSeriesCancelled'));
});
reload(context);
});
});
});
}
function renderTimers(context, timers) {
var html = '';
@ -43,92 +23,14 @@
showSeriesTimerChannel: true
});
//if (timers.length) {
// html += '<div class="paperList">';
//}
//for (var i = 0, length = timers.length; i < length; i++) {
// var timer = timers[i];
// html += '<div class="listItem">';
// html += '<i class="md-icon listItemIcon">live_tv</i>';
// html += '<div class="listItemBody three-line">';
// html += '<a class="clearLink" href="livetvseriestimer.html?id=' + timer.Id + '">';
// html += '<h3 class="listItemBodyText">';
// html += timer.Name;
// html += '</h3>';
// html += '<div class="secondary">';
// if (timer.DayPattern) {
// html += timer.DayPattern;
// }
// else {
// var days = timer.Days || [];
// html += days.join(', ');
// }
// if (timer.RecordAnyTime) {
// html += ' - ' + Globalize.translate('LabelAnytime');
// } else {
// html += ' - ' + datetime.getDisplayTime(timer.StartDate);
// }
// html += '</div>';
// html += '<div class="secondary">';
// if (timer.RecordAnyChannel) {
// html += Globalize.translate('LabelAllChannels');
// }
// else if (timer.ChannelId) {
// html += timer.ChannelName;
// }
// html += '</div>';
// html += '</a>';
// html += '</div>';
// html += '<button type="button" is="paper-icon-button-light" data-seriestimerid="' + timer.Id + '" title="' + Globalize.translate('ButtonCancelSeries') + '" class="btnCancelSeries autoSize"><i class="md-icon">cancel</i></button>';
// html += '</div>';
//}
//if (timers.length) {
// html += '</div>';
//}
var elem = context.querySelector('#items');
elem.innerHTML = html;
//if (timers.length) {
// elem.querySelector('.paperList').addEventListener('click', function (e) {
// var btnCancelSeries = parentWithClass(e.target, 'btnCancelSeries');
// if (btnCancelSeries) {
// deleteSeriesTimer(context, btnCancelSeries.getAttribute('data-seriestimerid'));
// }
// });
//}
imageLoader.lazyChildren(elem);
Dashboard.hideLoadingMsg();
}
function parentWithClass(elem, className) {
while (!elem.classList || !elem.classList.contains(className)) {
elem = elem.parentNode;
if (!elem) {
return null;
}
}
return elem;
}
function reload(context, promise) {
Dashboard.showLoadingMsg();

View file

@ -35,7 +35,7 @@
</div>
<br />
<div>
<div class="accessScheduleSection">
<div class="detailSectionHeader">
<h1>${HeaderAccessSchedule}</h1>
<button is="emby-button" type="button" class="raised btnAddSchedule submit mini" style="margin-left:1em;" title="${ButtonAddUser}">