Class ValidateAndConfirmPaymentActivity

java.lang.Object
org.broadleafcommerce.core.workflow.BaseActivity<ProcessContext<CheckoutSeed>>
org.broadleafcommerce.core.checkout.service.workflow.ValidateAndConfirmPaymentActivity
All Implemented Interfaces:
Activity<ProcessContext<CheckoutSeed>>, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware, org.springframework.core.Ordered

@Component("blValidateAndConfirmPaymentActivity") public class ValidateAndConfirmPaymentActivity extends BaseActivity<ProcessContext<CheckoutSeed>>

This activity is responsible for validating and processing several aspects of an order's payment so that it may successfully complete the checkout workflow. This activity will:

  • Verify that there is enough payment on the order via the successful amount on PaymentTransactionType.AUTHORIZE and PaymentTransactionType.AUTHORIZE_AND_CAPTURE and PaymentTransactionType.PENDING transactions.
  • "Confirm" any PaymentTransactionType.UNCONFIRMED transactions that exist on an OrderPayment. This can mean different things depending on the type of Order Payment and is handled by the OrderPaymentConfirmationStrategy
  • If there is an exception (either in this activity or later downstream) the confirmed payments are rolled back via ConfirmPaymentsRollbackHandler. It will also by default attempt to mark the payment as "ARCHIVED" so that the user may attempt to re-enter their payment details.

Author:
Phillip Verheyden (phillipuniverse), Elbert Bautista (elbertbautista)