fixes #397 - WB web client - Missing person metadata field

This commit is contained in:
Luke Pulverenti 2013-07-29 14:33:48 -04:00
parent 86df2296f7
commit 84b60a8672
3 changed files with 21 additions and 5 deletions

View File

@ -87,6 +87,10 @@
<label id="lblYear" for="txtProductionYear">Year:</label>
<input type="number" id="txtProductionYear" name="txtProductionYear" data-mini="true" />
</div>
<div data-role="fieldcontain" id="fldPlaceOfBirth" style="display: none;">
<label for="txtPlaceOfBirth">Place of birth:</label>
<input type="text" id="txtPlaceOfBirth" name="txtPlaceOfBirth" data-mini="true" />
</div>
<div data-role="fieldcontain" id="fldEndDate" style="display: none;">
<label id="lblEndDate" for="txtEndDate">End date:</label>
<input type="date" id="txtEndDate" name="txtEndDate" data-mini="true" />

View File

@ -69,7 +69,7 @@
setFieldVisibilities(page, item);
fillItemInfo(page, item);
if (item.Type == "Person" || item.Type == "Studio" || item.Type == "MusicGenre" || item.Type == "Genre" || item.Type == "Artist") {
$('#peopleTab', page).hide();
} else {
@ -143,7 +143,7 @@
} else {
$('#fldTvCom', page).hide();
}
if (item.Type == "Series") {
$('#fldStatus', page).show();
$('#fldAirDays', page).show();
@ -210,10 +210,12 @@
$('#lblPremiereDate', page).html('Date of birth');
$('#lblYear', page).html('Birth year');
$('#lblEndDate', page).html('Death date');
$('#fldPlaceOfBirth', page).show();
} else {
$('#lblPremiereDate', page).html('Release date');
$('#lblYear', page).html('Year');
$('#lblEndDate', page).html('End date');
$('#fldPlaceOfBirth', page).hide();
}
if (item.MediaType == "Video") {
@ -356,6 +358,9 @@
$('#txtProductionYear', page).val(item.ProductionYear || "");
$('#txtAirTime', page).val(convertTo24HourFormat(item.AirTime || ""));
var placeofBirth = item.ProductionLocations && item.ProductionLocations.length ? item.ProductionLocations[0] : '';
$('#txtPlaceOfBirth', page).val(placeofBirth);
$('#txtOriginalAspectRatio', page).val(item.AspectRatio || "");
var providerIds = item.ProviderIds || {};
@ -542,8 +547,8 @@
Tags: editableListViewValues($("#listTags", form)),
Studios: editableListViewValues($("#listStudios", form)).map(function (element) { return { Name: element }; }),
PremiereDate: $('#txtPremiereDate', form).val(),
EndDate: $('#txtEndDate', form).val(),
PremiereDate: $('#txtPremiereDate', form).val() || null,
EndDate: $('#txtEndDate', form).val() || null ,
ProductionYear: $('#txtProductionYear', form).val(),
AspectRatio: $('#txtOriginalAspectRatio', form).val(),
Video3DFormat: $('#select3dFormat', form).val(),
@ -571,6 +576,13 @@
}
};
if (currentItem.Type == "Person") {
var placeOfBirth = $('#txtPlaceOfBirth', form).val();
item.ProductionLocations = placeOfBirth ? [placeOfBirth] : [];
}
var updatePromise;
if (currentItem.Type == "Artist") {

View File

@ -3,7 +3,7 @@
function reloadTips(page) {
var tips = [
'Did you know that editing the artist or album of a music video will allow it to appear on the artist page?',
'Did you know that editing the artist or album of a music video will allow it to appear on the artist and album pages?',
'Did you know that editing the tmdb id, tvdb id, and/or games db id of an album will allow media browser to link it to a movie, series or game as a soundtrack?',
'Did you know that you can re-order your media collections by editing their sort names?',
'Did you know that series, seasons, games and boxsets can have local trailers?',