| | |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Service |
| | | @AllArgsConstructor |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class PatrolReportServiceImpl extends BaseServiceImpl<PatrolReportMapper, PatrolReport> implements IPatrolReportService { |
| | | private final IPatrolRecordService patrolRecordService; |
| | | |
| | |
| | | } |
| | | |
| | | @Override |
| | | @Transactional |
| | | public Boolean customizeUpdateBatchById(List<PatrolReport> list) { |
| | | list.forEach(report->{ |
| | | updateById(report); |
| | | }); |
| | | return true; |
| | | } |
| | | |
| | | @Override |
| | | public boolean updateById(PatrolReport patrolReport) { |
| | | PatrolRecord patrolRecord = new PatrolRecord(); |
| | | patrolRecord.setId(Long.parseLong(patrolReport.getRecordId())); |