Interface EmploymentStatusRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<EmploymentStatus,,String> org.springframework.data.jpa.repository.JpaRepository<EmploymentStatus,,String> org.springframework.data.repository.PagingAndSortingRepository<EmploymentStatus,,String> org.springframework.data.repository.query.QueryByExampleExecutor<EmploymentStatus>,org.springframework.data.repository.Repository<EmploymentStatus,String>
@Repository
public interface EmploymentStatusRepository
extends org.springframework.data.jpa.repository.JpaRepository<EmploymentStatus,String>
Repository for queries for Employment Status.
-
Method Summary
Modifier and TypeMethodDescriptionList<es.kukenan.smartfi.dto.DataOnboardingResponse>findAllByLanguageId(int language) Select registers by language.findById(int id) Select registers by id.Methods inherited from interface org.springframework.data.repository.CrudRepository
count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, saveMethods inherited from interface org.springframework.data.jpa.repository.JpaRepository
deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, findAll, findAll, findAllById, flush, getById, getOne, getReferenceById, saveAll, saveAllAndFlush, saveAndFlushMethods inherited from interface org.springframework.data.repository.PagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor
count, exists, findAll, findBy, findOne
-
Method Details
-
findById
@Query("SELECT e FROM EmploymentStatus e WHERE e.id = :id") EmploymentStatus findById(@Param("id") int id) Select registers by id.- Parameters:
id- document for Employment Status.- Returns:
- Employment Status object from database
-
findAllByLanguageId
@Query("SELECT NEW es.kukenan.smartfi.dto.DataOnboardingResponse(e.id, e.description, e.id) FROM EmploymentStatus e WHERE e.language.id = :language") List<es.kukenan.smartfi.dto.DataOnboardingResponse> findAllByLanguageId(@Param("language") int language) Select registers by language.- Parameters:
language- for Employment Status.- Returns:
- List of objects from database
-