Forum Message UI Improvement (Thesis Board #3470) #61

Merged
tozh4728 merged 20 commits from 3470-forum-msg-ui-improvement into develop 2024-12-19 15:28:23 +01:00
Showing only changes of commit 552aaade6e - Show all commits

View File

@ -106,6 +106,17 @@ public class ProjectForumServiceImpl implements ProjectForumService {
return false; return false;
} }
public int getUnreadThreadsCount(Project project, User user) {
List<ProjectThread> threads = getThreads(project);
int count = 0;
for (ProjectThread thread : threads) {
if (!basicForumService.isThreadRead(user, thread.getForumThread())) {
count++;
}
}
return count;
}
@Override @Override
public ProjectThread findOne(long threadId) { public ProjectThread findOne(long threadId) {
return projectThreadRepository.findOne(threadId); return projectThreadRepository.findOne(threadId);