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/SecurionPay/Message/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

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

/**
 * SecurionPay Pay Order Request.
 */

namespace Corals\Modules\Payment\SecurionPay\Message;

/**
 * SecurionPay Pay Order Request
 *
 * @see Corals\Modules\Payment\SecurionPay\Gateway
 * @link https://securionpay.com/docs/api#pay_order
 */
class PayOrderRequest extends AbstractRequest
{

    /**
     * Set the order id
     *
     * @return PayProductRequest provides a fluent interface.
     */
    public function setId($id)
    {
        return $this->setParameter('id', $id);
    }

    /**
     * Get the order id
     *
     * @return string
     */
    public function getId()
    {
        return $this->getParameter('id');
    }

    /**
     * Set the order customer
     *
     * @return PayProductRequest provides a fluent interface.
     */
    public function setCustomer($customer)
    {
        return $this->setParameter('customer', $customer);
    }

    /**
     * Get the order Customer
     *
     * @return string
     */
    public function getCustomer()
    {
        return $this->getParameter('customer');
    }


    /**
     * Get the order source
     *
     * @return array
     */
    public function getSource()
    {
        return $this->getParameter('source');
    }


    /**
     * Set the order source value
     *
     * @return PayOrderRequest provides a fluent interface.
     */
    public function setSource($source)
    {
        return $this->setParameter('source', $source);
    }

    /**
     * Get the order status
     *
     * @return array
     */
    public function getEmail()
    {
        return $this->getParameter('email');
    }


    /**
     * Set the order email value
     *
     * @return PayOrderRequest provides a fluent interface.
     */
    public function setEmail($email)
    {
        return $this->setParameter('email', $email);
    }


    /**
     * @return array|mixed
     * @throws \Corals\Modules\Payment\Common\Exception\InvalidRequestException
     */
    public function getData()
    {
        $data = [];
        $customer = $this->getCustomer();
        if ($customer != null) {
            $data['customer'] = $customer;
        }
        $source = $this->getSource();
        if ($source != null) {
            $data['source'] = $source;
        }
        $email = $this->getEmail();
        if ($email != null) {
            $data['email'] = $email;
        }

        return $data;
    }

    public function getEndpoint()
    {
        return $this->endpoint . '/orders/' . $this->getId() . '/pay';
    }
}

Spamworldpro Mini