Spamworldpro Mini Shell
Spamworldpro


Server : Apache
System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64
User : corals ( 1002)
PHP Version : 7.4.33
Disable Function : exec,passthru,shell_exec,system
Directory :  /home/corals/job-board.corals.io/Corals/modules/Payment/Omise/Message/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/corals/job-board.corals.io/Corals/modules/Payment/Omise/Message/CompletePurchaseResponse.php
<?php

namespace Corals\Modules\Payment\Omise\Message;

use Corals\Modules\Payment\Common\Message\AbstractResponse;

/**
 * Omise Complete Purchase Response.
 */
class CompletePurchaseResponse extends AbstractResponse
{
    public function isSuccessful()
    {
        if ($this->data['status']) {
            return true;
        } else {
            return false;

        }
    }

    /**
     * @return array|null
     *@see \Corals\Modules\Payment\Omise\Message\Response::getTransactionReference()
     */
    public function getChargeReference()
    {
        if (isset($this->data['object']) && $this->data['object'] == 'charge') {
            return $this->data['id'];
        }

        return null;
    }

    /**
     * Transaction reference returned by omise or null on payment failure.
     *
     * @return mixed|null
     */
    public function getTransactionReference()
    {
        return isset($this->data['order_number']) ? $this->data['order_number'] : null;
    }

    public function getTransactionInvoice()
    {
        return isset($this->data['invoice_id']) ? $this->data['invoice_id'] : null;
    }

    /**
     * Transaction ID.
     *
     * @return mixed|null
     */
    public function getTransactionId()
    {
        return isset($this->data['merchant_order_id']) ? $this->data['merchant_order_id'] : null;
    }
}

Spamworldpro Mini