package com.estate.expert.admin.domain.project.info;
|
|
import com.estate.expert.admin.domain.common.EntityBaseRepository;
|
import org.springframework.data.domain.Page;
|
import org.springframework.data.domain.Pageable;
|
import org.springframework.data.jpa.repository.Query;
|
import org.springframework.data.repository.query.Param;
|
|
public interface ProjectInfoRepository extends EntityBaseRepository<ProjectInfo> {
|
|
@Query("select p from ProjectInfo p where p.project.id = :projectId " +
|
"and p.deleted = false " +
|
"order by p.updateTime desc")
|
Page<ProjectInfo> findByProjectId(@Param("projectId") Integer projectId, Pageable page);
|
|
// getByCheckTaskId
|
// ProjectInfo findFirstByCheckTaskId(Integer checkTaskId);
|
|
// latest
|
ProjectInfo findTopByProjectIdOrderByIdDesc(Integer projectId);
|
|
}
|