saveTransactionId($this->getPrimaryKey()); return $this; } /** * Save transaction id to session * * @param int $id * @return App_ECommerce_Checkout_Abstract_Obj */ public function saveTransactionId($id) { $session = new Qs_Session_Namespace(self::TRANSACTION_NAMESPACE); $session->setExpirationHops(1); $session->id = $id; return $this; } /** * Return and remove transaction id from session * * @return int */ public function getTransactionId() { $session = new Qs_Session_Namespace(self::TRANSACTION_NAMESPACE); return $session->id; } /** * Cancel transaction and remove transaction data * * @return App_ECommerce_Checkout_Abstract_Obj */ public function cancelTransaction() { if (null !== ($id = $this->getTransactionId())) { $this->setPrimaryKey($id); $this->delete(); } return $this; } }