比對新檔案 |
| | |
| | | package com.pollex.pam.service; |
| | | |
| | | import java.util.List; |
| | | |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import com.pollex.pam.domain.AppointmentNoticeLog; |
| | | import com.pollex.pam.repository.AppointmentNoticeLogRepository; |
| | | import com.pollex.pam.service.dto.AppointmentNoticeSendDTO; |
| | | import com.pollex.pam.service.mapper.AppointmentNoticeSendMapper; |
| | | |
| | | @Service |
| | | @Transactional |
| | | public class AppointmentNoticeLogService { |
| | | |
| | | @Autowired |
| | | AppointmentNoticeLogRepository appointmentNoticeLogRepository; |
| | | |
| | | @Autowired |
| | | AppointmentNoticeSendMapper appointmentNoticeSendMapper; |
| | | |
| | | public AppointmentNoticeLog create(AppointmentNoticeSendDTO noticeSendDTO) { |
| | | AppointmentNoticeLog appointmentNoticeLog = |
| | | appointmentNoticeSendMapper.toAppointmentNoticeLog(noticeSendDTO); |
| | | return appointmentNoticeLogRepository.save(appointmentNoticeLog); |
| | | } |
| | | |
| | | public List<AppointmentNoticeLog> findByAppointmentId(Long appointmentId){ |
| | | return appointmentNoticeLogRepository.findByAppointmentId(appointmentId); |
| | | } |
| | | } |