@Service(value="blOrderPaymentService") public class OrderPaymentServiceImpl extends Object implements OrderPaymentService
| Modifier and Type | Field and Description | 
|---|---|
| protected AddressService | addressService | 
| protected CustomerPaymentService | customerPaymentService | 
| protected OrderPaymentDao | paymentDao | 
| Constructor and Description | 
|---|
| OrderPaymentServiceImpl() | 
protected OrderPaymentDao paymentDao
protected CustomerPaymentService customerPaymentService
protected AddressService addressService
@Transactional(value="blTransactionManager") public OrderPayment save(OrderPayment payment)
save in interface OrderPaymentService@Transactional(value="blTransactionManager") public PaymentTransaction save(PaymentTransaction transaction)
save in interface OrderPaymentServicepublic PaymentLog save(PaymentLog log)
save in interface OrderPaymentServicepublic OrderPayment readPaymentById(Long paymentId)
readPaymentById in interface OrderPaymentServicepublic List<OrderPayment> readPaymentsForOrder(Order order)
readPaymentsForOrder in interface OrderPaymentServicepublic OrderPayment create()
create in interface OrderPaymentService@Transactional(value="blTransactionManager") public void delete(OrderPayment payment)
OrderPaymentServicedelete in interface OrderPaymentServiceOrderPayment#getArchived()}public PaymentLog createLog()
createLog in interface OrderPaymentServicepublic PaymentTransaction createTransaction()
createTransaction in interface OrderPaymentServicepublic PaymentTransaction readTransactionById(Long transactionId)
readTransactionById in interface OrderPaymentService@Transactional(value="blTransactionManager") public OrderPayment createOrderPaymentFromCustomerPayment(Order order, CustomerPayment customerPayment, Money amount)
OrderPaymentService
 Create an OrderPayment with a single
 PaymentTransactionType.UNCONFIRMED
 PaymentTransaction initialized with the
 passed in amount and order.
 
Used typically during the payment flow of checkout, where a customer intends to pay for their order with a saved payment token.
createOrderPaymentFromCustomerPayment in interface OrderPaymentService@Transactional(value="blTransactionManager") public CustomerPayment createCustomerPaymentFromPaymentTransaction(PaymentTransaction transaction)
OrderPaymentService
 Create a CustomerPayment token for the passed in Customer
 given a PaymentTransaction. This assumes that the
 token and any additional request attributes needed to do another transaction for this specific gateway
 has already been persisted to the PaymentTransaction.getAdditionalFields() map.
 Specifically, the PaymentAdditionalFieldType.TOKEN has been set.
 
Used typically during the complete checkout flow when a token needs to be saved from a "confirmed" transaction
createCustomerPaymentFromPaymentTransaction in interface OrderPaymentServicepublic void populateCustomerPaymentToken(CustomerPayment customerPayment, PaymentTransaction transaction)
OrderPaymentService
 Will attempt to populate the CustomerPayment.setPaymentToken(String)
 by looking at the PaymentTransaction.getAdditionalFields()
 for key PaymentAdditionalFieldType.TOKEN.
 
Usually used during a checkout flow when there is a direct response from the gateway (e.g. transparent redirect).
populateCustomerPaymentToken in interface OrderPaymentServiceorg.broadleafcommerce.core.checkout.service.workflow.ValidateAndConfirmPaymentActivity}Copyright © 2020. All rights reserved.