mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
display new fields on person page
This commit is contained in:
parent
8785935d23
commit
0d19fce987
4 changed files with 50 additions and 20 deletions
|
@ -52,6 +52,33 @@
|
|||
|
||||
renderUserDataIcons(page, item);
|
||||
renderLinks(page, item);
|
||||
|
||||
if (item.Type == "Person" && item.PremiereDate) {
|
||||
|
||||
var birthday = parseISO8601Date(item.PremiereDate, { toLocal: true }).toDateString();
|
||||
|
||||
$('#itemBirthday', page).show().html("Birthday: " + birthday);
|
||||
} else {
|
||||
$('#itemBirthday', page).hide();
|
||||
}
|
||||
|
||||
if (item.Type == "Person" && item.EndDate) {
|
||||
|
||||
var deathday = parseISO8601Date(item.EndDate, { toLocal: true }).toDateString();
|
||||
|
||||
$('#itemDeathDate', page).show().html("Death day: " + deathday);
|
||||
} else {
|
||||
$('#itemDeathDate', page).hide();
|
||||
}
|
||||
|
||||
if (item.Type == "Person" && item.ProductionLocations && item.ProductionLocations.length) {
|
||||
|
||||
var gmap = '<a target="_blank" href="https://maps.google.com/maps?q=' + item.ProductionLocations[0] + '">' + item.ProductionLocations[0] + '</a>';
|
||||
|
||||
$('#itemBirthLocation', page).show().html("Birth place: " + gmap).trigger('create');
|
||||
} else {
|
||||
$('#itemBirthLocation', page).hide();
|
||||
}
|
||||
}
|
||||
|
||||
function renderLinks(page, item) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue