Skip to content

Commit

Permalink
Merge pull request #124 from dongkyun0713/dongkyun
Browse files Browse the repository at this point in the history
fix() : 게시물 조회 오류 해결
  • Loading branch information
dongkyun0713 authored Feb 28, 2024
2 parents 7fdc0f2 + 24f4ea1 commit 6695650
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@
public class MatchingBoardService {
private final MatchingPostRepository matchingPostRepository;

@Transactional(readOnly = true)
@Transactional
public MatchingPostPagingResponseDto findAllPosts(int page) {
Pageable pageable = PageRequest.of(page, 10, Sort.by("createDate").descending());
Page<MatchingPost> matchingPosts = matchingPostRepository.findAll(pageable);
return MatchingPostPagingResponseDto.from(matchingPosts);
}

@Transactional(readOnly = true)
@Transactional
public MatchingPostPagingResponseDto searchByKeyWord(int page,
String keyword) {

Expand All @@ -33,7 +33,7 @@ public MatchingPostPagingResponseDto searchByKeyWord(int page,
return MatchingPostPagingResponseDto.from(matchingPosts);
}

@Transactional(readOnly = true)
@Transactional
public MatchingPostPagingResponseDto findByCategory(int page,
String category) {
Pageable pageable = PageRequest.of(page, 10, Sort.by("createDate").descending());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public class MatchingPostService {
private final UserRepository userRepository;
private final MatchingPostReviewRepository matchingPostReviewRepository;

//게시물 작성
// 게시물 작성
@Transactional
public MatchingPostCreateResponseDto createMatchingPost(Principal principal,
MatchingPostCreateRequestDto matchingPostCreateRequestDto) {
Expand Down

0 comments on commit 6695650

Please sign in to comment.