Interface InventoryTransactionRepository<T extends com.broadleafcommerce.data.tracking.core.Trackable>

Type Parameters:
T -
All Superinterfaces:
CustomizedInventoryTransactionRepository<T>, com.broadleafcommerce.common.extension.DomainTypeAware, com.broadleafcommerce.common.messaging.notification.NotificationStateRepository, org.springframework.data.repository.Repository<T,String>, com.broadleafcommerce.data.tracking.core.TrackableRepository<T>
All Known Subinterfaces:
JpaInventoryTransactionRepository<D>

@NoRepositoryBean public interface InventoryTransactionRepository<T extends com.broadleafcommerce.data.tracking.core.Trackable> extends CustomizedInventoryTransactionRepository<T>, com.broadleafcommerce.data.tracking.core.TrackableRepository<T>, com.broadleafcommerce.common.extension.DomainTypeAware
Spring Repository API to store and retrieve individual inventory transactions.
Author:
Kelly Tisdell (ktisdell)
  • Method Details

    • findBySkuInventoryId

      org.springframework.data.domain.Page<T> findBySkuInventoryId(@NonNull String skuInventoryId, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Convenience method to retrieve all JpaInventoryTransaction records for a given JpaSkuInventory.getContextId().
      Parameters:
      skuInventoryId -
      page -
      contextInfo -
      Returns:
    • findBySkuInventoryIdAndTransactionType

      org.springframework.data.domain.Page<T> findBySkuInventoryIdAndTransactionType(@NonNull String skuInventoryId, @NonNull String transactionType, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Returns a Page of InventoryTransaction instances by skuInventoryId and transactionType.
      Parameters:
      skuInventoryId -
      transactionType -
      page -
      contextInfo -
      Returns:
      See Also:
    • findByTransactionTypeAndReferenceNumber

      List<T> findByTransactionTypeAndReferenceNumber(@NonNull String transactionType, @NonNull String referenceNumber, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Returns a List of InventoryTransaction instances by transactionType, and referenceNumber.
      Parameters:
      transactionType -
      referenceNumber -
      contextInfo -
      Returns:
      See Also:
    • findByTransactionTypeAndReferenceNumberAndDateProcessedIsNull

      List<T> findByTransactionTypeAndReferenceNumberAndDateProcessedIsNull(@NonNull String transactionType, @NonNull String referenceNumber, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Returns a List of InventoryTransaction instances by transactionType, and referenceNumber where the dateProcessed is null.
      Parameters:
      transactionType -
      referenceNumber -
      contextInfo -
      Returns:
      See Also:
    • findBySkuInventoryIdAndReferenceNumberAndTransactionTypeIn

      List<T> findBySkuInventoryIdAndReferenceNumberAndTransactionTypeIn(@NonNull String skuInventoryId, @NonNull String referenceNumber, @NonNull Set<String> transactionTypes, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Returns a list of InventoryTransaction records that have 1 or more transaction types for the same SkuInventory.getId() and reference number.
      Parameters:
      skuInventoryId -
      referenceNumber -
      transactionTypes -
      contextInfo -
      Returns:
    • findByReferenceNumberAndTransactionTypeIn

      List<T> findByReferenceNumberAndTransactionTypeIn(@NonNull String referenceNumber, @NonNull Set<String> transactionTypes, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Returns a list of InventoryTransaction records that have 1 or more transaction types for the same reference number.
      Parameters:
      referenceNumber -
      transactionTypes -
      contextInfo -
      Returns:
    • findByReferenceNumberInAndTransactionTypeIn

      List<T> findByReferenceNumberInAndTransactionTypeIn(@NonNull List<String> referenceNumbers, @NonNull Set<String> transactionTypes, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Returns a list of InventoryTransaction records that have 1 or more transaction types for the given reference numbers.
      Parameters:
      referenceNumbers - the reference numbers to search for
      transactionTypes - the transaction types to search for
      contextInfo - context information around sandbox and multitenant state
      Returns:
      a list of InventoryTransaction records that have 1 or more transaction types for the given reference numbers
    • findByBatchId

      org.springframework.data.domain.Page<T> findByBatchId(@NonNull String batchId, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Reads a list of InventoryTransaction records by a batch ID.
      Parameters:
      batchId -
      page -
      contextInfo -
      Returns:
    • findByDateCreatedBeforeAndTransactionTypeIn

      org.springframework.data.domain.Page<T> findByDateCreatedBeforeAndTransactionTypeIn(Instant maxCreatedDate, Set<String> transactionTypes, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Reads a page of inventory transactions created before a certain date and of certain transaction types.