Package org.openwms.wms.receiving.impl
Class AbstractReceivingOrderPosition
java.lang.Object
org.ameba.integration.jpa.BaseEntity
org.openwms.wms.receiving.impl.AbstractReceivingOrderPosition
- All Implemented Interfaces:
Serializable
,org.ameba.integration.TypedEntity<Long>
- Direct Known Subclasses:
ReceivingOrderPosition
,ReceivingTransportUnitOrderPosition
@Entity
public abstract class AbstractReceivingOrderPosition
extends org.ameba.integration.jpa.BaseEntity
implements Serializable
A AbstractReceivingOrderPosition.
- Author:
- Heiko Scherrer
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionArbitrary detail information on this position, might be populated with ERP information.private ZonedDateTime
Latest date this position can be processed.private ReceivingOrder
private @NotNull Integer
The position number is a unique index within a singleReceivingOrder
instance.private @NotNull PositionState
Current position state. -
Constructor Summary
ModifierConstructorDescriptionprotected
Used by the JPA provider. -
Method Summary
Modifier and TypeMethodDescriptionAdd a new detail to theAbstractReceivingOrderPosition
.void
changePositionState
(org.springframework.context.ApplicationEventPublisher eventPublisher, PositionState positionState) boolean
Capturing on an ReceivingOrderPosition is allowed if the state is any but notPositionState.CANCELED
.Get all the details of thisAbstractReceivingOrderPosition
.getOrder()
int
getPosNo()
getState()
void
preCreate
(ServiceProvider serviceProvider) Subclasses have the chance for manipulation before creation.void
setDetails
(Map<String, String> details) void
setOrder
(ReceivingOrder order) void
setState
(PositionState state) toString()
abstract void
validateOnCreation
(jakarta.validation.Validator validator, Class<?> clazz) Subclasses may validate themselves.Methods inherited from class org.ameba.integration.jpa.BaseEntity
getCreatedBy, getCreateDt, getLastModifiedBy, getLastModifiedDt, getOl, getPk, isNew, setCreatedBy, setCreateDt, setLastModifiedBy, setLastModifiedDt, setOl
-
Field Details
-
order
-
posNo
The position number is a unique index within a singleReceivingOrder
instance. -
state
Current position state. -
details
Arbitrary detail information on this position, might be populated with ERP information. -
latestDueDate
Latest date this position can be processed.
-
-
Constructor Details
-
AbstractReceivingOrderPosition
protected AbstractReceivingOrderPosition()Used by the JPA provider. -
AbstractReceivingOrderPosition
-
-
Method Details
-
validateOnCreation
Subclasses may validate themselves.- Parameters:
validator
- The Validator instanceclazz
- The validation group
-
preCreate
Subclasses have the chance for manipulation before creation.- Parameters:
serviceProvider
- An instance that provides application services.
-
getOrder
-
setOrder
-
getPosNo
public int getPosNo() -
getState
-
setState
-
changePositionState
public void changePositionState(org.springframework.context.ApplicationEventPublisher eventPublisher, PositionState positionState) -
doesStateAllowCapturing
public boolean doesStateAllowCapturing()Capturing on an ReceivingOrderPosition is allowed if the state is any but notPositionState.CANCELED
.- Returns:
- if allowed
-
getDetails
Get all the details of thisAbstractReceivingOrderPosition
.- Returns:
- As Map
-
setDetails
-
addDetail
Add a new detail to theAbstractReceivingOrderPosition
.- Parameters:
key
- The unique key of the detailvalue
- The value as String- Returns:
- This instance
-
getLatestDueDate
-
toString
-