public static function ProcessSalesTX($invoicetx) { //if busy - add to queue, if ready - add to currentTransaction then prepare and commit if ($invoicetx->commit()) { return Voucher::CreateSalesTxVoucher($invoicetx); } else { Logger::Log('TransactionProcessor', 'Failed', $invoicetx->txtype->name . ' transaction with id:' . $invoicetx->invoice->id . ' and tx id:' . $invoicetx->transactionId . ' could not be commited'); return false; } }