display tags on detail page

This commit is contained in:
Luke Pulverenti 2013-05-06 23:00:24 -04:00
parent 3f433b3b61
commit 1c484b486b
4 changed files with 34 additions and 9 deletions

View File

@ -279,6 +279,11 @@ namespace MediaBrowser.Controller.Dto
dto.HomePageUrl = item.HomePageUrl;
}
if (fields.Contains(ItemFields.Tags))
{
dto.Tags = item.Tags;
}
if (fields.Contains(ItemFields.ProductionLocations))
{
dto.ProductionLocations = item.ProductionLocations;

View File

@ -932,22 +932,31 @@ namespace MediaBrowser.Controller.Providers.Movies
movie.OfficialRating = ourRelease.certification ?? usRelease.certification;
if (ourRelease.release_date > new DateTime(1900, 1, 1))
{
if (ourRelease.release_date.Year != 1)
{
movie.PremiereDate = ourRelease.release_date.ToUniversalTime();
movie.ProductionYear = ourRelease.release_date.Year;
}
}
else
{
if (usRelease.release_date.Year != 1)
{
movie.PremiereDate = usRelease.release_date.ToUniversalTime();
movie.ProductionYear = usRelease.release_date.Year;
}
}
}
else
{
if (movieData.release_date.Year != 1)
{
//no specific country release info at all
movie.PremiereDate = movieData.release_date.ToUniversalTime();
movie.ProductionYear = movieData.release_date.Year;
}
}
//if that didn't find a rating and we are a boxset, use the one from our first child
if (movie.OfficialRating == null && movie is BoxSet)
@ -960,8 +969,8 @@ namespace MediaBrowser.Controller.Providers.Movies
boxset.OfficialRating = firstChild != null ? firstChild.OfficialRating : null;
}
//if (movie.RunTimeTicks == null && movieData.runtime > 0)
// movie.RunTimeTicks = TimeSpan.FromMinutes(movieData.runtime).Ticks;
if (movie.RunTimeTicks == null && movieData.runtime > 0)
movie.RunTimeTicks = TimeSpan.FromMinutes(movieData.runtime).Ticks;
//studios
if (movieData.production_companies != null)

View File

@ -276,6 +276,12 @@ namespace MediaBrowser.Model.Dto
/// <value>The index options.</value>
public string[] IndexOptions { get; set; }
/// <summary>
/// Gets or sets the tags.
/// </summary>
/// <value>The tags.</value>
public List<string> Tags { get; set; }
/// <summary>
/// Gets or sets the primary image aspect ratio.
/// </summary>

View File

@ -131,6 +131,11 @@ namespace MediaBrowser.Model.Querying
/// </summary>
Taglines,
/// <summary>
/// The tags
/// </summary>
Tags,
/// <summary>
/// The trailer url of the item
/// </summary>