You are here

function pay_transaction::set_state in Pay 7

Same name and namespace in other branches
  1. 6 includes/handlers/pay_transaction.inc \pay_transaction::set_state()

Set the state of this transaction.

2 calls to pay_transaction::set_state()
pay_transaction::state in includes/handlers/pay_transaction.inc
Return the current state of this transaction.
pay_transaction::update_status in includes/handlers/pay_transaction.inc

File

includes/handlers/pay_transaction.inc, line 64
A base class for payment transactions.

Class

pay_transaction
@file A base class for payment transactions.

Code

function set_state($state = 'pending') {
  if (array_key_exists($state, $this
    ->states())) {
    $this->state = $state;
  }
}