com.retek.component.customerorder
Interface CustomerOrder

All Superinterfaces:
BusinessObject, DistributedObject

public interface CustomerOrder
extends DistributedObject


Field Summary
static java.lang.String ACCOMMODATION
           
static java.lang.String BALANCE
           
static java.lang.String BANNER
           
static java.lang.String BILL_TO_ADDRESS
           
static java.lang.String CANCEL_PENDED_ORDER_DATE
           
static java.lang.String CREATED_BY_USER
           
static java.lang.String CUSTOMER
           
static java.lang.String DISPLAY_NUMBER
           
static java.lang.String MAIL_ORDER_BATCH
           
static java.lang.String ORDER_LINE
           
static java.lang.String ORDER_PRIORITY
           
static java.lang.String ORDER_SOURCE
           
static java.lang.String ORDER_TYPE
           
static java.lang.String PAYMENT
           
static java.lang.String PRIORITY
           
static java.lang.String RETURN_LINE
           
static java.lang.String SHIP_TO_ADDRESS
           
static java.lang.String SHIPPED_CONTAINER
           
static java.lang.String SOURCE_CODE
           
static java.lang.String STORE
           
static java.lang.String TAX_ACCOMMODATION
           
static java.lang.String ZERO_SALE_LINE
           
 
Method Summary
 void addAccommodationAndGeneratePayment(Accommodation accomodation, Refundable refundable)
          Calculates the value of the accommodation, adds the accommodation to the order, generates a credit payment for the accommodation, sets the order priority to HIGH, and generates a history event for the accommodation.
 void addCallTag(User user, CallTag callTag)
           
 void addHistoryEventRequest(HistoryEventRequest eventRequest)
          Create a new history event request and add to the collection of requests so later history events can be created when order is submitted.
 void addJustPublishedToWmsShipmentRequest(ShipmentRequest shipmentRequest, User user)
           
 void addOfferCode(OfferCode offerCode)
           
 void addPayment(CustomerOrderPayment payment)
           
 void addTransactionGroup(CustomerOrderTransactionGroup transactionGroup)
           
 void applyGiftingDetailToLines(java.util.Set orderLines, GiftingDetail giftingDetail)
           
 void applyOrderLine(CustomerOrderLine orderLine, User user)
          Adds orderLine to the set of order lines for this order, reserves this order line, and applies promotions.
 void applyPromotionalOrderLine(CustomerOrderLine orderLine, User user, Promotion promotion)
           
 void applyPromotionalPaymentPlanCode(PaymentPlanCode selectedPaymentPlanCode, Promotion promotion)
           
 void applyReplacement(ReplacementLinePair replacementGroup, User user)
          Adds replacementLine from replacementGroup to the order and reserves the replacement line
 void applyReturnLine(ReturnLine returnLine, User user)
          Adds returnLine to the order, clears calculated totals on the return line's shipTo.
 void authorizePayment(CustomerOrderPayment payment)
          Using an authorization calculation strategy, calculates the amount to be authorized for this payment.
 void authorizePaymentManually(CustomerOrderPayment payment, java.lang.String authCode, User user)
          For payments needing manual authorization, manually authorize the payment by storing the authorization code and authorization date.
 boolean canApplyTaxAccommodation()
           
 void cancel(OrderCancelReason cancelReason, User user)
           
 void clearSpecialHandlingForLines(java.util.Set orderLines, User user)
           
 void clearTaxCalculationError()
          Clears tax calculation errors on all shipTos and all returnLines for this order
 void consolidatePreSettledPayments()
          Combines payments at settlement time according to payment account number, payment tender type, and whether the payment amount is positive or negative.
 void createBackorderNotificationHistoryEvent(CustomerOrderCorrespondenceRequest request, User user)
          Adds a new unsaved history event to the order with type = HistoryEventType.BO_NOTIFICATION.
 void createComponentReturnOnPackHistoryEvent(java.lang.String sellableItemId, User user)
          Adds a new unsaved history event to the order with type = HistoryEventType.COMPONENT_RETURN_ON_PACK
 void decrementOutstandingSalesAuditGoodwillAmount(Money amount)
          Decrease current outstanding sales audit goodwill amount by amount param
 Money generateRefundIfNegativeBalance()
          Generates a refund payment using the refund policy with transactionItem = null, payment tranaction type = CustomerOrderPaymentTransactionType.GENERIC_REFUND, refund balance = null, and no settlement.
 Money generateRefundIfNegativeBalance(CustomerOrderTransactionItem tranItem, CustomerOrderPaymentTransactionType transactionType)
          Generates a refund payment using the refund policy with transactionItem = tranItem param payment transaction type = transactionType param, refund balance = null, and no settlement.
 java.util.Set generateShipmentRequestsToReleaseToWms()
          Builds shipment requests based on ship to address, shipping method, carrier, and direct ship for all lines on the order that are ready to be released to the warehouse, as well as any pack lines that have any component lines that are ready to be released to the warehouse.
 java.util.List getAccommodations()
           
 java.util.List getAccommodations(AccommodationTypeEnum type)
           
 java.util.Set getAllAccommodations()
           
 java.util.Set getAllCustomerOrderPayments()
          Returns ALL the payments for the customer order (in no particular order).
 java.util.List getAllCustomerOrderPaymentsInSettlementOrder()
          Returns the payments for the customer order sorted by settlement (processing) order.
 java.util.Set getAllOfferCodes()
           
 java.util.Set getAllPackComponentLines()
           
 java.util.Collection getAllPromotionDiscountRollups()
          Return a summary of all promotion discount totals for the order, summarized by each Promotion applied to the order.
 java.util.Set getAllTransactionGroupItems()
           
 Money getBalance()
           
 Money getBalanceIncludingWaitingAuthorization()
           
 Banner getBanner()
           
 CustomerAddress getBillToAddress()
           
 RDate getCancelDate()
           
 OrderCancelReason getCancelReason()
           
 ChannelType getChannelType()
           
 RDate getCreateDate()
          Returns the date that this order was submitted.
 User getCreatedByUser()
           
 Customer getCustomer()
           
 java.util.List getCustomerOrderPendReasons()
           
 java.util.List getCustomerOrderPendReasons(boolean isActiveOnly)
           
 Media getDefaultMedia()
           
 CustomerAddress getDefaultShipToAddress()
           
 java.lang.String getDisplayNumber()
           
 GiftingDetail getGiftingDetailForLine(CustomerOrderLine orderLine)
           
 java.util.Set getGiftServiceLinesFromLineOrPrimary(CustomerOrderLine customerOrderLine)
           
 Money getGrandTotal()
           
 User getLastUpdatedByUser()
           
 RDate getLastUpdateTimestamp()
           
 RDate getLatestEstimatedDeliveryDate()
          Finds the latest estimated delivery date of the order lines on the order
 java.util.List getLinesForWrapTogether(java.lang.String wrapTogether)
           
 Address getOrderAcceptanceAddress()
           
 CustomerOrderLine getOrderLine(int lineNumber)
           
 java.util.List getOrderLines()
           
 OrderPriority getOrderPriority()
           
 OrderSource getOrderSource()
           
 OrderType getOrderType()
           
 Money getOutstandingSalesAuditGoodwillAmount()
           
 RDate getPendCancelByDate()
           
 Money getPreviouslyRecordedDemandAmount()
           
 java.util.Collection getPromotionDiscounts()
          Return promotion discount records applicable to the order (only those discounts that are stored at the order level).
 java.util.Set getQualifiedPromotions()
          Obtains the set of currently qualified promotions pertinent to this order.
 java.util.List getRefundables()
           
 ReplacementLinePair getReplacementLinePair(CustomerOrderLine saleLine)
           
 ReplacementLinePair getReplacementLinePair(ReturnLine returnLine)
           
 java.util.List getReturnableOrderLines()
           
 java.util.List getReturnLines()
           
 java.util.List getSellingItems()
           
 java.util.Set getShipmentRequests()
           
 java.util.Set getShipTos()
           
 java.util.Set getShipTos(boolean filterForCancelledLines)
           
 SourceCode getSourceCode()
           
 Media getSourceCodeMedia()
           
 Money getStandardShippingPromotionDiscountValue()
           
 com.retek.fsm.State getState()
           
 Store getStore()
           
 java.util.Set getTenderTypeGroups()
           
 java.util.Set getTenderTypes()
           
 Money getTotalAccommodationAmount()
           
 Money getTotalAccommodationTaxAmount()
           
 Money getTotalAdditionalShippingCharge()
           
 Money getTotalAuthorizedPaymentAmount()
           
 Money getTotalExtendedPrice()
           
 Money getTotalExtendedTax()
           
 Money getTotalGiftServiceCharge()
           
 Money getTotalNetExtendedPrice()
          Return the total net extended price for the order (total sale extended price, less any return extended price, less any merchandise accommodations/adjustments).
 Money getTotalNetGiftServiceCharge()
          Return the total net gift service charge for the order (total sale gift service charge, less any return gift service charge, less any gift service accommodations/adjustments).
 Money getTotalNetPersonalizationServiceCharge()
          Return the total net personalization service charge for the order (total sale personalization serivce charge, less any return personalization service charge, less any personalization service accommodations/adjustments).
 Money getTotalNetShippingCharge()
          Return the total net shipping charge for the order (total sale shipping charge, less any return shipping charge, less any shipping accommodations/adjustments).
 Money getTotalOrderHeaderAccommodationAmount()
           
 Money getTotalPayments()
           
 Money getTotalPaymentsIncludingWaitingAuthorization()
           
 Money getTotalPersonalizationServiceCharge()
           
 Money getTotalPromotionDiscountValue()
           
 Money getTotalReturnExtendedPrice()
           
 Money getTotalReturnPostageAmount()
           
 Money getTotalReturnTaxAdjustmentAmount()
           
 Money getTotalServiceCharge()
           
 Quantity getTotalShippedQuantity()
           
 Money getTotalShippingCharge()
           
 Money getTotalShippingTax()
           
 Money getTotalTax()
           
 Money getTotalValueAddedServiceTax()
           
 java.util.Set getTransactionGroupItems(CustomerOrderTransactionGroup transactionGroup)
           
 java.util.Set getTransactionGroups()
           
 Money getUnsettledAmount()
           
 boolean hasActiveManualPendReason()
           
 boolean hasEverBeenPendedForFraudReason()
           
 boolean hasInvalidNonCreditPaymentForSVC()
           
 boolean hasNewlyActivatedPLCCPayment()
           
 boolean hasNewPLCCCard()
           
 boolean hasNewPLCCPayment()
           
 boolean hasOrderPendReason(OrderPendReason reason)
           
 boolean hasUnpersistedSVCOrderLine()
           
 void incrementOutstandingSalesAuditGoodwillAmount(Money amount)
          Increase current outstanding sales audit goodwill amount by amount param
 boolean isBalanceWithinUnderpaymentTolerance()
           
 boolean isCancelled()
           
 boolean isClosed()
           
 boolean isExchangeSaleAllowed()
           
 boolean isMailOrder()
           
 boolean isMailOrderPreBatch()
           
 boolean isNewNormalOrderLineAllowed()
           
 boolean isOpen()
           
 boolean isOrderConfirmationPublished()
           
 boolean isPended()
           
 boolean isPendedForFraudReason()
           
 boolean isTaxCalculationValid()
           
 void pend(CustomerOrderPendReason customerOrderPendReason, User user)
          Pends an order for the given customer order pend reason.
 void pend(MailOrderBatch mailOrderBatch, CustomerOrderPendReason customerOrderPendReason, User user)
          Different variation on pend, used when the order is a mail order in mail-order-pre-batch state.
 void persistForSalesAuditExport(User user)
           
 void reapplyPromotions()
          Called by order user when they would like to genericly reapply promotions
 void reauthorizePayments()
          Perform reauthorization for credit card sale payments where the payment authorization has expired or where order lines have now reached appropriate lead time for authorization.
 void releaseFromMailOrderBatch(User user)
          Releases this order to the warehouse because it is a mail order and the batch this mail order belongs to was just released.
 void setBanner(Banner banner)
           
 void setBillToAddress(CustomerAddress billToAddress)
          Set the bill to address for the order.
 void setCustomer(Customer customer)
          (Re)sets the customer on the order.
 void setCustomerForCustomerMerge(Customer customer)
          (Re)sets the customer on the order.
 void setCustomerOrderPendReasons(java.util.List customerOrderPendReasons, User user)
           
 void setGenericHold(java.util.Set genericLines, GenericEvent genericEvent, User user)
           
 void setOrderPriority(OrderPriority priority)
           
 void setOrderType(OrderType orderType)
           
 void setPendCancelByDate(RDate pendedCancelDate)
           
 void setPersonalHoldDate(java.util.Set orderLines, RDate rDate, User user)
           
 void setProcessTogether(java.util.Set orderLines)
          Joins the set of orderLines into the same process together group.
 void setSourceCode(SourceCode sourceCode)
          Sets the default source code for the order
 void setStore(Store store)
           
 void settle(ShippedContainer shippedContainer, User user, Money origOrderTotalTax)
          Finalize payments for the shippedContainer, generate credit payment if there was any tax adjustment in the customers favor at ship time, and allocate settlement for all payments that are ready to be settled.
 void setWrapTogetherForLines(java.util.Set orderLines)
          Joins the set of orderLines into the same wrap together group.
 void submit(MailOrderBatch mailOrderBatch, User user)
          Persist this order to the database, perform minimal mail order submit validation, and add this order to the set of orders for the mailOrderBatch param.
 void submit(User user)
          Persist this order to the database and perform all order submit validation.
 void submit(User user, boolean doLightValidation)
          Persist this order to the database and perform all order submit validation.
 void submitForFirstTimeFromUI(MailOrderBatch mailOrderBatch, User user, java.lang.String originalOrderSummaryData)
           
 void submitForFirstTimeFromUI(User user, java.lang.String orginalOrderSummary)
          Persist this order to the database and perform all order submit validation.
 void virtualWarehouseReserve(User user)
           
 
Methods inherited from interface com.retek.commons.component.DistributedObject
debugToString, discardChanges, getContext, getId, getReference, isDeleted, isDirty, isDirtyDeep, isDirtyIgnoreFields, isPersisted, refresh
 
Methods inherited from interface com.retek.commons.component.BusinessObject
getBusinessInterface
 

Field Detail

DISPLAY_NUMBER

public static final java.lang.String DISPLAY_NUMBER
See Also:
Constant Field Values

CREATED_BY_USER

public static final java.lang.String CREATED_BY_USER
See Also:
Constant Field Values

CUSTOMER

public static final java.lang.String CUSTOMER
See Also:
Constant Field Values

BANNER

public static final java.lang.String BANNER
See Also:
Constant Field Values

ORDER_PRIORITY

public static final java.lang.String ORDER_PRIORITY
See Also:
Constant Field Values

SHIP_TO_ADDRESS

public static final java.lang.String SHIP_TO_ADDRESS
See Also:
Constant Field Values

BILL_TO_ADDRESS

public static final java.lang.String BILL_TO_ADDRESS
See Also:
Constant Field Values

ORDER_LINE

public static final java.lang.String ORDER_LINE
See Also:
Constant Field Values

ORDER_SOURCE

public static final java.lang.String ORDER_SOURCE
See Also:
Constant Field Values

PRIORITY

public static final java.lang.String PRIORITY
See Also:
Constant Field Values

SOURCE_CODE

public static final java.lang.String SOURCE_CODE
See Also:
Constant Field Values

BALANCE

public static final java.lang.String BALANCE
See Also:
Constant Field Values

SHIPPED_CONTAINER

public static final java.lang.String SHIPPED_CONTAINER
See Also:
Constant Field Values

ACCOMMODATION

public static final java.lang.String ACCOMMODATION
See Also:
Constant Field Values

PAYMENT

public static final java.lang.String PAYMENT
See Also:
Constant Field Values

ORDER_TYPE

public static final java.lang.String ORDER_TYPE
See Also:
Constant Field Values

MAIL_ORDER_BATCH

public static final java.lang.String MAIL_ORDER_BATCH
See Also:
Constant Field Values

ZERO_SALE_LINE

public static final java.lang.String ZERO_SALE_LINE
See Also:
Constant Field Values

CANCEL_PENDED_ORDER_DATE

public static final java.lang.String CANCEL_PENDED_ORDER_DATE
See Also:
Constant Field Values

TAX_ACCOMMODATION

public static final java.lang.String TAX_ACCOMMODATION
See Also:
Constant Field Values

RETURN_LINE

public static final java.lang.String RETURN_LINE
See Also:
Constant Field Values

STORE

public static final java.lang.String STORE
See Also:
Constant Field Values
Method Detail

getDisplayNumber

public java.lang.String getDisplayNumber()
                                  throws SystemException
Throws:
SystemException

getCreatedByUser

public User getCreatedByUser()
                      throws SystemException,
                             BusinessException
Throws:
SystemException
BusinessException

getLastUpdatedByUser

public User getLastUpdatedByUser()
                          throws SystemException
Throws:
SystemException

getOrderType

public OrderType getOrderType()
                       throws SystemException
Throws:
SystemException

getState

public com.retek.fsm.State getState()
                             throws SystemException
Throws:
SystemException

getCreateDate

public RDate getCreateDate()
                    throws SystemException
Returns the date that this order was submitted.

Returns:
RDate createDate
Throws:
SystemException

getCancelDate

public RDate getCancelDate()
                    throws SystemException
Throws:
SystemException

getPendCancelByDate

public RDate getPendCancelByDate()
                          throws SystemException
Throws:
SystemException

getLastUpdateTimestamp

public RDate getLastUpdateTimestamp()
                             throws SystemException
Throws:
SystemException

getOrderPriority

public OrderPriority getOrderPriority()
                               throws SystemException
Throws:
SystemException

getCustomer

public Customer getCustomer()
                     throws SystemException
Throws:
SystemException

getBanner

public Banner getBanner()
                 throws SystemException
Throws:
SystemException

getChannelType

public ChannelType getChannelType()
                           throws SystemException,
                                  BusinessException
Throws:
SystemException
BusinessException

getDefaultShipToAddress

public CustomerAddress getDefaultShipToAddress()
                                        throws SystemException,
                                               BusinessException
Throws:
SystemException
BusinessException

getBillToAddress

public CustomerAddress getBillToAddress()
                                 throws SystemException,
                                        BusinessException
Throws:
SystemException
BusinessException

getSourceCode

public SourceCode getSourceCode()
                         throws SystemException
Throws:
SystemException

getSourceCodeMedia

public Media getSourceCodeMedia()
                         throws SystemException,
                                BusinessException
Throws:
SystemException
BusinessException

getDefaultMedia

public Media getDefaultMedia()
                      throws SystemException
Throws:
SystemException

getReplacementLinePair

public ReplacementLinePair getReplacementLinePair(CustomerOrderLine saleLine)
                                           throws SystemException
Throws:
SystemException

getReplacementLinePair

public ReplacementLinePair getReplacementLinePair(ReturnLine returnLine)
                                           throws SystemException
Throws:
SystemException

getTotalExtendedPrice

public Money getTotalExtendedPrice()
                            throws SystemException,
                                   BusinessException
Throws:
SystemException
BusinessException

getStandardShippingPromotionDiscountValue

public Money getStandardShippingPromotionDiscountValue()
                                                throws SystemException
Throws:
SystemException

getTotalPromotionDiscountValue

public Money getTotalPromotionDiscountValue()
                                     throws SystemException
Throws:
SystemException

getTotalShippingCharge

public Money getTotalShippingCharge()
                             throws SystemException,
                                    BusinessException
Throws:
SystemException
BusinessException

getTotalAdditionalShippingCharge

public Money getTotalAdditionalShippingCharge()
                                       throws SystemException,
                                              BusinessException
Throws:
SystemException
BusinessException

getTotalReturnPostageAmount

public Money getTotalReturnPostageAmount()
                                  throws SystemException
Throws:
SystemException

getTotalServiceCharge

public Money getTotalServiceCharge()
                            throws SystemException,
                                   BusinessException
Throws:
SystemException
BusinessException

getTotalGiftServiceCharge

public Money getTotalGiftServiceCharge()
                                throws SystemException,
                                       BusinessException
Throws:
SystemException
BusinessException

getTotalPersonalizationServiceCharge

public Money getTotalPersonalizationServiceCharge()
                                           throws SystemException,
                                                  BusinessException
Throws:
SystemException
BusinessException

getGrandTotal

public Money getGrandTotal()
                    throws SystemException,
                           BusinessException
Throws:
SystemException
BusinessException

getTotalNetExtendedPrice

public Money getTotalNetExtendedPrice()
                               throws SystemException,
                                      BusinessException
Return the total net extended price for the order (total sale extended price, less any return extended price, less any merchandise accommodations/adjustments).

Returns:
Money total net extended price
Throws:
SystemException
BusinessException

getTotalNetShippingCharge

public Money getTotalNetShippingCharge()
                                throws SystemException,
                                       BusinessException
Return the total net shipping charge for the order (total sale shipping charge, less any return shipping charge, less any shipping accommodations/adjustments).

Returns:
Money total net shipping charge
Throws:
SystemException
BusinessException

getTotalNetGiftServiceCharge

public Money getTotalNetGiftServiceCharge()
                                   throws SystemException,
                                          BusinessException
Return the total net gift service charge for the order (total sale gift service charge, less any return gift service charge, less any gift service accommodations/adjustments).

Returns:
Money total net gift service charge
Throws:
SystemException
BusinessException

getTotalNetPersonalizationServiceCharge

public Money getTotalNetPersonalizationServiceCharge()
                                              throws SystemException,
                                                     BusinessException
Return the total net personalization service charge for the order (total sale personalization serivce charge, less any return personalization service charge, less any personalization service accommodations/adjustments).

Returns:
Money total net personalization service charge
Throws:
SystemException
BusinessException

getTotalPayments

public Money getTotalPayments()
                       throws SystemException,
                              BusinessException
Throws:
SystemException
BusinessException

getTotalAuthorizedPaymentAmount

public Money getTotalAuthorizedPaymentAmount()
                                      throws SystemException,
                                             BusinessException
Throws:
SystemException
BusinessException

getTotalPaymentsIncludingWaitingAuthorization

public Money getTotalPaymentsIncludingWaitingAuthorization()
                                                    throws SystemException,
                                                           BusinessException
Throws:
SystemException
BusinessException

getBalance

public Money getBalance()
                 throws SystemException,
                        BusinessException
Throws:
SystemException
BusinessException

getBalanceIncludingWaitingAuthorization

public Money getBalanceIncludingWaitingAuthorization()
                                              throws SystemException,
                                                     BusinessException
Throws:
SystemException
BusinessException

getTotalExtendedTax

public Money getTotalExtendedTax()
                          throws BusinessException,
                                 SystemException
Throws:
BusinessException
SystemException

getTotalShippingTax

public Money getTotalShippingTax()
                          throws BusinessException,
                                 SystemException
Throws:
BusinessException
SystemException

getTotalValueAddedServiceTax

public Money getTotalValueAddedServiceTax()
                                   throws BusinessException,
                                          SystemException
Throws:
BusinessException
SystemException

getTotalTax

public Money getTotalTax()
                  throws BusinessException,
                         SystemException
Throws:
BusinessException
SystemException

getPreviouslyRecordedDemandAmount

public Money getPreviouslyRecordedDemandAmount()
                                        throws SystemException
Throws:
SystemException

getTotalAccommodationAmount

public Money getTotalAccommodationAmount()
                                  throws SystemException,
                                         BusinessException
Throws:
SystemException
BusinessException

getTotalAccommodationTaxAmount

public Money getTotalAccommodationTaxAmount()
                                     throws SystemException
Throws:
SystemException

getTotalReturnTaxAdjustmentAmount

public Money getTotalReturnTaxAdjustmentAmount()
                                        throws SystemException
Throws:
SystemException

getTotalOrderHeaderAccommodationAmount

public Money getTotalOrderHeaderAccommodationAmount()
                                             throws SystemException,
                                                    BusinessException
Throws:
SystemException
BusinessException

getTotalReturnExtendedPrice

public Money getTotalReturnExtendedPrice()
                                  throws SystemException,
                                         BusinessException
Throws:
SystemException
BusinessException

isCancelled

public boolean isCancelled()
                    throws SystemException
Throws:
SystemException

isPended

public boolean isPended()
                 throws SystemException
Throws:
SystemException

isClosed

public boolean isClosed()
                 throws SystemException
Throws:
SystemException

isOpen

public boolean isOpen()
               throws SystemException
Throws:
SystemException

isMailOrderPreBatch

public boolean isMailOrderPreBatch()
                            throws SystemException
Throws:
SystemException

isMailOrder

public boolean isMailOrder()
                    throws SystemException
Throws:
SystemException

isNewNormalOrderLineAllowed

public boolean isNewNormalOrderLineAllowed()
                                    throws SystemException,
                                           BusinessException
Throws:
SystemException
BusinessException

isExchangeSaleAllowed

public boolean isExchangeSaleAllowed()
                              throws SystemException
Throws:
SystemException

isPendedForFraudReason

public boolean isPendedForFraudReason()
                               throws SystemException,
                                      BusinessException
Throws:
SystemException
BusinessException

isTaxCalculationValid

public boolean isTaxCalculationValid()
                              throws BusinessException,
                                     SystemException
Throws:
BusinessException
SystemException

isOrderConfirmationPublished

public boolean isOrderConfirmationPublished()
                                     throws SystemException
Throws:
SystemException

hasEverBeenPendedForFraudReason

public boolean hasEverBeenPendedForFraudReason()
                                        throws SystemException,
                                               BusinessException
Throws:
SystemException
BusinessException

hasActiveManualPendReason

public boolean hasActiveManualPendReason()
                                  throws SystemException,
                                         BusinessException
Throws:
SystemException
BusinessException

hasOrderPendReason

public boolean hasOrderPendReason(OrderPendReason reason)
                           throws SystemException
Throws:
SystemException

hasNewlyActivatedPLCCPayment

public boolean hasNewlyActivatedPLCCPayment()
                                     throws SystemException,
                                            BusinessException
Throws:
SystemException
BusinessException

hasNewPLCCCard

public boolean hasNewPLCCCard()
                       throws SystemException,
                              BusinessException
Throws:
SystemException
BusinessException

hasNewPLCCPayment

public boolean hasNewPLCCPayment()
                          throws SystemException,
                                 BusinessException
Throws:
SystemException
BusinessException

hasUnpersistedSVCOrderLine

public boolean hasUnpersistedSVCOrderLine()
                                   throws SystemException
Throws:
SystemException

hasInvalidNonCreditPaymentForSVC

public boolean hasInvalidNonCreditPaymentForSVC()
                                         throws SystemException
Throws:
SystemException

canApplyTaxAccommodation

public boolean canApplyTaxAccommodation()
                                 throws SystemException
Throws:
SystemException

getCancelReason

public OrderCancelReason getCancelReason()
                                  throws SystemException
Throws:
SystemException

getTotalShippedQuantity

public Quantity getTotalShippedQuantity()
                                 throws SystemException
Throws:
SystemException

getOrderSource

public OrderSource getOrderSource()
                           throws SystemException
Throws:
SystemException

getGiftingDetailForLine

public GiftingDetail getGiftingDetailForLine(CustomerOrderLine orderLine)
                                      throws SystemException,
                                             BusinessException
Throws:
SystemException
BusinessException

getOrderLine

public CustomerOrderLine getOrderLine(int lineNumber)
                               throws SystemException
Throws:
SystemException

getSellingItems

public java.util.List getSellingItems()
                               throws SystemException
Throws:
SystemException

getRefundables

public java.util.List getRefundables()
                              throws SystemException,
                                     BusinessException
Throws:
SystemException
BusinessException

getLinesForWrapTogether

public java.util.List getLinesForWrapTogether(java.lang.String wrapTogether)
                                       throws SystemException
Throws:
SystemException

getPromotionDiscounts

public java.util.Collection getPromotionDiscounts()
                                           throws SystemException
Return promotion discount records applicable to the order (only those discounts that are stored at the order level).

Returns:
Collection order-level promotion discounts
Throws:
SystemException

getAllPromotionDiscountRollups

public java.util.Collection getAllPromotionDiscountRollups()
                                                    throws SystemException
Return a summary of all promotion discount totals for the order, summarized by each Promotion applied to the order. The roll-up summary objects contain a total discount amount for any discounts on the order (for all discounts at any level, ie. at the order level, order line, and service line levels). This summary can be used to report a breakdown of order level promotion totals by promotion. Note1: This summary should be used for display purposes only. Financial computations should be based off of the lower level api. Note2: These totals are a rolled up summary of discount records and thus do not account for any return promotion adjustments.

Returns:
Collection CustomerOrderPromotionDiscountRollup summary objects
Throws:
SystemException
See Also:
CustomerOrderPromotionDiscountRollup

getTenderTypeGroups

public java.util.Set getTenderTypeGroups()
                                  throws SystemException,
                                         BusinessException
Throws:
SystemException
BusinessException

getTenderTypes

public java.util.Set getTenderTypes()
                             throws SystemException,
                                    BusinessException
Throws:
SystemException
BusinessException

getReturnLines

public java.util.List getReturnLines()
                              throws SystemException
Throws:
SystemException

getOrderLines

public java.util.List getOrderLines()
                             throws SystemException
Throws:
SystemException

getReturnableOrderLines

public java.util.List getReturnableOrderLines()
                                       throws SystemException
Throws:
SystemException

getTransactionGroups

public java.util.Set getTransactionGroups()
                                   throws SystemException
Throws:
SystemException

getGiftServiceLinesFromLineOrPrimary

public java.util.Set getGiftServiceLinesFromLineOrPrimary(CustomerOrderLine customerOrderLine)
                                                   throws SystemException
Throws:
SystemException

getAllOfferCodes

public java.util.Set getAllOfferCodes()
                               throws SystemException
Throws:
SystemException

getCustomerOrderPendReasons

public java.util.List getCustomerOrderPendReasons()
                                           throws SystemException
Throws:
SystemException

getCustomerOrderPendReasons

public java.util.List getCustomerOrderPendReasons(boolean isActiveOnly)
                                           throws SystemException
Throws:
SystemException

getShipTos

public java.util.Set getShipTos()
                         throws SystemException
Throws:
SystemException

getShipTos

public java.util.Set getShipTos(boolean filterForCancelledLines)
                         throws SystemException
Throws:
SystemException

getAllAccommodations

public java.util.Set getAllAccommodations()
                                   throws SystemException
Throws:
SystemException

getAccommodations

public java.util.List getAccommodations()
                                 throws SystemException
Throws:
SystemException

getAccommodations

public java.util.List getAccommodations(AccommodationTypeEnum type)
                                 throws SystemException
Throws:
SystemException

getAllTransactionGroupItems

public java.util.Set getAllTransactionGroupItems()
                                          throws SystemException
Throws:
SystemException

getTransactionGroupItems

public java.util.Set getTransactionGroupItems(CustomerOrderTransactionGroup transactionGroup)
                                       throws SystemException
Throws:
SystemException

getShipmentRequests

public java.util.Set getShipmentRequests()
                                  throws SystemException
Throws:
SystemException

getAllCustomerOrderPaymentsInSettlementOrder

public java.util.List getAllCustomerOrderPaymentsInSettlementOrder()
                                                            throws SystemException,
                                                                   BusinessException
Returns the payments for the customer order sorted by settlement (processing) order.

Returns:
List all customer order payments in settlement order
Throws:
SystemException
BusinessException

getAllCustomerOrderPayments

public java.util.Set getAllCustomerOrderPayments()
                                          throws SystemException
Returns ALL the payments for the customer order (in no particular order).

Returns:
Set all customer order payments
Throws:
SystemException

addPayment

public void addPayment(CustomerOrderPayment payment)
                throws BusinessException,
                       SystemException
Throws:
BusinessException
SystemException

addOfferCode

public void addOfferCode(OfferCode offerCode)
                  throws SystemException
Throws:
SystemException

setPendCancelByDate

public void setPendCancelByDate(RDate pendedCancelDate)
                         throws SystemException,
                                BusinessException
Throws:
SystemException
BusinessException

setCustomerOrderPendReasons

public void setCustomerOrderPendReasons(java.util.List customerOrderPendReasons,
                                        User user)
                                 throws SystemException,
                                        BusinessException
Throws:
SystemException
BusinessException

setOrderPriority

public void setOrderPriority(OrderPriority priority)
                      throws SystemException
Throws:
SystemException

setOrderType

public void setOrderType(OrderType orderType)
                  throws SystemException,
                         BusinessException
Throws:
CustomerOrderBusinessException - if order has one or more lines
SystemException
BusinessException

setCustomer

public void setCustomer(Customer customer)
                 throws SystemException,
                        BusinessException
(Re)sets the customer on the order. Any previously held customer-related order attributes (i.e. dayPhone, evePhone, email, billToAddress, shipToAddress) are reset to the new customer's default values.

Throws:
java.lang.IllegalArgumentException - if customer is null
SystemException
BusinessException

setCustomerForCustomerMerge

public void setCustomerForCustomerMerge(Customer customer)
                                 throws SystemException,
                                        BusinessException
(Re)sets the customer on the order. DOES NOT reset any previously held customer-related order attributes. All other customer attributes should have already been moved to this order as a new customer.

Throws:
java.lang.IllegalArgumentException - if customer is null
SystemException
BusinessException

setBanner

public void setBanner(Banner banner)
               throws SystemException
Throws:
java.lang.IllegalArgumentException - if banner is null
SystemException

setBillToAddress

public void setBillToAddress(CustomerAddress billToAddress)
                      throws SystemException,
                             BusinessException
Set the bill to address for the order.

Throws:
SystemException
BusinessException

setSourceCode

public void setSourceCode(SourceCode sourceCode)
                   throws SystemException,
                          BusinessException
Sets the default source code for the order

Throws:
java.lang.IllegalStateException - if order is not in new state
SystemException
BusinessException

setProcessTogether

public void setProcessTogether(java.util.Set orderLines)
                        throws SystemException,
                               BusinessException
Joins the set of orderLines into the same process together group.

Throws:
CustomerOrderBusinessException - if processTogether fails business validation
SystemException
BusinessException

setWrapTogetherForLines

public void setWrapTogetherForLines(java.util.Set orderLines)
                             throws SystemException,
                                    BusinessException
Joins the set of orderLines into the same wrap together group.

Throws:
CustomerOrderBusinessException - if wrapTogether fails business validation.
SystemException
BusinessException

setPersonalHoldDate

public void setPersonalHoldDate(java.util.Set orderLines,
                                RDate rDate,
                                User user)
                         throws SystemException,
                                BusinessException
Throws:
CustomerOrderBusinessException - if personal hold date fails business validation
SystemException
BusinessException

setGenericHold

public void setGenericHold(java.util.Set genericLines,
                           GenericEvent genericEvent,
                           User user)
                    throws SystemException,
                           BusinessException
Throws:
InvalidHoldException - if genericEvent fails business validation
SystemException
BusinessException

applyOrderLine

public void applyOrderLine(CustomerOrderLine orderLine,
                           User user)
                    throws InvalidOrderLineException,
                           ItemNotAvailableException,
                           OrderQtyNotReservedException,
                           SystemException,
                           BusinessException
Adds orderLine to the set of order lines for this order, reserves this order line, and applies promotions.

Throws:
InvalidOrderLineException
ItemNotAvailableException
OrderQtyNotReservedException
SystemException
BusinessException

applyReturnLine

public void applyReturnLine(ReturnLine returnLine,
                            User user)
                     throws SystemException,
                            BusinessException
Adds returnLine to the order, clears calculated totals on the return line's shipTo.

Throws:
SystemException
BusinessException

applyReplacement

public void applyReplacement(ReplacementLinePair replacementGroup,
                             User user)
                      throws SystemException,
                             BusinessException
Adds replacementLine from replacementGroup to the order and reserves the replacement line

Throws:
SystemException
BusinessException

applyGiftingDetailToLines

public void applyGiftingDetailToLines(java.util.Set orderLines,
                                      GiftingDetail giftingDetail)
                               throws SystemException,
                                      BusinessException
Throws:
CustomerOrderBusinessException - if gifting details fails business validation
SystemException
BusinessException

addJustPublishedToWmsShipmentRequest

public void addJustPublishedToWmsShipmentRequest(ShipmentRequest shipmentRequest,
                                                 User user)
                                          throws SystemException,
                                                 BusinessException
Throws:
java.lang.IllegalStateException - if this shipmentRequest already belongs to this order
SystemException
BusinessException

clearTaxCalculationError

public void clearTaxCalculationError()
                              throws BusinessException,
                                     SystemException
Clears tax calculation errors on all shipTos and all returnLines for this order

Throws:
BusinessException
SystemException

clearSpecialHandlingForLines

public void clearSpecialHandlingForLines(java.util.Set orderLines,
                                         User user)
                                  throws SystemException,
                                         BusinessException
Throws:
SystemException
BusinessException

getUnsettledAmount

public Money getUnsettledAmount()
                         throws SystemException
Throws:
SystemException

getOutstandingSalesAuditGoodwillAmount

public Money getOutstandingSalesAuditGoodwillAmount()
                                             throws SystemException
Throws:
SystemException

decrementOutstandingSalesAuditGoodwillAmount

public void decrementOutstandingSalesAuditGoodwillAmount(Money amount)
                                                  throws SystemException
Decrease current outstanding sales audit goodwill amount by amount param

Throws:
java.lang.IllegalStateException - if salesAuditGoodwillAmount would be negative when decreasing by this amount
SystemException

incrementOutstandingSalesAuditGoodwillAmount

public void incrementOutstandingSalesAuditGoodwillAmount(Money amount)
                                                  throws SystemException
Increase current outstanding sales audit goodwill amount by amount param

Throws:
SystemException

submit

public void submit(User user)
            throws SystemException,
                   InvalidCustomerException,
                   InvalidCustomerOrderException,
                   BusinessException
Persist this order to the database and perform all order submit validation.

Throws:
SystemException
InvalidCustomerException
InvalidCustomerOrderException
BusinessException

submit

public void submit(User user,
                   boolean doLightValidation)
            throws SystemException,
                   BusinessException
Persist this order to the database and perform all order submit validation.

Parameters:
user - order create user
doLightValidation - flag indicating whether to perform full submit business validation or light persist validation (no business checks)
Throws:
SystemException
BusinessException

submit

public void submit(MailOrderBatch mailOrderBatch,
                   User user)
            throws SystemException,
                   InvalidCustomerException,
                   InvalidCustomerOrderException,
                   BusinessException
Persist this order to the database, perform minimal mail order submit validation, and add this order to the set of orders for the mailOrderBatch param.

Throws:
SystemException
InvalidCustomerException
InvalidCustomerOrderException
BusinessException

submitForFirstTimeFromUI

public void submitForFirstTimeFromUI(MailOrderBatch mailOrderBatch,
                                     User user,
                                     java.lang.String originalOrderSummaryData)
                              throws SystemException,
                                     InvalidCustomerException,
                                     InvalidCustomerOrderException,
                                     BusinessException
Throws:
SystemException
InvalidCustomerException
InvalidCustomerOrderException
BusinessException

cancel

public void cancel(OrderCancelReason cancelReason,
                   User user)
            throws SystemException,
                   InvalidCustomerException,
                   InvalidCustomerOrderException,
                   BusinessException
Throws:
SystemException
InvalidCustomerException
InvalidCustomerOrderException
BusinessException

addHistoryEventRequest

public void addHistoryEventRequest(HistoryEventRequest eventRequest)
                            throws SystemException
Create a new history event request and add to the collection of requests so later history events can be created when order is submitted.

Parameters:
eventRequest - history event request to add to the order
Throws:
SystemException

releaseFromMailOrderBatch

public void releaseFromMailOrderBatch(User user)
                               throws SystemException,
                                      BusinessException
Releases this order to the warehouse because it is a mail order and the batch this mail order belongs to was just released.

Throws:
SystemException
BusinessException

pend

public void pend(CustomerOrderPendReason customerOrderPendReason,
                 User user)
          throws SystemException,
                 BusinessException
Pends an order for the given customer order pend reason. A CustomerOrderPendReason is a relationship object which wraps a given OrderPendReason.

Parameters:
customerOrderPendReason - new customer order pend reason object
Throws:
SystemException
BusinessException
See Also:
CustomerOrderManager#buildCustomerOrderPendReason(OrderPendReason)

pend

public void pend(MailOrderBatch mailOrderBatch,
                 CustomerOrderPendReason customerOrderPendReason,
                 User user)
          throws SystemException,
                 BusinessException
Different variation on pend, used when the order is a mail order in mail-order-pre-batch state. Persists the order with the batch, sets the pend reason onto the order, but does not send the mail order to the pend state, instead stays in mailOrderPreBatch state

Parameters:
mailOrderBatch - mail order batch that this mail order belongs to
Throws:
SystemException
BusinessException
See Also:
CustomerOrderManager#buildCustomerOrderPendReason(OrderPendReason)

settle

public void settle(ShippedContainer shippedContainer,
                   User user,
                   Money origOrderTotalTax)
            throws SystemException,
                   BusinessException
Finalize payments for the shippedContainer, generate credit payment if there was any tax adjustment in the customers favor at ship time, and allocate settlement for all payments that are ready to be settled.

Throws:
SystemException
BusinessException

persistForSalesAuditExport

public void persistForSalesAuditExport(User user)
                                throws SystemException,
                                       BusinessException
Throws:
SystemException
BusinessException

authorizePayment

public void authorizePayment(CustomerOrderPayment payment)
                      throws SystemException,
                             BusinessException
Using an authorization calculation strategy, calculates the amount to be authorized for this payment. After the amount to authorize is computed 1.If the amount to authorize is $0 then if the payment had NOT already been authorized for $1 authorize the payment for $1. Otherwise, don't auth the payment and return. 2. If the amount to authorize is not $0 then subtract out the previously authorized amount and then do the $0 check

Throws:
SystemException
BusinessException

authorizePaymentManually

public void authorizePaymentManually(CustomerOrderPayment payment,
                                     java.lang.String authCode,
                                     User user)
                              throws SystemException,
                                     BusinessException
For payments needing manual authorization, manually authorize the payment by storing the authorization code and authorization date.

Throws:
SystemException
BusinessException

reauthorizePayments

public void reauthorizePayments()
                         throws SystemException,
                                BusinessException
Perform reauthorization for credit card sale payments where the payment authorization has expired or where order lines have now reached appropriate lead time for authorization.

Throws:
SystemException
BusinessException

generateShipmentRequestsToReleaseToWms

public java.util.Set generateShipmentRequestsToReleaseToWms()
                                                     throws SystemException,
                                                            BusinessException
Builds shipment requests based on ship to address, shipping method, carrier, and direct ship for all lines on the order that are ready to be released to the warehouse, as well as any pack lines that have any component lines that are ready to be released to the warehouse.

Throws:
java.lang.IllegalStateException - if the shipping method or carrier on any of the releasable lines or component lines is null.
SystemException
BusinessException

addAccommodationAndGeneratePayment

public void addAccommodationAndGeneratePayment(Accommodation accomodation,
                                               Refundable refundable)
                                        throws SystemException,
                                               BusinessException
Calculates the value of the accommodation, adds the accommodation to the order, generates a credit payment for the accommodation, sets the order priority to HIGH, and generates a history event for the accommodation. If generating the credit payment caused an exception, the accommodation is removed from the order.

Throws:
InvalidCustomerOrderException - if the accommodation fails business validation.
java.lang.IllegalArgumentException - if the accommodation is not an order accommodation or an order line accommodation
SystemException
BusinessException

addTransactionGroup

public void addTransactionGroup(CustomerOrderTransactionGroup transactionGroup)
                         throws SystemException
Throws:
SystemException

consolidatePreSettledPayments

public void consolidatePreSettledPayments()
                                   throws SystemException,
                                          BusinessException
Combines payments at settlement time according to payment account number, payment tender type, and whether the payment amount is positive or negative.

Throws:
SystemException
BusinessException

createBackorderNotificationHistoryEvent

public void createBackorderNotificationHistoryEvent(CustomerOrderCorrespondenceRequest request,
                                                    User user)
                                             throws SystemException,
                                                    BusinessException
Adds a new unsaved history event to the order with type = HistoryEventType.BO_NOTIFICATION.

Throws:
SystemException
BusinessException

createComponentReturnOnPackHistoryEvent

public void createComponentReturnOnPackHistoryEvent(java.lang.String sellableItemId,
                                                    User user)
                                             throws SystemException,
                                                    BusinessException
Adds a new unsaved history event to the order with type = HistoryEventType.COMPONENT_RETURN_ON_PACK

Throws:
SystemException
BusinessException

generateRefundIfNegativeBalance

public Money generateRefundIfNegativeBalance(CustomerOrderTransactionItem tranItem,
                                             CustomerOrderPaymentTransactionType transactionType)
                                      throws SystemException,
                                             BusinessException
Generates a refund payment using the refund policy with transactionItem = tranItem param payment transaction type = transactionType param, refund balance = null, and no settlement.

Returns:
Money value of refund generated
Throws:
SystemException
BusinessException
See Also:
CustomerOrderGeneralRefundPolicyCommand

generateRefundIfNegativeBalance

public Money generateRefundIfNegativeBalance()
                                      throws SystemException,
                                             BusinessException
Generates a refund payment using the refund policy with transactionItem = null, payment tranaction type = CustomerOrderPaymentTransactionType.GENERIC_REFUND, refund balance = null, and no settlement.

Returns:
Money value of refund generated
Throws:
SystemException
BusinessException
See Also:
CustomerOrderGeneralRefundPolicyCommand

getLatestEstimatedDeliveryDate

public RDate getLatestEstimatedDeliveryDate()
                                     throws SystemException
Finds the latest estimated delivery date of the order lines on the order

Returns:
RDate Latest date
Throws:
SystemException

getQualifiedPromotions

public java.util.Set getQualifiedPromotions()
                                     throws SystemException
Obtains the set of currently qualified promotions pertinent to this order. "Qualified" promotions are those that are: (1) visible via the prevailing trigger(s), and (2) have passed one or more thresholds but have not yet been either automatically or manually (via the UI) "accepted".

Throws:
SystemException

submitForFirstTimeFromUI

public void submitForFirstTimeFromUI(User user,
                                     java.lang.String orginalOrderSummary)
                              throws SystemException,
                                     BusinessException
Persist this order to the database and perform all order submit validation. This is called only from the UI and only once. i.e. when the order gets submitted for the first time.

Parameters:
orginalOrderSummary - Initial order summary page information in HTML format.
Throws:
SystemException
BusinessException

applyPromotionalOrderLine

public void applyPromotionalOrderLine(CustomerOrderLine orderLine,
                                      User user,
                                      Promotion promotion)
                               throws SystemException,
                                      BusinessException
Throws:
SystemException
BusinessException

applyPromotionalPaymentPlanCode

public void applyPromotionalPaymentPlanCode(PaymentPlanCode selectedPaymentPlanCode,
                                            Promotion promotion)
                                     throws SystemException,
                                            BusinessException
Parameters:
promotion - This is the promotion containing the tender type of the payment for which the parameter selectedPaymentPlanCode should be set.
selectedPaymentPlanCode - This is the user selected payment plan code that should be set on the the payment matching tenderType found on parameter promotion.
Throws:
SystemException
BusinessException

reapplyPromotions

public void reapplyPromotions()
                       throws BusinessException,
                              SystemException
Called by order user when they would like to genericly reapply promotions

Throws:
BusinessException
SystemException

virtualWarehouseReserve

public void virtualWarehouseReserve(User user)
                             throws SystemException,
                                    BusinessException
Throws:
SystemException
BusinessException

getAllPackComponentLines

public java.util.Set getAllPackComponentLines()
                                       throws SystemException
Throws:
SystemException

getStore

public Store getStore()
               throws SystemException
Throws:
SystemException

setStore

public void setStore(Store store)
              throws SystemException,
                     BusinessException
Throws:
SystemException
BusinessException

getOrderAcceptanceAddress

public Address getOrderAcceptanceAddress()
                                  throws SystemException,
                                         BusinessException
Returns:
Address This is the address that should be used in tax calculation for order acceptance.
Throws:
SystemException
BusinessException

addCallTag

public void addCallTag(User user,
                       CallTag callTag)
                throws SystemException,
                       BusinessException
Throws:
SystemException
BusinessException

isBalanceWithinUnderpaymentTolerance

public boolean isBalanceWithinUnderpaymentTolerance()
                                             throws SystemException,
                                                    BusinessException
Returns:
boolean True if order.getBalance() <= Banner underpayment tolerance amount
Throws:
SystemException
BusinessException


Copyright © 2005 Retek Inc. All Rights Reserved. - Generated at Fri, 01/21/2005 14:25