aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Controller/Entities
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2013-11-22 10:33:14 -0500
committerLuke Pulverenti <luke.pulverenti@gmail.com>2013-11-22 10:33:14 -0500
commit16203c52b4855b8474d5393ceebe1b7d85ce37fc (patch)
treecc8c059fd0aee1d9f13a24d8cb0bedcbcc7e8d06 /MediaBrowser.Controller/Entities
parentae63a3c2f79599bae9c82cf5f755a5641a5921ae (diff)
Added specialized episodes endpoint, updated nuget.
Diffstat (limited to 'MediaBrowser.Controller/Entities')
-rw-r--r--MediaBrowser.Controller/Entities/TV/Episode.cs27
1 files changed, 27 insertions, 0 deletions
diff --git a/MediaBrowser.Controller/Entities/TV/Episode.cs b/MediaBrowser.Controller/Entities/TV/Episode.cs
index c68ba0ad1..95ea10ea1 100644
--- a/MediaBrowser.Controller/Entities/TV/Episode.cs
+++ b/MediaBrowser.Controller/Entities/TV/Episode.cs
@@ -50,6 +50,33 @@ namespace MediaBrowser.Controller.Entities.TV
get { return true; }
}
+ [IgnoreDataMember]
+ public int? AiredSeasonNumber
+ {
+ get
+ {
+ return AirsBeforeSeasonNumber ?? AirsAfterSeasonNumber ?? PhysicalSeasonNumber;
+ }
+ }
+
+ [IgnoreDataMember]
+ public int? PhysicalSeasonNumber
+ {
+ get
+ {
+ var value = ParentIndexNumber;
+
+ if (value.HasValue)
+ {
+ return value;
+ }
+
+ var season = Parent as Season;
+
+ return season != null ? season.IndexNumber : null;
+ }
+ }
+
/// <summary>
/// We roll up into series
/// </summary>