diff options
| author | Vasily <JustAMan@users.noreply.github.com> | 2020-05-15 22:04:23 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-05-15 22:04:23 +0300 |
| commit | d21feb2b188b0b317f0d12ff2aea9f48f4a4c2e0 (patch) | |
| tree | f4cc08dd0f8f19dbd003a4814fb496b061d2ec32 /MediaBrowser.Model/Activity | |
| parent | 18953d95e6692290bf56547d4c9614790687654c (diff) | |
| parent | 79dee27299bda60f67e98eda8c309b1f25e0893b (diff) | |
Merge pull request #2970 from barronpm/activitydb-efcore
Migrate Activity Database to Entity Framework Core
Diffstat (limited to 'MediaBrowser.Model/Activity')
| -rw-r--r-- | MediaBrowser.Model/Activity/ActivityLogEntry.cs | 1 | ||||
| -rw-r--r-- | MediaBrowser.Model/Activity/IActivityManager.cs | 14 | ||||
| -rw-r--r-- | MediaBrowser.Model/Activity/IActivityRepository.cs | 14 |
3 files changed, 12 insertions, 17 deletions
diff --git a/MediaBrowser.Model/Activity/ActivityLogEntry.cs b/MediaBrowser.Model/Activity/ActivityLogEntry.cs index 80f01b66ee..5ab904394e 100644 --- a/MediaBrowser.Model/Activity/ActivityLogEntry.cs +++ b/MediaBrowser.Model/Activity/ActivityLogEntry.cs @@ -59,6 +59,7 @@ namespace MediaBrowser.Model.Activity /// Gets or sets the user primary image tag. /// </summary> /// <value>The user primary image tag.</value> + [Obsolete("UserPrimaryImageTag is not used.")] public string UserPrimaryImageTag { get; set; } /// <summary> diff --git a/MediaBrowser.Model/Activity/IActivityManager.cs b/MediaBrowser.Model/Activity/IActivityManager.cs index f336f5272c..9dab5e77b7 100644 --- a/MediaBrowser.Model/Activity/IActivityManager.cs +++ b/MediaBrowser.Model/Activity/IActivityManager.cs @@ -1,6 +1,9 @@ #pragma warning disable CS1591 using System; +using System.Linq; +using System.Threading.Tasks; +using Jellyfin.Data.Entities; using MediaBrowser.Model.Events; using MediaBrowser.Model.Querying; @@ -10,10 +13,15 @@ namespace MediaBrowser.Model.Activity { event EventHandler<GenericEventArgs<ActivityLogEntry>> EntryCreated; - void Create(ActivityLogEntry entry); + void Create(ActivityLog entry); - QueryResult<ActivityLogEntry> GetActivityLogEntries(DateTime? minDate, int? startIndex, int? limit); + Task CreateAsync(ActivityLog entry); - QueryResult<ActivityLogEntry> GetActivityLogEntries(DateTime? minDate, bool? hasUserId, int? x, int? y); + QueryResult<ActivityLogEntry> GetPagedResult(int? startIndex, int? limit); + + QueryResult<ActivityLogEntry> GetPagedResult( + Func<IQueryable<ActivityLog>, IQueryable<ActivityLog>> func, + int? startIndex, + int? limit); } } diff --git a/MediaBrowser.Model/Activity/IActivityRepository.cs b/MediaBrowser.Model/Activity/IActivityRepository.cs deleted file mode 100644 index 66144ec478..0000000000 --- a/MediaBrowser.Model/Activity/IActivityRepository.cs +++ /dev/null @@ -1,14 +0,0 @@ -#pragma warning disable CS1591 - -using System; -using MediaBrowser.Model.Querying; - -namespace MediaBrowser.Model.Activity -{ - public interface IActivityRepository - { - void Create(ActivityLogEntry entry); - - QueryResult<ActivityLogEntry> GetActivityLogEntries(DateTime? minDate, bool? z, int? startIndex, int? limit); - } -} |
