\apex\transaction\interfacesTxInterface

interface for individual transaction, the /transaction/tx.php class.

Summary

Methods
Constants
set_user()
set_account()
set_amount()
set_from_amount()
set_fee()
set_controller()
set_payment_method()
set_status()
set_reference_id()
No constants found
No protected methods found
N/A
No private methods found
N/A

Methods

set_user()

set_user(integer  $userid,\apex\users\user  $user = null)

Set the user

Parameters

integer $userid

The ID# of the user.

\apex\users\user $user

The UserInterface object of the loaded user.

set_account()

set_account(integer  $account_id,\apex\transaction\tx_account  $account = null)

Set the transaction account.

Parameters

integer $account_id

The id# of the transaction account.

\apex\transaction\tx_account $account

The transaction account object.

set_amount()

set_amount(float  $amount,string  $currency = '')

Set amount

Parameters

float $amount

The amount of the transaction.

string $currency

The currency of the transaction. If undefined, user's the base currency in settings.

set_from_amount()

set_from_amount(float  $amount,string  $currency = '')

Set the from amount / currency. Used in cases of currency conversion.

Parameters

float $amount

The from amount of the transaction.

string $currency

The from currency. If undefined, defaults to the base currency from settings.

set_fee()

set_fee(float  $fee,\apex\transaction\interfaces\float  $fee_percent = 0.0)

Set fee.

Parameters

float $fee

The amount amount if dollars.

\apex\transaction\interfaces\float $fee_percent

set_controller()

set_controller(string  $controller_alias,integer  $index_id)

Set controller and index id

Parameters

string $controller_alias

The alias of the transaction controller.

integer $index_id

Optional index_id to help identify the transaction.

set_payment_method()

set_payment_method(integer  $payment_id,\apex\transaction\payment_method  $payment_method = null)

Set payment method.

Parameters

integer $payment_id

The id# of the payment method.

\apex\transaction\payment_method $payment_method

The payment_method object, loaded.

set_status()

set_status(string  $status)

Set status of transaction

Parameters

string $status

The status of the transaction.

set_reference_id()

set_reference_id(integer  $reference_id)

Set reference ID

Parameters

integer $reference_id

The reference ID# of the transaction.