Skip to content

Commit

Permalink
Merge pull request #178 from BudgetBuddiesTeam/dev
Browse files Browse the repository at this point in the history
[Hotfix] expense 말일 조회되도록 수정
  • Loading branch information
wnd01jun authored Aug 31, 2024
2 parents abeee27 + 9796e1b commit 4f99893
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package com.bbteam.budgetbuddies.domain.expense.service;

import java.time.LocalDate;
import java.time.LocalTime;
import java.util.List;

import org.springframework.stereotype.Service;
Expand Down Expand Up @@ -117,7 +118,7 @@ public MonthlyExpenseResponseDto getMonthlyExpense(Long userId, LocalDate localD
User user = userRepository.findById(userId).orElseThrow(() -> new IllegalArgumentException("Invalid user ID"));

List<Expense> expenseSlice = expenseRepository.findAllByUserIdForPeriod(user,
startOfMonth.atStartOfDay(), endOfMonth.atStartOfDay());
startOfMonth.atStartOfDay(), endOfMonth.atTime(LocalTime.MAX));

return expenseConverter.toMonthlyExpenseResponseDto(expenseSlice, startOfMonth);
}
Expand Down

0 comments on commit 4f99893

Please sign in to comment.