Skip to content

Commit

Permalink
UMC-EWHA#31 Refactor: Modify BoardService
Browse files Browse the repository at this point in the history
  • Loading branch information
JoongHyun-Kim committed Nov 21, 2022
1 parent 55e0618 commit 23a4824
Showing 1 changed file with 6 additions and 20 deletions.
26 changes: 6 additions & 20 deletions src/main/java/umc/crud/src/board/BoardService.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,34 +7,18 @@
import umc.crud.config.BaseResponseStatus;
import umc.crud.src.board.model.*;

import java.util.List;

@Service
public class BoardService {
@Autowired
BoardDao boardDao;
private BoardDao boardDao;

/**
* 모든 글 조회
* @return
*/
public List<GetBoardRes> getAllBoards() {

return boardDao.getAllBoards();
}

/**
* 특정 글 조회
* @param writer
* @return
*/
public List<GetBoardRes> getBoardByWriter(String writer) {

return boardDao.getBoardByWriter(writer);
}
@Autowired
private BoardProvider boardProvider;

/**
* 글 생성
* POST
* @param postBoardReq
* @return
* @throws BaseException
Expand All @@ -52,6 +36,7 @@ public PostBoardRes writeBoard(PostBoardReq postBoardReq) throws BaseException{

/**
* 글 내용 수정
* PUT
* @param putBoardReq
* @throws BaseException
*/
Expand All @@ -69,6 +54,7 @@ public void modifyContent(PutBoardReq putBoardReq) throws BaseException {

/**
* 글 삭제
* DELETE
* @param boardId
*/
@Transactional
Expand Down

0 comments on commit 23a4824

Please sign in to comment.