2014-10-15 20:26:39 -07:00
|
|
|
|
(function ($, document) {
|
2014-01-12 08:58:47 -07:00
|
|
|
|
|
|
|
|
|
function reload(page) {
|
|
|
|
|
|
|
|
|
|
Dashboard.showLoadingMsg();
|
|
|
|
|
|
2014-10-15 20:26:39 -07:00
|
|
|
|
ApiClient.getLiveTvRecommendedPrograms({
|
2014-01-12 08:58:47 -07:00
|
|
|
|
|
|
|
|
|
userId: Dashboard.getCurrentUserId(),
|
|
|
|
|
IsAiring: true,
|
2015-03-14 13:56:50 -07:00
|
|
|
|
limit: 16
|
2014-01-12 08:58:47 -07:00
|
|
|
|
|
|
|
|
|
}).done(function (result) {
|
2014-05-09 12:43:06 -07:00
|
|
|
|
|
2014-01-12 08:58:47 -07:00
|
|
|
|
var html = LibraryBrowser.getPosterViewHtml({
|
|
|
|
|
|
|
|
|
|
items: result.Items,
|
2015-03-14 13:56:50 -07:00
|
|
|
|
shape: "auto",
|
2014-01-12 08:58:47 -07:00
|
|
|
|
showTitle: true,
|
|
|
|
|
showParentTitle: true,
|
2014-08-01 19:34:45 -07:00
|
|
|
|
overlayText: true,
|
2015-01-22 23:15:15 -07:00
|
|
|
|
coverImage: true,
|
|
|
|
|
lazy: true
|
2014-01-12 08:58:47 -07:00
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
2015-01-22 23:15:15 -07:00
|
|
|
|
$('.activeProgramItems', page).html(html).lazyChildren();
|
2014-01-12 08:58:47 -07:00
|
|
|
|
});
|
|
|
|
|
|
2014-10-15 20:26:39 -07:00
|
|
|
|
ApiClient.getLiveTvRecommendedPrograms({
|
2014-01-12 08:58:47 -07:00
|
|
|
|
|
|
|
|
|
userId: Dashboard.getCurrentUserId(),
|
|
|
|
|
IsAiring: false,
|
|
|
|
|
HasAired: false,
|
2015-03-14 13:56:50 -07:00
|
|
|
|
limit: 10,
|
|
|
|
|
IsMovie: false
|
2014-01-12 08:58:47 -07:00
|
|
|
|
|
|
|
|
|
}).done(function (result) {
|
|
|
|
|
|
|
|
|
|
var html = LibraryBrowser.getPosterViewHtml({
|
|
|
|
|
|
|
|
|
|
items: result.Items,
|
2015-03-14 13:56:50 -07:00
|
|
|
|
shape: "auto",
|
2014-01-12 08:58:47 -07:00
|
|
|
|
showTitle: true,
|
|
|
|
|
showParentTitle: true,
|
2014-08-01 19:34:45 -07:00
|
|
|
|
overlayText: true,
|
2015-01-22 23:15:15 -07:00
|
|
|
|
coverImage: true,
|
|
|
|
|
lazy: true
|
2014-01-12 08:58:47 -07:00
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
2015-01-22 23:15:15 -07:00
|
|
|
|
$('.upcomingProgramItems', page).html(html).lazyChildren();
|
2014-01-12 08:58:47 -07:00
|
|
|
|
});
|
2015-03-14 13:56:50 -07:00
|
|
|
|
|
|
|
|
|
ApiClient.getLiveTvRecommendedPrograms({
|
|
|
|
|
|
|
|
|
|
userId: Dashboard.getCurrentUserId(),
|
|
|
|
|
IsAiring: false,
|
|
|
|
|
HasAired: false,
|
|
|
|
|
limit: 10,
|
|
|
|
|
IsMovie: true
|
|
|
|
|
|
|
|
|
|
}).done(function (result) {
|
|
|
|
|
|
|
|
|
|
var html = LibraryBrowser.getPosterViewHtml({
|
|
|
|
|
items: result.Items,
|
|
|
|
|
shape: "auto",
|
|
|
|
|
showTitle: true,
|
|
|
|
|
coverImage: true,
|
|
|
|
|
overlayText: false,
|
|
|
|
|
lazy: true
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
$('.upcomingTvMovieItems', page).html(html).lazyChildren();
|
|
|
|
|
});
|
2014-01-12 08:58:47 -07:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$(document).on('pagebeforeshow', "#liveTvSuggestedPage", function () {
|
|
|
|
|
|
|
|
|
|
var page = this;
|
|
|
|
|
|
|
|
|
|
reload(page);
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
2014-10-15 20:26:39 -07:00
|
|
|
|
})(jQuery, document);
|