Skip to content

Add item requests and gateway#5

Merged
NadezhdaTA merged 13 commits intomainfrom
add-item-requests-and-gateway
Aug 5, 2025
Merged

Add item requests and gateway#5
NadezhdaTA merged 13 commits intomainfrom
add-item-requests-and-gateway

Conversation

@NadezhdaTA
Copy link
Copy Markdown
Owner

No description provided.

public List<RequestOutputDto> getAllRequests() {
return requestRepository.findAll().stream()
.map(requestMapper::toRequestOutputDto)
.sorted(Comparator.comparing(RequestOutputDto::getRequestDate))
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Лучше конечно получить уже отсортированный набор из БД
https://www.baeldung.com/spring-data-sorting

Comment thread gateway/src/main/java/ru/practicum/shareit/item/ItemController.java Outdated
Copy link
Copy Markdown

@VadimZharkov VadimZharkov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Хорошая работа, можно улучшить.

@NadezhdaTA NadezhdaTA merged commit b851ebb into main Aug 5, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants