From bd1bd5e87e1744b363279577a6550afc5f2229c1 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Tue, 14 Oct 2014 20:05:09 -0400 Subject: fixes #552 - Add parental control usage limits --- MediaBrowser.Model/Configuration/AccessSchedule.cs | 23 ++++++++++++++++++++++ .../Configuration/UserConfiguration.cs | 7 +++++-- 2 files changed, 28 insertions(+), 2 deletions(-) create mode 100644 MediaBrowser.Model/Configuration/AccessSchedule.cs (limited to 'MediaBrowser.Model/Configuration') diff --git a/MediaBrowser.Model/Configuration/AccessSchedule.cs b/MediaBrowser.Model/Configuration/AccessSchedule.cs new file mode 100644 index 0000000000..65f2f62917 --- /dev/null +++ b/MediaBrowser.Model/Configuration/AccessSchedule.cs @@ -0,0 +1,23 @@ +using System; + +namespace MediaBrowser.Model.Configuration +{ + public class AccessSchedule + { + /// + /// Gets or sets the day of week. + /// + /// The day of week. + public DayOfWeek DayOfWeek { get; set; } + /// + /// Gets or sets the start hour. + /// + /// The start hour. + public double StartHour { get; set; } + /// + /// Gets or sets the end hour. + /// + /// The end hour. + public double EndHour { get; set; } + } +} diff --git a/MediaBrowser.Model/Configuration/UserConfiguration.cs b/MediaBrowser.Model/Configuration/UserConfiguration.cs index 46eb0c7332..c162e389b0 100644 --- a/MediaBrowser.Model/Configuration/UserConfiguration.cs +++ b/MediaBrowser.Model/Configuration/UserConfiguration.cs @@ -66,7 +66,7 @@ namespace MediaBrowser.Model.Configuration public string[] BlockedChannels { get; set; } public string[] DisplayChannelsWithinViews { get; set; } - + public string[] ExcludeFoldersFromGrouping { get; set; } public UnratedItem[] BlockUnratedItems { get; set; } @@ -86,13 +86,14 @@ namespace MediaBrowser.Model.Configuration public bool EnableCinemaMode { get; set; } + public AccessSchedule[] AccessSchedules { get; set; } + /// /// Initializes a new instance of the class. /// public UserConfiguration() { PlayDefaultAudioTrack = true; - EnableRemoteControlOfOtherUsers = true; EnableLiveTvManagement = true; EnableMediaPlayback = true; EnableLiveTvAccess = true; @@ -111,6 +112,8 @@ namespace MediaBrowser.Model.Configuration SyncConnectImage = true; IncludeTrailersInSuggestions = true; EnableCinemaMode = true; + + AccessSchedules = new AccessSchedule[] { }; } } } -- cgit v1.2.3