| | |
| | | import com.fasterxml.jackson.databind.ObjectMapper; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.integration.annotation.ServiceActivator; |
| | | import org.springframework.messaging.MessageHeaders; |
| | | import org.springframework.stereotype.Service; |
| | |
| | | @Autowired |
| | | private IFileMapper mapper; |
| | | |
| | | @Value("${oss.out-net-file-address}") |
| | | private String fileAddress; |
| | | @Value("${oss.bucket}") |
| | | private String bucket; |
| | | @Override |
| | | public Boolean fastUpload(String workspaceId, String fingerprint) { |
| | | return fileService.checkExist(workspaceId, fingerprint); |
| | |
| | | |
| | | @Override |
| | | public PaginationData<MediaJobDTO> mediaPage(String workspaceId, SearchMediaParam param) { |
| | | param.setFileAddress(fileAddress+"/"+bucket); |
| | | Page<MediaJobDTO> waylineJobDTOPage = mapper.mediaPage(new Page<MediaJobDTO>(param.getPage(), param.getPageSize()), workspaceId, param); |
| | | return new PaginationData<MediaJobDTO>(waylineJobDTOPage.getRecords(), new Pagination(waylineJobDTOPage)); |
| | | } |
| | | |
| | | @Override |
| | | public PaginationData<MediaJobDTO> mediaDetail( String jobId,Long page, Long pageSize) { |
| | | Page<MediaJobDTO> waylineJobDTOPage = mapper.mediaDetail(new Page<MediaJobDTO>(page, pageSize), jobId); |
| | | Page<MediaJobDTO> waylineJobDTOPage = mapper.mediaDetail(new Page<MediaJobDTO>(page, pageSize), jobId,fileAddress+"/"+bucket); |
| | | return new PaginationData<MediaJobDTO>(waylineJobDTOPage.getRecords(), new Pagination(waylineJobDTOPage)); |
| | | } |
| | | |