<?php
namespace App\Entity;
use App\Repository\ShippingCurrencyRepository;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass=ShippingCurrencyRepository::class)
*/
class ShippingCurrency
{
/**
* @ORM\Id
* @ORM\GeneratedValue
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\ManyToOne(targetEntity=Shipping::class, inversedBy="currencies")
* @ORM\JoinColumn(nullable=false)
*/
private $shipping;
/**
* @ORM\ManyToOne(targetEntity=CurrencyChange::class, inversedBy="shippings")
* @ORM\JoinColumn(nullable=false)
*/
private $currency;
/**
* @ORM\Column(type="float")
*/
private $exchangeRate;
public function getId(): ?int
{
return $this->id;
}
public function getShipping(): ?Shipping
{
return $this->shipping;
}
public function setShipping(?Shipping $shipping): self
{
$this->shipping = $shipping;
return $this;
}
public function getCurrency(): ?CurrencyChange
{
return $this->currency;
}
public function setCurrency(?CurrencyChange $currency): self
{
$this->currency = $currency;
return $this;
}
public function getExchangeRate(): ?float
{
return $this->exchangeRate;
}
public function setExchangeRate(float $exchangeRate): self
{
$this->exchangeRate = $exchangeRate;
return $this;
}
}