Forum Message UI Improvement (Thesis Board #3470) #61
@ -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);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user