Aplicación para gestionar el WiFi y punto de luz en puertos.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

185 lines
3.5 KiB

5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. /**
  5. * Facturas
  6. *
  7. * @ORM\Table(name="facturas", indexes={@ORM\Index(name="id_cliente", columns={"id_cliente"})})
  8. * @ORM\Entity
  9. */
  10. class Facturas
  11. {
  12. /**
  13. * @var int
  14. *
  15. * @ORM\Column(name="id", type="integer", nullable=false)
  16. * @ORM\Id
  17. * @ORM\GeneratedValue(strategy="IDENTITY")
  18. */
  19. private $id;
  20. /**
  21. * @var \DateTime
  22. *
  23. * @ORM\Column(name="fecha", type="datetime", nullable=false, options={"default"="CURRENT_TIMESTAMP"})
  24. */
  25. private $fecha;
  26. /**
  27. * @var bool
  28. *
  29. * @ORM\Column(name="estado", type="boolean", nullable=false, options={"comment"="Estado pendiente o pagado."})
  30. */
  31. private $estado = '0';
  32. /**
  33. * @var string
  34. *
  35. * @ORM\Column(name="numerofactura", type="string", length=10, nullable=false)
  36. */
  37. private $numerofactura;
  38. /**
  39. * @var string
  40. *
  41. * @ORM\Column(name="filepdf", type="text", length=65535, nullable=false)
  42. */
  43. private $filepdf;
  44. /**
  45. * @var float
  46. *
  47. * @ORM\Column(name="precio", type="decimal", precision=7, scale=2, nullable=false)
  48. */
  49. private $precio;
  50. /**
  51. * @var float
  52. *
  53. * @ORM\Column(name="impuestos", type="decimal", precision=7, scale=2, nullable=false, options={"comment"="total de los impuestos en euros"})
  54. */
  55. private $impuestos;
  56. /**
  57. * @var float
  58. *
  59. * @ORM\Column(name="total", type="decimal", precision=7, scale=2, nullable=false)
  60. */
  61. private $total;
  62. /**
  63. * @var \Clientes
  64. *
  65. * @ORM\ManyToOne(targetEntity="Clientes")
  66. * @ORM\JoinColumns({
  67. * @ORM\JoinColumn(name="id_cliente", referencedColumnName="id")
  68. * })
  69. */
  70. private $idCliente;
  71. public function getId(): ?int
  72. {
  73. return $this->id;
  74. }
  75. public function getFecha(): ?\DateTimeInterface
  76. {
  77. return $this->fecha;
  78. }
  79. public function setFecha(\DateTimeInterface $fecha): self
  80. {
  81. $this->fecha = $fecha;
  82. return $this;
  83. }
  84. public function getEstado(): ?bool
  85. {
  86. return $this->estado;
  87. }
  88. public function setEstado(bool $estado): self
  89. {
  90. $this->estado = $estado;
  91. return $this;
  92. }
  93. public function getNumerofactura(): ?string
  94. {
  95. return $this->numerofactura;
  96. }
  97. public function setNumerofactura(string $numerofactura): self
  98. {
  99. $this->numerofactura = $numerofactura;
  100. return $this;
  101. }
  102. public function getFilepdf(): ?string
  103. {
  104. return $this->filepdf;
  105. }
  106. public function setFilepdf(string $filepdf): self
  107. {
  108. $this->filepdf = $filepdf;
  109. return $this;
  110. }
  111. public function getPrecio(): ?float
  112. {
  113. return $this->precio;
  114. }
  115. public function setPrecio(float $precio): self
  116. {
  117. $this->precio = $precio;
  118. return $this;
  119. }
  120. public function getImpuestos(): ?float
  121. {
  122. return $this->impuestos;
  123. }
  124. public function setImpuestos(float $impuestos): self
  125. {
  126. $this->impuestos = $impuestos;
  127. return $this;
  128. }
  129. public function getTotal(): ?float
  130. {
  131. return $this->total;
  132. }
  133. public function setTotal(float $total): self
  134. {
  135. $this->total = $total;
  136. return $this;
  137. }
  138. public function getIdCliente(): ?Clientes
  139. {
  140. return $this->idCliente;
  141. }
  142. public function setIdCliente(?Clientes $idCliente): self
  143. {
  144. $this->idCliente = $idCliente;
  145. return $this;
  146. }
  147. }