# ivyforms/1.5.1/backend/src/Entity/Payment/Order.php

The Innovative Form Builder – IvyForms, version 1.5.1. 82 lines.

- Page: https://pluginprobe.com/plugins/ivyforms/1.5.1/code/backend/src/Entity/Payment/Order.php
- Raw: https://pluginprobe.com/plugins/ivyforms/1.5.1/raw/backend/src/Entity/Payment/Order.php
- Modified: 2026-10-05T14:37:20+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/ivyforms/1.5.1/code/backend/src/Entity/Payment/Order.php#L10-L20`.

```php
<?php

namespace IvyForms\Entity\Payment;

use IvyForms\ValueObjects\Payment\Order as OrderValueObject;

/**
 * Order entity wrapping the value object.
 */
class Order
{
    private OrderValueObject $order;

    public function __construct(OrderValueObject $order)
    {
        $this->order = $order;
    }

    public function getId(): int
    {
        return $this->order->id;
    }

    public function setId(int $id): void
    {
        $this->order->id = $id;
    }

    public function getEntryId(): int
    {
        return $this->order->entryId;
    }

    public function getSquareOrderId(): string
    {
        return $this->order->squareOrderId;
    }

    public function getStatus(): string
    {
        return $this->order->status;
    }

    public function setStatus(string $status): void
    {
        $this->order->status = $status;
    }

    public function getSquareCustomerId(): ?string
    {
        return $this->order->squareCustomerId;
    }

    public function getAmount(): int
    {
        return $this->order->amount;
    }

    public function getCurrency(): string
    {
        return $this->order->currency;
    }

    public function getDateCreated(): ?string
    {
        return $this->order->dateCreated;
    }

    public function setDateCreated(string $dateCreated): void
    {
        $this->order->dateCreated = $dateCreated;
    }

    /**
     * @return mixed[]
     */
    public function toArray(): array
    {
        return $this->order->toArray();
    }
}

```
