mirror of
https://github.com/nagisa77/OpenIsle.git
synced 2026-03-06 12:00:44 +08:00
Add DAU statistics module
This commit is contained in:
@@ -32,4 +32,9 @@ public class UserVisitService {
|
||||
.orElseThrow(() -> new com.openisle.exception.NotFoundException("User not found"));
|
||||
return userVisitRepository.countByUser(user);
|
||||
}
|
||||
|
||||
public long countDau(LocalDate date) {
|
||||
LocalDate d = date != null ? date : LocalDate.now();
|
||||
return userVisitRepository.countByVisitDate(d);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user