From b41f887712ef8f2f0b602da3042261a78c5f492a Mon Sep 17 00:00:00 2001 From: transtrike Date: Mon, 1 Feb 2021 16:03:38 +0200 Subject: Commented out implementation of Rating; Bug fixes --- src/DevHive.Data/Interfaces/Models/IPost.cs | 2 +- src/DevHive.Data/Interfaces/Models/IRating.cs | 8 ++++---- src/DevHive.Data/Interfaces/Repositories/IRatingRepository.cs | 4 +--- 3 files changed, 6 insertions(+), 8 deletions(-) (limited to 'src/DevHive.Data/Interfaces') diff --git a/src/DevHive.Data/Interfaces/Models/IPost.cs b/src/DevHive.Data/Interfaces/Models/IPost.cs index 65c0fb4..5031a05 100644 --- a/src/DevHive.Data/Interfaces/Models/IPost.cs +++ b/src/DevHive.Data/Interfaces/Models/IPost.cs @@ -14,7 +14,7 @@ namespace DevHive.Data.Interfaces.Models List Comments { get; set; } - Rating Rating { get; set; } + // Rating Rating { get; set; } List FileUrls { get; set; } } diff --git a/src/DevHive.Data/Interfaces/Models/IRating.cs b/src/DevHive.Data/Interfaces/Models/IRating.cs index 4604a75..d1b968f 100644 --- a/src/DevHive.Data/Interfaces/Models/IRating.cs +++ b/src/DevHive.Data/Interfaces/Models/IRating.cs @@ -1,14 +1,14 @@ -using DevHive.Data.Interfaces.Models; +using System.Collections.Generic; using DevHive.Data.Models; namespace DevHive.Data.Interfaces.Models { public interface IRating : IModel { - Post Post { get; set; } + // Post Post { get; set; } - int Likes { get; set; } + int Rate { get; set; } - int Dislikes { get; set; } + // HashSet UsersThatRated { get; set; } } } diff --git a/src/DevHive.Data/Interfaces/Repositories/IRatingRepository.cs b/src/DevHive.Data/Interfaces/Repositories/IRatingRepository.cs index de4e3f2..7b99e0e 100644 --- a/src/DevHive.Data/Interfaces/Repositories/IRatingRepository.cs +++ b/src/DevHive.Data/Interfaces/Repositories/IRatingRepository.cs @@ -8,8 +8,6 @@ namespace DevHive.Data.Interfaces.Repositories public interface IRatingRepository : IRepository { Task GetByPostId(Guid postId); - Task> GetRating(Guid postId); - - Task HasUserRatedThisPost(Guid userId, Guid postId); + Task GetRating(Guid postId); } } -- cgit v1.2.3