ReplyServiceImpl
페이지 정보
본문
package web.service;
import org.modelmapper.ModelMapper;
import org.springframework.stereotype.Service;
import lombok.RequiredArgsConstructor;
import lombok.extern.log4j.Log4j2;
import web.domain.Reply;
import web.dto.ReplyDTO;
import web.repository.ReplyRepository;
@Service
@RequiredArgsConstructor
@Log4j2
public class ReplyServiceImpl implements ReplyService {
private final ReplyRepository replyRepository;
private final ModelMapper modelMapper;
@Override
public Long register(ReplyDTO replyDTO) {
Reply reply = modelMapper.map(replyDTO, Reply.class);
Long rno = replyRepository.save(reply).getRno();
return rno;
}
}
- 이전글ReplyService 24.06.21
- 다음글ReplyServiceTests 24.06.21
댓글목록
등록된 댓글이 없습니다.