Complaints working, web comments response page, filtering for announcements

This commit is contained in:
Dimitar Byalkov
2023-06-09 04:57:28 +02:00
parent d8e185757d
commit d81450ed21
20 changed files with 336 additions and 48 deletions

View File

@@ -15,11 +15,15 @@ namespace Logic
this.commentRepository = commentRepository;
}
public void CreateCommentToAnnouncement(User author, string description, string title, DateTime publishDate, int announcementId)
public Comment GetCommentById(int id)
{
return commentRepository.GetCommentById(id);
}
public void CreateCommentOnAnnouncement(User author, string description, string title, DateTime publishDate, int announcementId)
{
commentRepository.CreateCommentOnAnnouncement(author, description, title, publishDate, announcementId);
}
public void CreateResponseToComment(User author, string description, string title, DateTime publishDate, int commentId)
public void CreateResponseOnComment(User author, string description, string title, DateTime publishDate, int commentId)
{
commentRepository.CreateResponseOnComment(author, description, title, publishDate, commentId);
}
@@ -35,5 +39,13 @@ namespace Logic
{
commentRepository.DeleteResponseOnComment(responseId, commentId);
}
public List<Comment> GetAllCommentsOnComplaint(int complaintId)
{
return commentRepository.GetAllCommentsOnComplaint(complaintId);
}
public void CreateCommentOnComplaint(User author, string description, string title, DateTime publishDate, int complaintId)
{
commentRepository.CreateCommentOnComplaint(author, description, title, publishDate, complaintId);
}
}
}