public class CreateReceiptCmdImpl extends TaskCommandImpl implements CreateReceiptCmd
This command first determines the type of receipt to be created. If the expected inventory record detail identifier is provided, an expected inventory receipt will be created and the receipt type will be set to 'EIR'. If the disposition record identifier of returned item is provided, a return receipt will be created and the receipt type will be set to 'RTN'. Otherwise, an ad hoc receipt will be created and the receipt type will be set to 'ADHC'.
If this is an expected inventory receipt, the quantity received and quantity remaining of the corresponding expected inventory record detail will be updated.
If the receipt is created successfully, the receipt identifier will be returned and the receipt will be made available to the distribution arrangement by calling MakeReceiptAvailableCmd task command.
This command requires to have the store id set in the command context.
Modifier and Type | Field and Description |
---|---|
static java.lang.String | COPYRIGHT
The internal copyright field.
|
Constructor and Description |
---|
CreateReceiptCmdImpl() |
Modifier and Type | Method and Description |
---|---|
void | createItemffmctr(java.lang.Long itemspcId)
Adds a new row in itemffmctr table for this item, store and fulfillment center if row does not yet exist when the receipt is created.
|
java.lang.String | getComment1()
Gets the comment specified on the new receipt.
|
java.lang.String | getComment2()
Gets the comment specified regarding the quality of the item received.
|
java.math.BigDecimal | getCost()
Gets the unit cost of the item.
|
java.lang.Long | getDistArrangId()
Gets the identifier of the distribution arrangement that has access to this received inventory.
|
java.lang.Integer | getFfmcenterId()
Gets the identifier of the fulfillment center where the inventory was received.
|
java.lang.Long | getItemspcId()
Gets the identifier of the item specified for receipt.
|
java.lang.Long | getMemberId()
Gets the identifier of the owner of the received item.
|
java.lang.String | getPartNumber()
Gets the part number of the received item.
|
java.lang.Integer | getQtyReceived()
Gets the number of items received.
|
java.lang.Long | getRaDetailId()
Gets the expected inventory record detail identifier for the expected inventory receipt.
|
java.lang.Long | getRcptAvailId()
Gets the available receipt identifier.
|
java.sql.Timestamp | getReceiptDate()
Gets the date the inventory was received.
|
java.lang.Long | getReceiptId()
Gets the identifier of the new receipt.
|
java.lang.String | getReceiptType()
Gets the type of receipt which indicates how this receipt was created.
|
java.lang.Long | getRtnRcptDspId()
Gets the disposition record identifier of the item returned for receipt.
|
java.lang.String | getSetCCurr()
Gets the currency of the cost field.
|
java.lang.Long | getVendorId()
Gets the identifier of the vendor that supplied the inventory.
|
java.lang.Long | getVersionSpcId()
Gets the product version identifier of the item returned for receipt.
|
boolean | isReadyToCallExecute()
Ready to be executed.
|
void | performExecute()
Performs the execution of creating a receipt.
|
void | reset()
Resets the command local variable.
|
void | setComment1(java.lang.String newComment1)
Sets the comment on the new receipt.
|
void | setComment2(java.lang.String newComment2)
Sets the comment regarding the quality of the item received.
|
void | setCost(java.math.BigDecimal newCost)
Sets the unit cost of the item being received.
|
void | setDistArrangId(java.lang.Long newDistArrangId)
Sets the identifier of the distribution arrangement that has access to this received inventory.
|
void | setFfmcenterId(java.lang.Integer newFfmcenterId)
Sets the fulfillment center identifier.
|
void | setItemspcId(java.lang.Long newItemspcId)
Sets the identifier of the item specified for receipt.
|
void | setMemberId(java.lang.Long newMemberId)
Sets the identifier of the owner of the item specified for receipt.
|
void | setPartNumber(java.lang.String newPartNumber)
Sets the part number of the items being received.
|
void | setQtyReceived(java.lang.Integer newQtyReceived)
Sets the number of items being received.
|
void | setRaDetailId(java.lang.Long newRaDetailId)
Sets the identifier of the record detail of the expected inventory.
|
void | setRcptAvailId(java.lang.Long newRcptAvailId)
Sets the identifier of the available receipt.
|
void | setReceiptDate(java.sql.Timestamp newReceiptDate)
Sets the date the inventory was received.
|
void | setReceiptId(java.lang.Long newReceiptId)
Sets identifier of the new receipt.
|
void | setReceiptType(java.lang.String newReceiptType)
Sets the type of receipt which indicates how this receipt was created.
|
void | setRequestProperties(TypedProperty newRequestProperties)
Gets the information of receipt to be created and sets the information into the command local variable.
|
void | setRtnRcptDspId(java.lang.Long newRtnRcptDspId)
Sets the disposition record identifier of the returned item.
|
void | setSetCCurr(java.lang.String newSetCCurr)
Sets the currency of the cost field.
|
void | setVendorId(java.lang.Long newVendorId)
Sets the identifier of the vendor that supplied the inventory.
|
void | setVersionSpcId(java.lang.Long newVersionSpcId)
Sets the product version identifier of the item specified for receipt.
|
void | validateParameters()
Checks the information of the receipt to be created.
|
public static final java.lang.String COPYRIGHT
public java.lang.String getComment1()
public java.lang.String getComment2()
public java.math.BigDecimal getCost()
public java.lang.Long getDistArrangId()
public java.lang.Integer getFfmcenterId()
public java.lang.Long getItemspcId()
public java.lang.Long getMemberId()
public java.lang.String getPartNumber()
public java.lang.Integer getQtyReceived()
public java.lang.Long getRaDetailId()
public java.lang.Long getRcptAvailId()
public java.sql.Timestamp getReceiptDate()
public java.lang.Long getReceiptId()
public java.lang.String getReceiptType()
public java.lang.Long getRtnRcptDspId()
public java.lang.String getSetCCurr()
public java.lang.Long getVendorId()
public java.lang.Long getVersionSpcId()
public void setComment1(java.lang.String newComment1)
public void setComment2(java.lang.String newComment2)
public void setCost(java.math.BigDecimal newCost)
public void setDistArrangId(java.lang.Long newDistArrangId)
public void setFfmcenterId(java.lang.Integer newFfmcenterId)
public void setItemspcId(java.lang.Long newItemspcId)
public void setMemberId(java.lang.Long newMemberId)
public void setPartNumber(java.lang.String newPartNumber)
public void setQtyReceived(java.lang.Integer newQtyReceived)
public void setRaDetailId(java.lang.Long newRaDetailId)
public void setRcptAvailId(java.lang.Long newRcptAvailId)
public void setReceiptDate(java.sql.Timestamp newReceiptDate)
public void setReceiptId(java.lang.Long newReceiptId)
public void setReceiptType(java.lang.String newReceiptType)
public void setRtnRcptDspId(java.lang.Long newRtnRcptDspId)
public void setSetCCurr(java.lang.String newSetCCurr)
public void setVendorId(java.lang.Long newVendorId)
public void setVersionSpcId(java.lang.Long newVersionSpcId)
public void setRequestProperties(TypedProperty newRequestProperties) throws ECApplicationException
public boolean isReadyToCallExecute()
public void validateParameters() throws ECException
Checks the information of the receipt to be created. Make sure all the required parameters were passed in, or collected from somewhere. Fields required to be set beforehand
public void performExecute() throws ECException
If this is an expected inventory receipt, the quantity received and quantity remaining of the corresponding expected inventory record detail will be updated.
If the receipt is created successfully, the receipt identifier will be returned and the receipt will be made available to the distribution arrangement by calling MakeReceiptAvailableCmd.
Utilizes the following beans
public void createItemffmctr(java.lang.Long itemspcId) throws ECException
public void reset()