Свойство | Тип | Описание | |
---|---|---|---|
$error | string | ||
$notifier | OrderEmailNotifier | ||
$order | Order |
Метод | Описание | |
---|---|---|
__construct ( Order $order ) | Assign the order to a local variable | |
canPlace ( Order $order ) | Determine if an order can be placed. | |
completePayment ( ) | Complete payment processing - send receipt - update order status accordingling - fire event hooks | |
config ( ) | ||
create ( Order $order ) | Static way to create the order processor. | |
createPayment ( $gateway ) | Create a new payment for an order | |
getError ( ) | ||
getOrder ( ) : Order | ||
getReturnUrl ( ) : String | URL to display success message to the user. | |
makePayment ( string $gateway, array $gatewaydata = [], string $successUrl = null, string $cancelUrl = null ) : SilverStripe\Omnipay\Service\ServiceResponse | null | Create a payment model, and provide link to redirect to external gateway, or redirect to order link. | |
placeOrder ( ) : boolean | Takes an order from being a cart to awaiting payment. |
Метод | Описание | |
---|---|---|
error ( $message ) | ||
getGatewayData ( array $customData ) : array | Map shop data to omnipay fields |
public __construct ( Order $order ) | ||
$order | Order |
public canPlace ( Order $order ) | ||
$order | Order |
public completePayment ( ) |
public static create ( Order $order ) | ||
$order | Order |
protected getGatewayData ( array $customData ) : array | ||
$customData | array | Usually user submitted data. |
Результат | array |
public getReturnUrl ( ) : String | ||
Результат | String | Relative URL |
public makePayment ( string $gateway, array $gatewaydata = [], string $successUrl = null, string $cancelUrl = null ) : SilverStripe\Omnipay\Service\ServiceResponse | null | ||
$gateway | string | the gateway to use |
$gatewaydata | array | the data that should be passed to the gateway |
$successUrl | string | (optional) return URL for successful payments. If left blank, the default return URL will be used @see getReturnUrl |
$cancelUrl | string | (optional) return URL for cancelled/failed payments |
Результат | SilverStripe\Omnipay\Service\ServiceResponse | null |
public placeOrder ( ) : boolean | ||
Результат | boolean | - success/failure |