diff --git a/dashboard-ui/channelitems.html b/dashboard-ui/channelitems.html index 2123fa2d8e..9a06e30669 100644 --- a/dashboard-ui/channelitems.html +++ b/dashboard-ui/channelitems.html @@ -4,15 +4,95 @@ ${TitleMediaBrowser} -
+
+ +

Trailers

+ +
+ + +
+
+
+

Loading channel content...

+
+
+
+ +
+
+ + ${HeaderSortBy} + + + + + + + + + + + + + + + + + + + + + + +
+
+ + ${HeaderSortOrder} + + + + + + + +
+
+
+
+
+
+ + ${HeaderFilters} + + + + + + + + + + + + + + + + + + +
+
+
diff --git a/dashboard-ui/channels.html b/dashboard-ui/channels.html index 130ce2fd80..49a902d41b 100644 --- a/dashboard-ui/channels.html +++ b/dashboard-ui/channels.html @@ -4,7 +4,7 @@ ${TitleMediaBrowser} -
+
diff --git a/dashboard-ui/collections.html b/dashboard-ui/collections.html index a91c0f9af8..da08a7855b 100644 --- a/dashboard-ui/collections.html +++ b/dashboard-ui/collections.html @@ -4,7 +4,7 @@ ${TitleMediaBrowser} -
+
diff --git a/dashboard-ui/css/librarybrowser.css b/dashboard-ui/css/librarybrowser.css index c0a2579124..efca7aea69 100644 --- a/dashboard-ui/css/librarybrowser.css +++ b/dashboard-ui/css/librarybrowser.css @@ -3,14 +3,6 @@ background: none!important; } -.libraryPage { - padding-top: 48px !important; -} - - .libraryPage:not(.metadataEditorPage):not(#indexPage):not(#boxsetsPage):not(#itemListPage):not(.nowPlayingPage):not(.trailerPage) { - padding-top: 91px !important; - } - .ui-panel fieldset + fieldset { margin-top: 2em; } @@ -20,87 +12,6 @@ margin-left: .5em; } -.viewMenuBar { - font-weight: bold; - position: fixed; - right: 0; - left: 0; - z-index: 1000; - top: 0; - padding-left: 10px; - background: #181818; - border-bottom: 1px solid #080808; -} - -.viewMenuLink { - font-size: 90%; -} - -.viewMenuLink { - text-decoration: none; - color: #ccc!important; - padding: 7px .5em 6px; - display: inline-block; - vertical-align: middle; -} - -.viewMenuBar .btnCurrentUser { - padding: 7px 1em 6px; -} - -.viewMenuLink:hover { - color: #fff; -} - - .viewMenuLink:hover img { - opacity: .5; - } - -.viewMenuLink img { - height: 24px; - vertical-align: top; -} - -.selectedMediaFolder { - color: #fff!important; -} -.viewMenuBar .selectedMediaFolder:before { - content: '\25BA'; - color: #fff; -} - -.viewMenuSecondary { - float: right; -} - -.viewMenuTextLink { - display: none; - height: 20px; - padding-top: 9px; - text-transform: uppercase; - font-size: 14px; - font-weight: 400!important; -} - -.viewMenuTextLink { - display: inline-block; -} - -.viewName { - vertical-align: middle; -} - -.selectedViewLink { - color: #fff!important; -} - -.selectedViewIndicator { - margin-right: .25em; - vertical-align: middle; - position: relative; - top: -1px; -} - .libraryPage .header { padding-bottom: 0; } @@ -120,53 +31,6 @@ padding-left: 7px; } -.libraryViewNav { - height: 42px; - overflow: hidden; - border-bottom: 1px solid #333; - position: fixed; - left: 0; - right: 0; - top: 48px; - z-index: 1000; - background-color: #252525; -} - -.libraryViewNavInner { - text-align: center; - font-size: 14px; - white-space: nowrap; - padding: 0 0 0; - overflow-x: auto; - height: 55px; -} - -.libraryViewNav .ui-btn-active .libraryViewNavLinkContent { - border-bottom-color: #38c; - color: #fff; -} - -.libraryViewNav a { - display: inline-block; - padding: 12px 0 0; - color: #eee!important; - text-decoration: none; - margin: 0 0; - position: relative; - font-weight: normal; -} - - .libraryViewNav a:hover { - color: #bbb!important; - } - -.libraryViewNavLinkContent { - border-bottom: 5px solid transparent; - display: inline-block; - padding: 0 .9em 7px; - color: #ddd; -} - .ehsContent { max-width: 640px; margin: 0 auto; @@ -241,11 +105,11 @@ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMYAAAA6CAYAAADryyY/AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAadEVYdFNvZnR3YXJlAFBhaW50Lk5FVCB2My41LjExR/NCNwAAD49JREFUeF7tXVlsFFcW7bYx+2L2xThsHvYwBEMGApMZMLZhIAhMkokmgMQY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5wA84TxMmjRp7p49e/bTIGZGUI+jKyOIsrIy33k4ffp0qV1j6AxhSw9JwkMkCsFW0RhWokUc1c8Q6m5gmdJCTFdEz8dDuUrNqVUuyGl3FOcxptEgbE3mwSD7sIXoT6oBjP5jM2qBfAeQn8GEfv0smW88YFOJeTDIvhMnTvykGsDoP34aQOzatct3Hs6cOVNFY1iZF3FUP2/ZsiUuPYSch0gGjBEzMgVFqxiiCgLlg0NzAD53za4SB8acTpU9QKQ+CMQQ8n7KuZMRE1UOg/xIExgBY5SLyMvQEL8G4IHwgOcuymGQH2kCI+AJPt95QCsQMzIFzUtDYBrZcz2EkIdIp/79+7foa27s9HcTotwOMAycK9HcnYPjB9UQauuAQ7b+VIPQTPwMfhYNUoEwkDu4BqEFFhx/QjpDQ/wagAfKA3Yor0AYyB38iIzQ4oMPPvCdB3x/i74Fw46HNxHpmnA9hIaHzp0752lrbMUQXFhSW4iJOkPIWgiZS1SDcBxCg7D1oenKsMPgVa05cIzb5fCBpYSvgIeFh40bN5bhty6uas0xfvx433g4ePBgnrbloiFWrlzpux6C5oEhEMtpDAjjLAS41aCFyMYxijheQ+gNQ4Ow1XmsBcH7V2CQK+jecQBephiH35/IFfDQ8QBhvIItOK+gWyNQU/vGA3YnXE5jHDhw4Ozq1asD10NAPESiECGnWrkTR77SddG2EBSk0y6TrMUwMghNx++iCRkjxecxlgDcHYNdrkSHhoSWB0zXLiktLfWNB7RWhWvXrg2dHnzmoa0WZjeFg2LuA8vZI25Tk4gWQmYYtQXhd/Ma2IXiNXHH9kQ/zdfBw6O708GDRqXceIzmYK2snXKVCTlR6apBaAbOZPG/H89ldPDw6I6mHA//B6BYmZET/pUHAAAAAElFTkSuQmCC); background-position: left center; background-repeat: no-repeat; - width: 19px; - height: 16px; + width: 14px; + height: 11.7px; display: inline-block; background-size: cover; - vertical-align: central; + vertical-align: top; cursor: pointer; } @@ -671,32 +535,6 @@ a.itemTag:hover { } } -@media all and (min-width: 950px) { - - .libraryMenuButton { - display: none; - } -} - -@media all and (max-width: 950px) { - - .desktopHomeLink { - display: none; - } - - .desktopViewMenuLink { - display: none; - } - - .libraryViewNavInner { - text-align: left; - } - - .selectedViewIndicator { - display: none; - } -} - @media all and (max-width: 750px) { .editorMenuLink { @@ -750,19 +588,6 @@ a.itemTag:hover { @media all and (min-width: 750px) { - .viewMenuLink { - padding-left: .8em; - padding-right: .8em; - } - - .libraryMenuButton + .viewMenuTextLink { - padding-left: .6em !important; - } - - .viewMenuBar .btnCurrentUser { - padding-right: 1.5em; - } - .lnkSibling:not(.hide) { display: block; } diff --git a/dashboard-ui/css/librarymenu.css b/dashboard-ui/css/librarymenu.css new file mode 100644 index 0000000000..7058999af3 --- /dev/null +++ b/dashboard-ui/css/librarymenu.css @@ -0,0 +1,178 @@ +.libraryPage { + padding-top: 48px !important; +} + + .libraryPage:not(.metadataEditorPage):not(.noSecondaryNavPage) { + padding-top: 91px !important; + } + + +.viewMenuBar { + font-weight: bold; + position: fixed; + right: 0; + left: 0; + z-index: 1000; + top: 0; + padding-left: 10px; + background: #181818; + border-bottom: 1px solid #080808; +} + +.viewMenuLink { + font-size: 90%; +} + +.viewMenuLink { + text-decoration: none; + color: #ccc!important; + padding: 7px .5em 6px; + display: inline-block; + vertical-align: middle; +} + +.viewMenuBar .btnCurrentUser { + padding: 7px 1em 6px; +} + +.viewMenuLink:hover { + color: #fff; +} + + .viewMenuLink:hover img { + opacity: .5; + } + +.viewMenuLink img { + height: 24px; + vertical-align: top; +} + +.selectedMediaFolder { + color: #fff!important; +} + +.viewMenuBar .selectedMediaFolder:before { + content: '\25BA'; + color: #fff; +} + +.viewMenuSecondary { + float: right; +} + +.viewMenuTextLink { + display: none; + height: 20px; + padding-top: 9px; + text-transform: uppercase; + font-size: 14px; + font-weight: 400!important; +} + +.viewMenuTextLink { + display: inline-block; +} + +.viewName { + vertical-align: middle; +} + +.selectedViewLink { + color: #fff!important; +} + + +.libraryViewNav { + height: 42px; + overflow: hidden; + border-bottom: 1px solid #333; + position: fixed; + left: 0; + right: 0; + top: 48px; + z-index: 1000; + background-color: #252525; +} + +.libraryViewNavInner { + text-align: center; + font-size: 14px; + white-space: nowrap; + padding: 0 0 0; + overflow-x: auto; + height: 55px; +} + +.libraryViewNav .ui-btn-active .libraryViewNavLinkContent { + border-bottom-color: #38c; + color: #fff; +} + +.libraryViewNav a { + display: inline-block; + padding: 12px 0 0; + color: #eee!important; + text-decoration: none; + margin: 0 0; + position: relative; + font-weight: normal; +} + + .libraryViewNav a:hover { + color: #bbb!important; + } + +.libraryViewNavLinkContent { + border-bottom: 5px solid transparent; + display: inline-block; + padding: 0 .9em 7px; + color: #ddd; +} + + +@media all and (min-width: 950px) { + + .libraryMenuButton { + display: none; + } +} + +@media all and (max-width: 950px) { + + .desktopHomeLink { + display: none; + } + + .desktopViewMenuLink { + display: none; + } + + .libraryViewNavInner { + text-align: left; + } +} + +@media all and (min-width: 750px) { + + .viewMenuLink { + padding-left: .8em; + padding-right: .8em; + } + + .libraryMenuButton + .viewMenuTextLink { + padding-left: .6em !important; + } + + .viewMenuBar .btnCurrentUser { + padding-right: 1.5em; + } + + .lnkSibling:not(.hide) { + display: block; + } + + .itemBackdrop:not(.noBackdrop) { + border-bottom: 1px solid #111; + } +} diff --git a/dashboard-ui/css/posteritem.css b/dashboard-ui/css/posteritem.css index 90b41a5a6d..db99c1f929 100644 --- a/dashboard-ui/css/posteritem.css +++ b/dashboard-ui/css/posteritem.css @@ -55,10 +55,6 @@ background-color: #999; } -.borderlessPosterItem .posterItemImage { - border-color: transparent; -} - .posterItemStoreText { font-weight: normal; text-overflow: ellipsis; diff --git a/dashboard-ui/index.html b/dashboard-ui/index.html index c7538612d4..43c0490458 100644 --- a/dashboard-ui/index.html +++ b/dashboard-ui/index.html @@ -4,7 +4,7 @@ ${TitleMediaBrowser} -
+
diff --git a/dashboard-ui/itemlist.html b/dashboard-ui/itemlist.html index 343a07a059..0bce4eeb28 100644 --- a/dashboard-ui/itemlist.html +++ b/dashboard-ui/itemlist.html @@ -4,7 +4,7 @@ -
+
diff --git a/dashboard-ui/movietrailers.html b/dashboard-ui/movietrailers.html index a7e3469ff3..468de44db0 100644 --- a/dashboard-ui/movietrailers.html +++ b/dashboard-ui/movietrailers.html @@ -4,7 +4,7 @@ ${TitleMediaBrowser} -
+
diff --git a/dashboard-ui/nowplaying.html b/dashboard-ui/nowplaying.html index a18caf80fb..1531ebda6b 100644 --- a/dashboard-ui/nowplaying.html +++ b/dashboard-ui/nowplaying.html @@ -4,7 +4,7 @@ ${TitleMediaBrowser} -
+
diff --git a/dashboard-ui/scripts/channelitems.js b/dashboard-ui/scripts/channelitems.js index 5d79db6f34..efb9791529 100644 --- a/dashboard-ui/scripts/channelitems.js +++ b/dashboard-ui/scripts/channelitems.js @@ -3,6 +3,8 @@ // The base query options var query = { + SortBy: "SortName", + SortOrder: "Ascending", StartIndex: 0 }; @@ -10,9 +12,18 @@ return 'channels-' + getParameterByName('id'); } + function showLoadingMessage(page) { + + $('#popupDialog', page).popup('open'); + } + + function hideLoadingMessage(page) { + $('#popupDialog', page).popup('close'); + } + function reloadItems(page) { - Dashboard.showLoadingMsg(); + showLoadingMessage(page); var channelId = getParameterByName('id'); @@ -57,16 +68,90 @@ LibraryBrowser.saveQueryValues(getSavedQueryId(), query); - Dashboard.hideLoadingMsg(); + hideLoadingMessage(page); }); } function updateFilterControls(page) { + // Reset form values using the last used query + $('.radioSortBy', page).each(function () { + + this.checked = (query.SortBy || '').toLowerCase() == this.getAttribute('data-sortby').toLowerCase(); + + }).checkboxradio('refresh'); + + $('.radioSortOrder', page).each(function () { + + this.checked = (query.SortOrder || '').toLowerCase() == this.getAttribute('data-sortorder').toLowerCase(); + + }).checkboxradio('refresh'); + + $('.chkStandardFilter', page).each(function () { + + var filters = "," + (query.Filters || ""); + var filterName = this.getAttribute('data-filter'); + + this.checked = filters.indexOf(',' + filterName) != -1; + + }).checkboxradio('refresh'); + + $('.alphabetPicker', page).alphaValue(query.NameStartsWith); } - $(document).on('pagebeforeshow', "#channelItemsPage", function () { + $(document).on('pageinit', "#channelItemsPage", function () { + var page = this; + + $('.radioSortBy', this).on('click', function () { + query.StartIndex = 0; + query.SortBy = this.getAttribute('data-sortby'); + reloadItems(page); + }); + + $('.radioSortOrder', this).on('click', function () { + query.StartIndex = 0; + query.SortOrder = this.getAttribute('data-sortorder'); + reloadItems(page); + }); + + $('.chkStandardFilter', this).on('change', function () { + + var filterName = this.getAttribute('data-filter'); + var filters = query.Filters || ""; + + filters = (',' + filters).replace(',' + filterName, '').substring(1); + + if (this.checked) { + filters = filters ? (filters + ',' + filterName) : filterName; + } + + query.StartIndex = 0; + query.Filters = filters; + + reloadItems(page); + }); + + $('.alphabetPicker', this).on('alphaselect', function (e, character) { + + query.NameStartsWithOrGreater = character; + query.StartIndex = 0; + + reloadItems(page); + + }).on('alphaclear', function (e) { + + query.NameStartsWithOrGreater = ''; + + reloadItems(page); + }); + + }).on('pagebeforeshow', "#channelItemsPage", function () { + + + }).on('pageshow', "#channelItemsPage", function () { + + var page = this; var limit = LibraryBrowser.getDefaultPageSize(); // If the default page size has changed, the start index will have to be reset @@ -77,11 +162,9 @@ LibraryBrowser.loadSavedQueryValues(getSavedQueryId(), query); - reloadItems(this); + reloadItems(page); - }).on('pageshow', "#channelItemsPage", function () { - - updateFilterControls(this); + updateFilterControls(page); }); })(jQuery, document); \ No newline at end of file diff --git a/dashboard-ui/scripts/channels.js b/dashboard-ui/scripts/channels.js index bb018c0bab..3ad0d4d5ee 100644 --- a/dashboard-ui/scripts/channels.js +++ b/dashboard-ui/scripts/channels.js @@ -25,10 +25,11 @@ html = LibraryBrowser.getPosterViewHtml({ items: result.Items, - shape: "square", + shape: "backdrop", context: 'channels', showTitle: true, - centerText: true + centerText: true, + preferThumb: true }); $('#items', page).html(html).trigger('create').createPosterItemMenus(); diff --git a/dashboard-ui/scripts/itemdetailpage.js b/dashboard-ui/scripts/itemdetailpage.js index 472a8746ef..94a8a96569 100644 --- a/dashboard-ui/scripts/itemdetailpage.js +++ b/dashboard-ui/scripts/itemdetailpage.js @@ -457,7 +457,7 @@ AdjacentTo: item.Id }); } - else if (item.Type == "Episode") { + else if (item.Type == "Episode" && item.SeasonId) { // Use dedicated episodes endpoint promise = ApiClient.getEpisodes(item.SeriesId, { diff --git a/dashboard-ui/scripts/librarymenu.js b/dashboard-ui/scripts/librarymenu.js index 68dabe3acc..0208b21d47 100644 --- a/dashboard-ui/scripts/librarymenu.js +++ b/dashboard-ui/scripts/librarymenu.js @@ -68,7 +68,7 @@ function getItemHref(item) { - if (item.Type == 'ManualCollectionsFolder' || item.CollectionType == 'boxsets') { + if (item.Type == 'ManualCollectionsFolder') { return 'collections.html?topParentId=' + item.Id; } @@ -106,7 +106,7 @@ }).join(''); if (counts.ChannelCount) { - html += 'Channels'; + html += 'Channels'; } if (liveTvInfo.EnabledUsers.indexOf(user.Id) != -1) { @@ -155,7 +155,7 @@ }).join(''); if (counts.ChannelCount) { - html += '
  • Channels
  • '; + html += '
  • Channels
  • '; } if (liveTvInfo.EnabledUsers.indexOf(Dashboard.getCurrentUserId()) != -1) { @@ -203,8 +203,9 @@ page = $(page); var isLiveTvPage = page.hasClass('liveTvPage'); - - var id = isLiveTvPage || page.hasClass('noLibraryMenuSelectionPage') ? + var isChannelsPage = page.hasClass('channelsPage'); + + var id = isLiveTvPage || isChannelsPage || page.hasClass('noLibraryMenuSelectionPage') ? '' : getTopParentId() || ''; @@ -214,7 +215,10 @@ var itemId = this.getAttribute('data-itemid'); - if (isLiveTvPage && itemId == 'livetv') { + if (isChannelsPage && itemId == 'channels') { + $(this).addClass('selectedMediaFolder'); + } + else if (isLiveTvPage && itemId == 'livetv') { $(this).addClass('selectedMediaFolder'); } else if (id && itemId == id) { diff --git a/dashboard-ui/scripts/musicvideos.js b/dashboard-ui/scripts/musicvideos.js index b9a64f3738..ced2dc98d9 100644 --- a/dashboard-ui/scripts/musicvideos.js +++ b/dashboard-ui/scripts/musicvideos.js @@ -215,7 +215,7 @@ }).on('pagebeforeshow', "#musicVideosPage", function () { - query.ParentId = LibraryMenu.getTopParentId(); + //query.ParentId = LibraryMenu.getTopParentId(); var limit = LibraryBrowser.getDefaultPageSize(); diff --git a/dashboard-ui/scripts/plugincatalogpage.js b/dashboard-ui/scripts/plugincatalogpage.js index dea89b40b4..294db481db 100644 --- a/dashboard-ui/scripts/plugincatalogpage.js +++ b/dashboard-ui/scripts/plugincatalogpage.js @@ -70,14 +70,22 @@ var category = plugin.category || "General"; if (category != currentCategory) { - html += '

    ' + category + '

    '; + + if (currentCategory) { + html += '
    '; + html += '
    '; + html += '
    '; + } + + html += '

    ' + category + '

    '; + currentCategory = category; } var href = plugin.externalUrl ? plugin.externalUrl : "addplugin.html?name=" + encodeURIComponent(plugin.name) + "&guid=" + plugin.guid; var target = plugin.externalUrl ? ' target="_blank"' : ''; - html += ""; + html += ""; if (plugin.thumbImage) { html += '
    '; @@ -94,21 +102,13 @@ } html += "
    "; - html += "
    "; + html += "
    "; - var installedPlugin = plugin.isApp ? null : installedPlugins.filter(function (ip) { - return ip.Name == plugin.name; - })[0]; + html += plugin.name; - if (installedPlugin) { - html += plugin.name; - } else { - html += plugin.name; - } - html += "
    "; - html += "
    "; + html += "
    "; html += plugin.price > 0 ? "$" + plugin.price.toFixed(2) : "Free"; html += Dashboard.getStoreRatingHtml(plugin.avgRating, plugin.id, plugin.name); @@ -117,6 +117,20 @@ html += ""; html += "
    "; + + var installedPlugin = plugin.isApp ? null : installedPlugins.filter(function (ip) { + return ip.Name == plugin.name; + })[0]; + + html += "
    "; + + if (installedPlugin) { + html += installedPlugin.Version + ' installed'; + } else { + html += ' '; + } + html += "
    "; + html += "
    "; pluginhtml += html; diff --git a/dashboard-ui/scripts/userparentalcontrol.js b/dashboard-ui/scripts/userparentalcontrol.js index 4887361ada..3eb3f20e3e 100644 --- a/dashboard-ui/scripts/userparentalcontrol.js +++ b/dashboard-ui/scripts/userparentalcontrol.js @@ -60,7 +60,38 @@ html += ''; - $('.libraryAccess', page).html(html).trigger('create'); + $('.mediaFolderAccess', page).html(html).trigger('create'); + } + + function loadChannels(page, user, channels) { + + var html = ''; + + html += '
    '; + + html += 'Channels'; + + for (var i = 0, length = channels.length; i < length; i++) { + + var folder = channels[i]; + + var id = 'channels' + i; + + var checkedAttribute = user.Configuration.BlockedChannels.indexOf(folder.Name) == -1 ? ' checked="checked"' : ''; + + html += ''; + html += ''; + } + + html += '
    '; + + $('.channelAccess', page).show().html(html).trigger('create'); + + if (channels.length) { + $('.channelAccessContainer', page).show(); + } else { + $('.channelAccessContainer', page).hide(); + } } function loadUnratedItems(page, user) { @@ -68,6 +99,7 @@ var items = [ { name: 'Books', value: 'Book' }, { name: 'Games', value: 'Game' }, + { name: 'Internet Channel Content', value: 'ChannelContent' }, { name: 'Live TV Channels', value: 'LiveTvChannel' }, { name: 'Live TV Programs', value: 'LiveTvProgram' }, { name: 'Movies', value: 'Movie' }, @@ -100,10 +132,11 @@ $('.blockUnratedItems', page).html(html).trigger('create'); } - function loadUser(page, user, loggedInUser, allParentalRatings, mediaFolders) { + function loadUser(page, user, loggedInUser, allParentalRatings, mediaFolders, channels) { Dashboard.setPageTitle(user.Name); + loadChannels(page, user, channels); loadMediaFolders(page, user, mediaFolders); loadUnratedItems(page, user); @@ -147,6 +180,12 @@ }).get(); + user.Configuration.BlockedChannels = $('.chkChannel:not(:checked)', page).map(function () { + + return this.getAttribute('data-foldername'); + + }).get(); + user.Configuration.BlockUnratedItems = $('.chkUnratedItem:checked', page).map(function () { return this.getAttribute('data-itemtype'); @@ -207,9 +246,11 @@ var promise4 = $.getJSON(ApiClient.getUrl("Library/MediaFolders")); - $.when(promise1, promise2, promise3, promise4).done(function (response1, response2, response3, response4) { + var promise5 = $.getJSON(ApiClient.getUrl("Channels")); - loadUser(page, response1[0] || response1, response2[0], response3[0], response4[0].Items); + $.when(promise1, promise2, promise3, promise4, promise5).done(function (response1, response2, response3, response4, response5) { + + loadUser(page, response1[0] || response1, response2[0], response3[0], response4[0].Items, response5[0].Items); }); }); diff --git a/dashboard-ui/userparentalcontrol.html b/dashboard-ui/userparentalcontrol.html index eece41a22f..8b40ce2a5e 100644 --- a/dashboard-ui/userparentalcontrol.html +++ b/dashboard-ui/userparentalcontrol.html @@ -18,11 +18,18 @@
    -
    +
    ${LibraryAccessHelp}

    + +
    +
    +
    +
    ${ChannelAccessHelp}
    +
    +