Class ReceivingOrder

java.lang.Object
org.ameba.integration.jpa.BaseEntity
org.ameba.integration.jpa.ApplicationEntity
org.openwms.wms.receiving.impl.ReceivingOrder
All Implemented Interfaces:
Serializable, org.ameba.integration.TypedEntity<Long>

@Entity public class ReceivingOrder extends org.ameba.integration.jpa.ApplicationEntity implements Serializable
A ReceivingOrder.
Author:
Heiko Scherrer
See Also:
  • Field Details

    • LOGGER

      private static final org.slf4j.Logger LOGGER
    • orderId

      private String orderId
      Unique order id, business key.
    • orderState

      private OrderState orderState
      Current state of this order.
    • locked

      private boolean locked
      Property to lock/unlock an order.
      • true: locked
      • false: unlocked
    • priority

      private int priority
      Current priority of the order.
    • latestDueDate

      @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssXXX") private ZonedDateTime latestDueDate
      Latest date of this order can be processed.
    • expectedReceiptDate

      @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssXXX") private ZonedDateTime expectedReceiptDate
      When the order is expected to be received.
    • earliestStartDate

      @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssXXX") private ZonedDateTime earliestStartDate
      Earliest date the order can be started.
    • startDate

      @DateTimeFormat(iso=DATE_TIME) private ZonedDateTime startDate
      When the order has been started.
    • endDate

      @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssXXX") private ZonedDateTime endDate
      When the order has been finished.
    • nextAllocationDate

      @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssXXX") private ZonedDateTime nextAllocationDate
      Date when the order should be allocated.
    • problem

      private Problem problem
      Latest problem that is occurred on this order.
    • positions

      @Valid private @Valid List<AbstractReceivingOrderPosition> positions
      All ReceivingOrderPosition this order has.
    • details

      private Map<String,String> details
      Arbitrary detail information on this order, might be populated with ERP information.
  • Constructor Details

    • ReceivingOrder

      protected ReceivingOrder()
      Used by the JPA provider.
    • ReceivingOrder

      public ReceivingOrder(String orderId)
  • Method Details

    • prePersist

      protected void prePersist()
    • getOrderId

      public String getOrderId()
    • setOrderId

      void setOrderId(String orderId)
    • hasOrderId

      public boolean hasOrderId()
    • getOrderState

      public OrderState getOrderState()
    • setOrderState

      public void setOrderState(OrderState orderState)
    • setOrderState

      protected void setOrderState(org.springframework.context.ApplicationEventPublisher publisher, OrderState orderState)
    • cancelOrder

      public void cancelOrder(org.springframework.context.ApplicationEventPublisher publisher, org.ameba.i18n.Translator translator)
    • recalculateOrderState

      public boolean recalculateOrderState(org.springframework.context.ApplicationEventPublisher publisher)
      Recalculate and occasionally change the state of this ReceivingOrder.
      Returns:
      true if the state has been changed
    • isLocked

      public boolean isLocked()
    • getPriority

      public int getPriority()
    • getLatestDueDate

      public ZonedDateTime getLatestDueDate()
    • getExpectedReceiptDate

      public ZonedDateTime getExpectedReceiptDate()
    • setExpectedReceiptDate

      public void setExpectedReceiptDate(ZonedDateTime expectedReceiptDate)
    • getEarliestStartDate

      public ZonedDateTime getEarliestStartDate()
    • getEndDate

      public ZonedDateTime getEndDate()
    • setEndDate

      public void setEndDate(ZonedDateTime endDate)
    • getStartDate

      public ZonedDateTime getStartDate()
    • getNextAllocationDate

      public ZonedDateTime getNextAllocationDate()
    • getProblem

      public Problem getProblem()
    • getPositions

      public List<AbstractReceivingOrderPosition> getPositions()
    • setPositions

      public void setPositions(List<AbstractReceivingOrderPosition> positions)
    • getDetails

      public Map<String,String> getDetails()
    • setDetails

      public void setDetails(Map<String,String> details)
    • toString

      public String toString()
      Only the orderId.
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object o)
      Only the orderId.
      Overrides:
      equals in class org.ameba.integration.jpa.ApplicationEntity
    • hashCode

      public int hashCode()
      Only the orderId.
      Overrides:
      hashCode in class org.ameba.integration.jpa.ApplicationEntity