refactor code, add interfaces for services

This commit is contained in:
mirrerror
2023-10-24 19:59:23 +03:00
parent d402514ecb
commit 65c5c3f2df
10 changed files with 89 additions and 30 deletions

View File

@@ -31,7 +31,7 @@ public class ExpenseMapper {
public Expense toExpense(ExpenseCreationDTO expenseDTO) {
return new Expense(expenseCategoryService.getExpenseCategory(expenseDTO.getExpenseCategory()), LocalDate.now(), expenseDTO.getAmount());
return new Expense(expenseCategoryService.getCategoryById(expenseDTO.getExpenseCategory()), LocalDate.now(), expenseDTO.getAmount());
}
}