Package org.openwms.tms.impl
Interface TransportOrderJpaRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<TransportOrder,,Long> org.springframework.data.jpa.repository.JpaRepository<TransportOrder,,Long> org.springframework.data.repository.ListCrudRepository<TransportOrder,,Long> org.springframework.data.repository.ListPagingAndSortingRepository<TransportOrder,,Long> org.springframework.data.repository.PagingAndSortingRepository<TransportOrder,,Long> org.springframework.data.repository.query.QueryByExampleExecutor<TransportOrder>,org.springframework.data.repository.Repository<TransportOrder,,Long> TransportOrderRepository<TransportOrder,Long>
interface TransportOrderJpaRepository
extends TransportOrderRepository<TransportOrder,Long>, org.springframework.data.jpa.repository.JpaRepository<TransportOrder,Long>
A TransportOrderRepository is an extension of Spring Data's
JpaRepository that provides additional queries regarding
TransportOrder entities.- Author:
- Heiko Scherrer
-
Method Summary
Modifier and TypeMethodDescriptionfindBypKey(String pKey) findBypKeys(List<String> pKeys) findByTargetLocation(String targetLocation) findByTransportUnitBKAndStates(String transportUnitBK, TransportOrderState... states) intnumberOfTransportOrders(String transportUnitBK, TransportOrderState state) 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, flush, getById, getOne, getReferenceById, saveAllAndFlush, saveAndFlushMethods inherited from interface org.springframework.data.repository.ListCrudRepository
findAll, findAllById, saveAllMethods inherited from interface org.springframework.data.repository.ListPagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.PagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor
count, exists, findAll, findBy, findOneMethods inherited from interface org.openwms.tms.impl.TransportOrderRepository
findById, save, saveAndFlush
-
Method Details
-
findBypKey
@Query("select to\n from TransportOrder to\n where to.pKey = ?1\n") Optional<TransportOrder> findBypKey(String pKey) - Specified by:
findBypKeyin interfaceTransportOrderRepository<TransportOrder,Long>
-
findBypKeys
@Query("select to\n from TransportOrder to\n where to.pKey in ?1\n") List<TransportOrder> findBypKeys(List<String> pKeys) - Specified by:
findBypKeysin interfaceTransportOrderRepository<TransportOrder,Long>
-
findByTargetLocation
- Specified by:
findByTargetLocationin interfaceTransportOrderRepository<TransportOrder,Long>
-
findByTransportUnitBKAndStates
@Query(" select to\n from TransportOrder to\n where to.transportUnitBK = ?1\n and to.state in ?2\n order by to.priority desc, to.startDate, to.createDt\n") List<TransportOrder> findByTransportUnitBKAndStates(String transportUnitBK, TransportOrderState... states) - Specified by:
findByTransportUnitBKAndStatesin interfaceTransportOrderRepository<TransportOrder,Long>
-
numberOfTransportOrders
@Query("select count(to)\n from TransportOrder to\n where to.transportUnitBK = :transportUnitBK\n and to.state = :state\n") int numberOfTransportOrders(@Param("transportUnitBK") String transportUnitBK, @Param("state") TransportOrderState state) - Specified by:
numberOfTransportOrdersin interfaceTransportOrderRepository<TransportOrder,Long>
-