returns true if the payment transaction was successful

@return boolean result of payment
3888
public function paymentSuccessful() {
    if ($this->requestHasSucceeded() && $this->requestMethod->isDirectPayment()) {
      return $this->requestMethod->getTransactionSuccessfulCode() == $this->response['resultPayment'];
    }

    return false;
  }
1017213
public function getTransaction() {

		$transactionTable	= PaymentTables::getTableName( PaymentTables::TABLE_TRANSACTION );
		$transactionSuccess = Transaction::STATUS_SUCCESS;

		return $this->hasOne( Transaction::class, [ 'orderId' => 'id' ] )->where( "$transactionTable.status=$transactionSuccess" );
	}
122778
public function isValid()
    {
        if(empty($this->returnUrl) || empty($this->cancelUrl)) {
            return false;
        }

        $valid = true;
        foreach($this->_paymentDetails as $detail) {
            if(empty($detail)) {
                $valid = false;
                break;
            }

            $amt = $detail->getAmt();

            if(empty($amt)) {
                $valid = false;
                break;
            }
        }

        return $valid;
    }
91737
public function isValid()
    {
        if(empty($this->token) || empty($this->payerId) || is_null($this->_paymentDetails)) {
            return false;
        }

        $valid = true;
        foreach($this->_paymentDetails as $detail) {
            if(empty($detail)) {
                $valid = false;
                break;
            }

            $amt = $detail->getAmt();

            if(empty($amt)) {
                $valid = false;
                break;
            }
        }

        return $valid;
    }
873182
protected function verifyPayment()
	{
		try {
			$soap = new SoapClient($this->serverUrl);

			$result = $soap->CheckRequestStatusResult(
				$this->transactionId(),
				$this->config->get('gateway.sadad.merchant'),
				$this->config->get('gateway.sadad.terminalId'),
				$this->config->get('gateway.sadad.transactionKey'),
				$this->refId(),
				$this->amount
			);

		} catch (\SoapFault $e) {
			$this->transactionFailed();
			$this->newLog('SoapFault', $e->getMessage());
			throw $e;
		}

		if (empty($result) || !isset($result->AppStatusCode))
			throw new SadadException('در دریافت اطلاعات از بانک خطایی رخ داده است.');

		$statusResult = strval($result->AppStatusCode);
		$appStatus = strtolower($result->AppStatusDescription);

		$message = $this->getMessage($statusResult, $appStatus);

		$this->newLog($statusResult, $message['fa']);

		if ($statusResult != 0 || $appStatus !== 'commit') {
			$this->transactionFailed();
			throw new SadadException($message['fa'], $statusResult);
		}
		$this->trackingCode = $result->TraceNo;
		$this->cardNumber = $result->CustomerCardNumber;
		$this->transactionSucceed();
	}
204151
protected function getOrderPaymentStatusFinal()
    {
        $status = null;
        if ($this->isOrderPaymentStatusFinal()) {
            $status = $this->getOrder()->getPaymentStatus();
        }

        return $status;
    }
1228396
public function getPaymentStatus()
    {
        if (isset($this->data->ewallet->status)) {
            return (string)$this->data->ewallet->status;
        }
    }
1047632
public function rollBackTransaction(): bool
	{
		if($this->transactionNestingLevel > 0)
		{
			if($this->transactionNestingLevel > 1)
			{
				$success = $this->rollBackSavepoint();
			}
			else
			{
				$success =  $this->pdo->rollBack();
			}

			$this->transactionNestingLevel--;

			return $success;
		}

		return false;
	}
1229491
public function doneAnything()
    {
        $output = false;
        foreach( $this->status as $transaction => $transactionStatus ) {
            foreach( $transactionStatus as $status ) {
                $output = ( $output || $status === self::SUCCESS );
            }
        }
        return $output;
    }
319834
public function isSuccess( $transaction = RecordManager::TRANSACTIONS_ALL )
    {
        $output = true;
        foreach( $this->getStatus($transaction) as $transaction => $transactionStatus ) {
            foreach( $transactionStatus as $status ) {
                $output = ( $output && $status === self::SUCCESS );
            }
        }
        return $output;
    }
178213
public function isPaid()
    {
        $response = array_get($this->data, 'response');
        if ($response) {
            $trade = array_get($response, 'trade');
            if (array_get($trade, 'trade_status')) {
                if (array_get($trade, 'trade_status') == 'TRADE_SUCCESS') {
                    return true;
                } elseif (array_get($trade, 'trade_status') == 'TRADE_FINISHED') {
                    return true;
                } else {
                    return false;
                }
            } else {
                return false;
            }
        } else {
            return false;
        }
    }
67708
protected function validatePaymentOrder()
    {
        $field = 'payment';

        if ($this->isExcluded($field)) {
            return null;
        }

        $value = $this->getSubmitted($field);

        if ($this->isUpdating() && !isset($value)) {
            $this->unsetSubmitted($field);
            return null;
        }

        $label = $this->translation->text('Payment');

        if (empty($value)) {
            $this->setErrorRequired($field, $label);
            return false;
        }

        $method = $this->payment->get($value);

        if (empty($method['status'])) {
            $this->setErrorUnavailable($field, $label);
            return false;
        }

        return true;
    }
979400
public function beginTransaction(): bool
    {
        if(!$this->inTransaction())
        {
            $generator = $this->__beginTransaction();
            if(!$generator->valid())
            {
                return $generator->getReturn();
            }
            $current = $generator->current();
            $generator->next();
            $generator->send($current);
            $result = $generator->getReturn();
            if(!$result)
            {
                return $result;
            }
        }
        $this->exec('SAVEPOINT P' . $this->getTransactionLevels());
        $this->__tBeginTransaction();
        return true;
    }
393808
protected function isShortcutPayment()
    {
        $trigger = (int) \OxidEsales\Eshop\Core\Registry::getSession()->getVariable(self::OEPAYPAL_TRIGGER_NAME);
        return (bool) ($trigger == self::OEPAYPAL_SHORTCUT);
    }
1174947
protected function verifyPayment()
	{

		$fields = array(
			'MerchantID' => $this->config->get('gateway.zarinpal.merchant-id'),
			'Authority' => $this->refId,
			'Amount' => $this->amount,
		);

		try {
			$soap = new SoapClient($this->serverUrl, ['encoding' => 'UTF-8']);
			$response = $soap->PaymentVerification($fields);

		} catch (\SoapFault $e) {
			$this->transactionFailed();
			$this->newLog('SoapFault', $e->getMessage());
			throw $e;
		}

		if ($response->Status != 100 && $response->Status != 101) {
			$this->transactionFailed();
			$this->newLog($response->Status, ZarinpalException::$errors[$response->Status]);
			throw new ZarinpalException($response->Status);
		}

		$this->trackingCode = $response->RefID;
		$this->transactionSucceed();
		$this->newLog($response->Status, Enum::TRANSACTION_SUCCEED_TEXT);
		return true;
	}
1045538
public function isSuccessful(): bool
    {
        $failures = $this->getTotalFailures();
        $errors = $this->getTotalErrors();

        return $failures === 0 && $errors === 0;
    }
930731
public function isValid()
    {
        $requestPayment = $this->getRequestOrderPayment();
        $orderPayment = $this->getOrderPayment();

        $currencyPayPal = $requestPayment->getCurrency();
        $pricePayPal = $requestPayment->getAmount();

        $currencyPayment = $orderPayment->getCurrency();
        $amountPayment = $orderPayment->getAmount();

        return ($currencyPayPal == $currencyPayment && $pricePayPal == $amountPayment);
    }