Package com.skava.accounts.repository
Interface PaymentTermRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<PaymentTermEntity,
,Long> org.springframework.data.querydsl.QuerydslPredicateExecutor<PaymentTermEntity>
,org.springframework.data.repository.Repository<PaymentTermEntity,
Long>
public interface PaymentTermRepository
extends org.springframework.data.repository.CrudRepository<PaymentTermEntity,Long>, org.springframework.data.querydsl.QuerydslPredicateExecutor<PaymentTermEntity>
The Interface PaymentTermRepository extends another CrudRepository which contains all default crud operations.
PaymentTermRepository contains customized methods definitions for the operations in PaymentTerm entity.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
existsByIdAndCollectionId
(long id, long collectionId) Exists by id and collection id.boolean
existsByNameAndCollectionId
(String name, long collectionId) Exists by name and collection id.org.springframework.data.domain.Page<PaymentTermEntity>
findAll
(org.springframework.data.jpa.domain.Specification<PaymentTermEntity> specification, org.springframework.data.domain.Pageable pageRequest) Find PaymentTermEntity based on inputs.findByIdAndCollectionId
(long id, long collectionId) Find PaymentTermEntity by id and collection id.findNameById
(long paymentTermId) Find PaymentTerm name by id.Methods inherited from interface org.springframework.data.repository.CrudRepository
count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findAll, findAllById, findById, save, saveAll
Methods inherited from interface org.springframework.data.querydsl.QuerydslPredicateExecutor
count, exists, findAll, findAll, findAll, findAll, findAll, findBy, findOne
-
Method Details
-
findAll
org.springframework.data.domain.Page<PaymentTermEntity> findAll(org.springframework.data.jpa.domain.Specification<PaymentTermEntity> specification, org.springframework.data.domain.Pageable pageRequest) Find PaymentTermEntity based on inputs.- Parameters:
specification
- contains all search criteria like accountId=1, teamId=2pageRequest
- contains pageable information like page, size- Returns:
- the PaymentTermEntity
-
findByIdAndCollectionId
Find PaymentTermEntity by id and collection id.- Parameters:
id
- the idcollectionId
- It refers to the id of the collection which is a unique identifier. An collection should exists for the given collection id, and also the collection should be associated with the given PaymentTerm id.- Returns:
- the optional
-
existsByNameAndCollectionId
Exists by name and collection id.- Parameters:
name
- the name of paymentTermcollectionId
- It refers to the id of the collection which is a unique identifier. An collection should exists for the given collection id, and also the collection should be associated with the given PaymentTerm id.- Returns:
- true, if successful
-
existsByIdAndCollectionId
boolean existsByIdAndCollectionId(long id, long collectionId) Exists by id and collection id.- Parameters:
id
- the unique identifier of payment term.collectionId
- It refers to the id of the collection which is a unique identifier. An collection should exists for the given collection id, and also the collection should be associated with the given PaymentTerm id.- Returns:
- true, if successful
-
findNameById
Find PaymentTerm name by id.- Parameters:
paymentTermId
- id the unique identifier of payment term.- Returns:
- PaymentTermEntity
-