<?php
namespace App\Entity;
use App\Repository\AvocadostoreToShopwareConnectionRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass=AvocadostoreToShopwareConnectionRepository::class)
*/
class AvocadostoreToShopwareConnection
{
/**
* @ORM\Id
* @ORM\GeneratedValue
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\Column(type="integer")
*/
private $shopwareApiVersion;
/**
* @ORM\Column(type="string", length=510)
*/
private $shopwareBaseUrl;
/**
* @ORM\Column(type="string", length=255)
*/
private $shopwareAdminApiUsername;
/**
* @ORM\Column(type="string", length=255)
*/
private $shopwareAdminApiPassword;
/**
* @ORM\Column(type="string", length=1024)
*/
private $shopwareAdminApiAccessToken;
/**
* @ORM\Column(type="string", length=1024)
*/
private $shopwareAdminApiRefreshToken;
/**
* @ORM\Column(type="datetime", nullable=true)
*/
private $shopwareAdminApiExpireTime;
/**
* @ORM\OneToMany(targetEntity=AvocadostoreOrder::class, mappedBy="connection")
*/
private $orders;
/**
* @ORM\Column(type="string", length=255)
*/
private $shopwareSalesChannelId;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $shopwareCustomerId;
/**
* @ORM\Column(type="string", length=255)
*/
private $shopwarePaymentId;
/**
* @ORM\Column(type="string", length=255)
*/
private $shopwareSalesChannelAccessKey;
public function __construct()
{
$this->orders = new ArrayCollection();
}
public function getId(): ?int
{
return $this->id;
}
public function getShopwareApiVersion(): ?int
{
return $this->shopwareApiVersion;
}
public function setShopwareApiVersion(int $shopwareApiVersion): self
{
$this->shopwareApiVersion = $shopwareApiVersion;
return $this;
}
public function getShopwareBaseUrl(): ?string
{
return $this->shopwareBaseUrl;
}
public function setShopwareBaseUrl(string $shopwareBaseUrl): self
{
$this->shopwareBaseUrl = $shopwareBaseUrl;
return $this;
}
public function getShopwareAdminApiUsername(): ?string
{
return $this->shopwareAdminApiUsername;
}
public function setShopwareAdminApiUsername(string $shopwareAdminApiUsername): self
{
$this->shopwareAdminApiUsername = $shopwareAdminApiUsername;
return $this;
}
public function getShopwareAdminApiPassword(): ?string
{
return $this->shopwareAdminApiPassword;
}
public function setShopwareAdminApiPassword(string $shopwareAdminApiPassword): self
{
$this->shopwareAdminApiPassword = $shopwareAdminApiPassword;
return $this;
}
public function getShopwareAdminApiAccessToken(): ?string
{
return $this->shopwareAdminApiAccessToken;
}
public function setShopwareAdminApiAccessToken(string $shopwareAdminApiAccessToken): self
{
$this->shopwareAdminApiAccessToken = $shopwareAdminApiAccessToken;
return $this;
}
public function getShopwareAdminApiRefreshToken(): ?string
{
return $this->shopwareAdminApiRefreshToken;
}
public function setShopwareAdminApiRefreshToken(string $shopwareAdminApiRefreshToken): self
{
$this->shopwareAdminApiRefreshToken = $shopwareAdminApiRefreshToken;
return $this;
}
public function getShopwareAdminApiExpireTime(): ?\DateTimeInterface
{
return $this->shopwareAdminApiExpireTime;
}
public function setShopwareAdminApiExpireTime(?\DateTimeInterface $shopwareAdminApiExpireTime): self
{
$this->shopwareAdminApiExpireTime = $shopwareAdminApiExpireTime;
return $this;
}
/**
* @return Collection|AvocadostoreOrder[]
*/
public function getOrders(): Collection
{
return $this->orders;
}
public function addOrder(AvocadostoreOrder $order): self
{
if (!$this->orders->contains($order)) {
$this->orders[] = $order;
$order->setConnection($this);
}
return $this;
}
public function removeOrder(AvocadostoreOrder $order): self
{
if ($this->orders->contains($order)) {
$this->orders->removeElement($order);
// set the owning side to null (unless already changed)
if ($order->getConnection() === $this) {
$order->setConnection(null);
}
}
return $this;
}
public function getShopwareSalesChannelId(): ?string
{
return $this->shopwareSalesChannelId;
}
public function setShopwareSalesChannelId(string $shopwareSalesChannelId): self
{
$this->shopwareSalesChannelId = $shopwareSalesChannelId;
return $this;
}
public function getShopwareCustomerId(): ?string
{
return $this->shopwareCustomerId;
}
public function setShopwareCustomerId(?string $shopwareCustomerId): self
{
$this->shopwareCustomerId = $shopwareCustomerId;
return $this;
}
public function getShopwarePaymentId(): ?string
{
return $this->shopwarePaymentId;
}
public function setShopwarePaymentId(string $shopwarePaymentId): self
{
$this->shopwarePaymentId = $shopwarePaymentId;
return $this;
}
public function getShopwareSalesChannelAccessKey(): ?string
{
return $this->shopwareSalesChannelAccessKey;
}
public function setShopwareSalesChannelAccessKey(string $shopwareSalesChannelAccessKey): self
{
$this->shopwareSalesChannelAccessKey = $shopwareSalesChannelAccessKey;
return $this;
}
}