Package DE_EPAGES::Order::API::Object::LineItemPaymentExternal
contains functions used by external payments
Base |
DE_EPAGES::Order::API::Object::LineItemPayment |
Functions
checkAmount
This functions allows a payment line item to check if the ordered amount differs from the amount defined in the transaction. Overwrite this function for security checks in external payment or checkout methods.
Syntax |
$result = $PaymentLineItem->checkAmount; |
Return |
|
executePayment
This function allows a payment line item to initiate the payment process. Override this function to interrupt the basket processing, for example to display additional pages for collection payment information. The default implementation does nothing. Called by DE_EPAGES::Order::Hooks::Basket::OnBasket2OrderExecutePayment Called by DE_EPAGES::Order::Hooks::Order::OnOrderExecutePayment
Syntax |
$PaymentLineItem->executePayment($hValues); |
Example |
sub executePayment { my $self = shift; my ($hParams)= @_; my $Object = defined $hParams->{'Order'} ? $hParams->{'Order'} : $hParams->{'Basket'}; my $Servlet = $hParams->{'Servlet'}; # display the credit card form $Servlet->vars('ObjectID', $Object->id); Error('INVALID_FORM', { 'ViewVars'=> { 'FormError' => 0, }, 'ViewAction' => 'ViewCreditCardForm', }); return; } |
Input |
|
updateOnExecute
This functions sets amount and currency.
Syntax |
$updateOnExecute($hParams); |
Input |
|