');
}
if (!mainImg && sc.media["10"] && this.serieImgPath)
mainImg = this.serieImgPath + sc.seriesid + '&season_number=' + terms.seasonnumber + '&episode_id=' + terms.episodeid + '&media_type=10&maxW=270&maxH=146';
if (sc.media["7"])
firstImg = this.serieImgPath + sc.seriesid + '&season_number=0&episode_id=0&media_type=7&maxW=400&maxh=999';
if (sc.seriesoverview)
desc += desc ? '
'
+ '
'
+ (sc.media["1"] && this.serieImgPath ? ' |
' : '')
+ (sc.media["10"] && this.serieImgPath ? ' |
' : '')
+ (sc.seriesname ? '' + tr.title + ' | ' + sc.seriesname + ' |
' : '')
+ (sc.seriesnetwork ? '' + tr.network + ' | ' + sc.seriesnetwork + ' |
' : '')
+ (sc.seriesstatus ? '' + tr.seriesstatus + ' | ' + sc.seriesstatus + ' |
' : '')
+ (sc.seriesfirstaired ? '' + tr.release_date + ' | ' + sc.seriesfirstaired + ' |
' : '')
+ (sc.seriesgenre ? '' + tr.genre + ' | ' + sc.seriesgenre.replace(/^\||\|$/g, '').replace(/ ?\| ?/g, ', ') + ' |
' : '')
+ (sc.seriesrating ? '' + tr.vote_average + ' | (' + sc.seriesrating.toFixed(1) + ' / 10) |
' : '')
+ extInfo
+ (epgd.profile.serieSeasonPath ? '' + tr.homepage + ' |
' : '')
+ '
'
+ (sc.media["6"] && this.serieImgPath ? '
' : '')
+ (sc.media["3"] && this.serieImgPath ? '
' : '');
}
} else {
sc = {};
extInfo = '
' + tr.extentedInfo + '
'
+ '' + tr.title + ' | ' + e.title + ' |
'
+ (ep.partname ? '' + tr.part + ' | ' + ep.partname + ' |
' : '')
+ (e.year ? '' + tr.release_date + ' | ' + e.year + ' |
' : '')
+ (ep.lang ? '' + tr.lang + ' | ' + ep.lang + ' |
' : '')
+ extInfo
+ '
';
}
if (!actors && e.actor)
actors = e.actor.replace(/, /g, '
');
actors && (extInfo += '
' + tr.actors + '
' + actors + '');
extInfo && (extInfo += '
');
info1 = (e.path ? epgd.tr.pages.timerList.folder + '
' + e.path.replace(/\//g, ' / ') + '
' : '')
+ (e.genre ? (tr.genre + '
' + e.genre + '') : '')
+ (e.category ? tr.category + '
' + e.category + '' : '')
+ (e.country ? tr.country + '
' + e.country + '' : '')
+ (e.year ? tr.year + '
' + e.year + '' : '');
info2 = (ep.part ? tr.part + '
' + ep.part + (ep.parts ? ' / ' + ep.parts + '' : '') + '' : '')
+ (ep.season ? tr.season + '
' + ep.season + '' : '')
+ (ep.number ? tr.number + '
' + ep.number + '' : '');
/*
e.recordings = [
{
"matchdensityshorttext": 12,
"owner": "7F13E490-09B3-401C-B26C-8B7F2F111014",
"name": "Star Wars: Episode III - Die Rache der Sith",
"duration": 10736,
"path": "Die_Biene_Maja/S03E04/2014-03-23.06.53.29-0.rec",
"md5path": "f6abd21ea13f52626723b3321c7a8c42",
"matchdensitytitle": 68,
"starttime": 1395553980,
"title": "Star Wars: Episode III - Die Rache der Sith",
"shorttext": "Science-Fiction (USA 2005)"
},
{
"matchdensityshorttext": 48,
"owner": "7F13E490-09B3-401C-B26C-8B7F2F111014",
"name": "Star Wars: Das Erwachen der Macht",
"duration": 8783,
"path": "Das_Traumhotel/2016-05-15.18.28.64-0.rec",
"md5path": "0279b0d04b68e891ef2b7e6d8bcdd059",
"matchdensitytitle": 70,
"starttime": 1463329680,
"title": "Star Wars: Das Erwachen der Macht",
"sho__rttext": "Star Wars - Episode VII: The Force Awakens"
}
];
*/
if (e.recordings)
for (i in e.recordings) {
terms= e.recordings[i];
recordings += '
'
+ '
' + epgd.utils.formatDateTime(terms.starttime) + '' + parseInt(terms.duration / 60, 10) + ' ' + epgd.tr.minutes
+ ''
+ '' + terms.title
+ (terms.shorttext ? '' + terms.shorttext + '' : '')
+ '';
}
this.$con = $('
' + $.datepicker.formatDate(isMobile ? 'd. M y' : 'd. MM yy', epgd.utils.date(e.starttime)) + '
'
+ (isMobile ? '' : e.title) + ''
+ epgd.utils.formatTime(e.starttime) + ' – ' + epgd.utils.formatTime(e.starttime + e.duration)
+ ' ' + epgd.tr.oClock + ' | ' + parseInt(e.duration / 60, 10) + ' ' + epgd.tr.minutes + '
'
+ '
'
+ '
'
+ '
' + (mainImg ? '
' : '') + '
'
+ '
'
+ epgd.channels.getHtml(e.channelid)
+ (progress > 0 && progress <= 100 ? '
' : '')
+ '
'
+ (e.flags && e.flags.indexOf('16:9') > 0 ? '
' : '')
+ (e.audio && e.audio.indexOf('DolbyDigital') >= 0 ? '
' : '')
+ (e.flags && e.flags.indexOf('Live') > 0 ? 'Live' : '')
+ (e.parentalrating ? '
' + tr.parentalrating + e.parentalrating + '
' : '')
+ '
'
+ (e.merge ? '
' + tr.mergeSrc + e.merge + '
' : '')
+ '
'
+ (stars ? '
' + stars + '
' : '')
+ '
'
+ e.title + (ep.partname ? '
' + ep.partname + '' : (e.shorttext ? '
' + e.shorttext + '' : ''))
+ '
'
+ (e.tipp ? '' + e.tipp + '' : '')
+ (e.txtrating ? '' + e.txtrating + '' : '')
+ (e.shortreview || '')
+ '
'
+ (info1 ? '
' + info1 + '
': '')
+ (info2 ? '
' + info2 + '
' : '')
+ (firstImg ? '
' : '')
+ '
'
+ '
' + (desc ? desc.replace(/\n/g, '
') : '') + '
'
+ '
'
+ extInfo
+ (e.category == 'Serie' || sc.isSerie ? '
' + tr.constabelInfo + '
'
: '')
+ (recordings ? '
' + epgd.tr.menu.records + '
' + recordings + '
' : '')
+ '
').replaceAll(this.$con);
this.$con.accordion({
heightStyle: "fill",
header: "h3",
active: 0,
beforeActivate: function(ev, ui){
if (ui.newHeader.attr('data-conti')) {
epgd.utils.loader.process(function () {
epgd.ajax({ url: epgd.login.url + 'data/proxy?id=constabel&title=' + encodeURIComponent(encodeURIComponent(ui.newHeader.attr('data-conti'))) + '&_' + new Date().getTime(), dataType: "html", contentType: "text/plain; charset=utf-8" }, function (data) {
if (data.indexOf('Error:') == -1) {
var $pre = ui.newPanel.find('#cRaw'),
thead = '
' + tr.season + ' | ' + tr.part + ' | ' + tr.number + ' | ' + tr.title + ' | ',
tbody = '
',
lines = data.split(/\r?\n/),
line, m, i;
for (i = 0; i < lines.length; i++) {
line = lines[i];
if (line.charAt(0) == '#') {
m = line.match(/EXTRACOL[0-9] (.+)/i);
if (m)
thead += '' + m[1] + ' | ';
} else {
m = line.split(/\t/);
if (m.length > 3)
tbody += '' + m.join(' | ') + ' |
';
}
}
$pre.html(data).hide().before('Raw');
$pre.before('' + thead + '' + tbody + '
');
} else
ui.newPanel.find('#cRaw').html(epgd.tr.error.noData);
epgd.utils.loader.close();
});
ui.newHeader.removeAttr('data-conti');
},true);
}
}
});
this.$rec.toggleClass("hasTimer", !!e.timerid).prop("title", this.detail.doRecord(true));
this.$play.toggle(this.detail.doPlay(true));
this.$prev.toggle(this.detail.doPrev(true));
this.$next.toggle(this.detail.doNext(true));
this.$con.find('.channel .i-tv').click(function () { epgd.vdrs.current.switchChannel(this.parentNode.id); });
//this.$win.position({ of: window });
this.closed = false;
i = Math.max.apply(null, this.$win.siblings(".ui-front:visible").map(function () {
return +$(this).css("z-index");
}).get()); // zIndexMax
if (i >= +this.$win.css("z-index"))
this.$win.css("z-index", i + 1);
$(window).trigger("resize.eventDetail");
this.$openDialogs = $('.ui-dialog:visible:not(.ui-state-disabled)').addClass("ui-state-disabled");
$(document).bind("keyup.eventDetail", function (e) {
if (e.keyCode == 27) {
$(window).trigger("epgd_close.eventDetail");
}
});
epgd.pages.help.initButtons(this.$con);
}
epgd.recordDetail = epgd.utils.inherits(function (elem) {
this.elem = elem;
return epgd.eventDetail.call(this);
}, epgd.eventDetail);
epgd.recordDetail.prototype.load = function () {
var self = this;
epgd.ajax({
url: epgd.login.url + 'data/recording?starttime=' + this.elem.getAttribute('data-start') + '&md5path=' + this.elem.getAttribute('data-md5') + '&owner=' + this.elem.getAttribute('data-owner'), async: false
}, function (data) {
self.data = data.recording;
});
return this;
}
epgd.recordDetail.prototype.doRecord = function (eData) {
if (eData === true) return epgd.tr.pages.records.similarTimer; // eData = getTitle
epgd.eventDetail.prototype.doRecord.call(this, eData);
}
epgd.recordDetail.prototype.doPlay = function (checkAvail) {
if (checkAvail) return true;
epgd.ajax({ url: epgd.login.url + 'data/replayrecording?vdruuid=' + ( !epgd.vdrs.list[this.data.vdruuid].usecommonrecfolder ? this.data.vdruuid : epgd.vdrs.current.uuid ) + '&starttime=' + this.data.starttime + '&md5path=' + this.data.md5path + '&owner=' + (this.data.owner || ''), cache: false }, function (data) {
epgd.utils.popup(data.result.message, { title: 'VDR', autoClose: 5000 });
});
}
epgd.recordDetail.prototype.doPrev = function (checkAvail) {
var $elem = $(this.elem).prev('.rec');
if (!$elem.length)
return false;
if (checkAvail) return true;
$elem.find('B').click();
}
epgd.recordDetail.prototype.doNext = function (checkAvail) {
var $elem = $(this.elem).next('.rec');
if (!$elem.length)
return false;
if (checkAvail) return true;
$elem.find('B').click();
}
epgd.doneTimerDetail = epgd.utils.inherits(function (tr) {
this.tr = tr;
return epgd.eventDetail.call(this);
}, epgd.eventDetail);
epgd.doneTimerDetail.prototype.load= function () {
var self = this;
epgd.ajax({ url: epgd.login.url + 'data/donetimer?id=' + this.tr.tData.id, async: false, cache: false }, function (data) {
var t = data.donetimer;
if (t.state)
t.cntlongdescription = epgd.pages.timerListDone.stateIcons[t.state];
t.episode = { lang: t.episodelang, season: t.episodeseason, part: t.episodepart };
self.id = data.id;
self.expire = epgd.utils.now().getTime() + 900000;
delete t.timerid;
delete t.id;
self.data = t;
});
return this;
};
epgd.doneTimerDetail.prototype.doRecord= function (eData) {
if (eData === true) return epgd.tr.pages.records.similarTimer;
epgd.eventDetail.prototype.doRecord.call(this, eData);
//epgd.pages.searchTimerList.dialog.render(eData || this.data);
};
epgd.doneTimerDetail.prototype.doPlay= function (checkAvail) {
return false;
};
epgd.doneTimerDetail.prototype.doPrev= function (checkAvail) {
var $elem = $(this.tr).prev('tr');
if (!$elem.length)
return false;
if (checkAvail) return true;
$elem.find('td').click();
};
epgd.doneTimerDetail.prototype.doNext= function (checkAvail) {
var $elem = $(this.tr).next('tr');
if (!$elem.length)
return false;
if (checkAvail) return true;
$elem.find('td').click();
};
$(document).ready(function () {
epgd.eventDetail.prototype.win = new epgd.eventDetail.win();
});