@Query(value = "select new com.matech.auditing.fileLog.FileCollectionDTO(att.id,att.originalName,att.createdTime) from ReleasedPaper r " +
"left join r.attach att where att.id is not null " +
" and (:originalName is null or att.originalName like :originalName) " +
" and (:userId is null or att.createdBy = :userId) " +
" and (:startTime is null or att.createdTime >= :startTime) " +
" and (:endTime is null or att.createdTime <= :endTime) ")
Page<FileCollectionDTO> getAllByReleasedPaper(Pageable pageable,
@Param("originalName") String originalName,
@Param("userId") String userId,
@Param("startTime") Date startTime,
@Param("endTime") Date endTime);