Guest User

Untitled

a guest
Nov 12th, 2018
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 20.76 KB | None | 0 0
  1. SELECT *
  2. FROM beneficiobbva.imagenes im
  3. LEFT JOIN beneficiobbva.imagenes_x_exppromociones impro
  4. ON im.id=impro.id_imagen
  5. where impro.id_imagen is null;
  6.  
  7. select *
  8. from beneficiobbva.imagenes a
  9. where a.id
  10. NOT IN (
  11. SELECT id_imagen
  12. FROM beneficiobbva.imagenes_x_exppromociones
  13. );
  14.  
  15. $imagenes = $em->createQueryBuilder()
  16. ->select('img')
  17. ->addSelect('img_pro')
  18. ->from('beneficiobbva.imagenes', 'img')
  19. ->leftjoin('beneficiobbva.imagenes_x_exppromociones', 'img_pro', 'WITH', 'img.id=img_pro.imagenes')
  20. ->where('img_pro.imagenes is null')
  21. ->getQuery()
  22. ->getResult();
  23.  
  24. <?php
  25.  
  26. namespace ROSHKABBVASitioExperienceFrontendBundleEntity;
  27.  
  28. use DoctrineORMMapping as ORM;
  29.  
  30. /**
  31. * Exppromociones
  32. */
  33. class Exppromociones
  34. {
  35. /**
  36. * @var integer
  37. */
  38. private $id;
  39.  
  40. /**
  41. * @var string
  42. */
  43. private $nombre;
  44.  
  45. /**
  46. * @var string
  47. */
  48. private $descripcion;
  49.  
  50. /**
  51. * @var integer
  52. */
  53. private $puntos;
  54.  
  55. /**
  56. * @var DateTime
  57. */
  58. private $fechaInicio;
  59.  
  60. /**
  61. * @var DateTime
  62. */
  63. private $fechaFin;
  64.  
  65. /**
  66. * @var boolean
  67. */
  68. private $enPromocion;
  69.  
  70. /**
  71. * @var string
  72. */
  73. private $vigenciaDescripcion;
  74.  
  75. /**
  76. * @var string
  77. */
  78. private $miniDescripcion;
  79.  
  80. /**
  81. * @var integer
  82. */
  83. private $puntosOtros;
  84.  
  85. /**
  86. * @var string
  87. */
  88. private $flujoCanje;
  89.  
  90. /**
  91. * @var ROSHKABBVASitioExperienceFrontendBundleEntityExpCategorias
  92. */
  93. private $categoria;
  94.  
  95. /**
  96. * @var ROSHKABBVASitioUniversosImagenesBundleEntityImagenes
  97. */
  98. private $banner;
  99.  
  100. /**
  101. * @var ROSHKABBVASitioUniversosImagenesBundleEntityImagenes
  102. */
  103. private $imagen;
  104.  
  105. /**
  106. * @var ROSHKABBVASitioExperienceFrontendBundleEntityexpcomercios
  107. */
  108. private $comercio;
  109.  
  110. /**
  111. * @var string
  112. *
  113. * @ORMColumn(name="Nombre_Real", type="text")
  114. */
  115. private $nombreReal;
  116.  
  117. /**
  118. * @var string
  119. *
  120. * @ORMColumn(name="Descripcion_Experience", type="text")
  121. */
  122. private $descripcionExperience;
  123.  
  124. /**
  125. * @var boolean
  126. */
  127. private $destacado = false;
  128.  
  129. /**
  130. * @var DoctrineCommonCollectionsCollection
  131. */
  132. private $imagenes;
  133.  
  134. /**
  135. * @var DoctrineCommonCollectionsCollection
  136. */
  137. private $categorias;
  138.  
  139. /**
  140. * @var DoctrineCommonCollectionsCollection
  141. */
  142. private $etiquetas;
  143.  
  144. /**
  145. * @var DateTime
  146. */
  147. private $fechaFinNovedad;
  148.  
  149. /**
  150. * @var integer
  151. */
  152. private $cantidadVista = 0;
  153.  
  154. /**
  155. * @var integer
  156. */
  157. private $cantidadCanjeada = 0;
  158.  
  159. /**
  160. * @var integer
  161. */
  162. private $valorGuaranies = 0;
  163.  
  164. /**
  165. * @var integer
  166. */
  167. private $puntosTelefonico;
  168.  
  169. /**
  170. * @var string
  171. */
  172. private $texto_circulo;
  173.  
  174. /**
  175. * @var boolean
  176. */
  177. private $mostrarValorGuaranies;
  178.  
  179.  
  180. /**
  181. * Get id
  182. *
  183. * @return integer
  184. */
  185. public function getId()
  186. {
  187. return $this->id;
  188. }
  189.  
  190. /**
  191. * Set nombre
  192. *
  193. * @param string $nombre
  194. * @return Exppromociones
  195. */
  196. public function setNombre($nombre)
  197. {
  198. $this->nombre = $nombre;
  199.  
  200. return $this;
  201. }
  202.  
  203. /**
  204. * Get nombre
  205. *
  206. * @return string
  207. */
  208. public function getNombre()
  209. {
  210. return $this->nombre;
  211. }
  212.  
  213. /**
  214. * Set descripcion
  215. *
  216. * @param string $descripcion
  217. * @return Exppromociones
  218. */
  219. public function setDescripcion($descripcion)
  220. {
  221. $this->descripcion = $descripcion;
  222.  
  223. return $this;
  224. }
  225.  
  226. /**
  227. * Get descripcion
  228. *
  229. * @return string
  230. */
  231. public function getDescripcion()
  232. {
  233. return $this->descripcion;
  234. }
  235.  
  236. /**
  237. * Set puntos
  238. *
  239. * @param integer $puntos
  240. * @return Exppromociones
  241. */
  242. public function setPuntos($puntos)
  243. {
  244. $this->puntos = $puntos;
  245.  
  246. return $this;
  247. }
  248.  
  249. /**
  250. * Get puntos
  251. *
  252. * @return integer
  253. */
  254. public function getPuntos()
  255. {
  256. return $this->puntos;
  257. }
  258.  
  259. /**
  260. * Set fechaInicio
  261. *
  262. * @param DateTime $fechaInicio
  263. * @return Exppromociones
  264. */
  265. public function setFechaInicio($fechaInicio)
  266. {
  267. $this->fechaInicio = $fechaInicio;
  268.  
  269. return $this;
  270. }
  271.  
  272. /**
  273. * Get fechaInicio
  274. *
  275. * @return DateTime
  276. */
  277. public function getFechaInicio()
  278. {
  279. return $this->fechaInicio;
  280. }
  281.  
  282. /**
  283. * Set fechaFin
  284. *
  285. * @param DateTime $fechaFin
  286. * @return Exppromociones
  287. */
  288. public function setFechaFin($fechaFin)
  289. {
  290. $this->fechaFin = $fechaFin;
  291.  
  292. return $this;
  293. }
  294.  
  295. /**
  296. * Get fechaFin
  297. *
  298. * @return DateTime
  299. */
  300. public function getFechaFin()
  301. {
  302. return $this->fechaFin;
  303. }
  304.  
  305. /**
  306. * Set enPromocion
  307. *
  308. * @param boolean $enPromocion
  309. * @return Exppromociones
  310. */
  311. public function setEnPromocion($enPromocion)
  312. {
  313. $this->enPromocion = $enPromocion;
  314.  
  315. return $this;
  316. }
  317.  
  318. /**
  319. * Get enPromocion
  320. *
  321. * @return boolean
  322. */
  323. public function getEnPromocion()
  324. {
  325. return $this->enPromocion;
  326. }
  327.  
  328. /**
  329. * Set vigenciaDescripcion
  330. *
  331. * @param string $vigenciaDescripcion
  332. * @return Exppromociones
  333. */
  334. public function setVigenciaDescripcion($vigenciaDescripcion)
  335. {
  336. $this->vigenciaDescripcion = $vigenciaDescripcion;
  337.  
  338. return $this;
  339. }
  340.  
  341. /**
  342. * Get vigenciaDescripcion
  343. *
  344. * @return string
  345. */
  346. public function getVigenciaDescripcion()
  347. {
  348. return $this->vigenciaDescripcion;
  349. }
  350.  
  351. /**
  352. * Set miniDescripcion
  353. *
  354. * @param string $miniDescripcion
  355. * @return Exppromociones
  356. */
  357. public function setMiniDescripcion($miniDescripcion)
  358. {
  359. $this->miniDescripcion = $miniDescripcion;
  360.  
  361. return $this;
  362. }
  363.  
  364. /**
  365. * Get miniDescripcion
  366. *
  367. * @return string
  368. */
  369. public function getMiniDescripcion()
  370. {
  371. return $this->miniDescripcion;
  372. }
  373.  
  374. /**
  375. * Set puntosOtros
  376. *
  377. * @param integer $puntosOtros
  378. * @return Exppromociones
  379. */
  380. public function setPuntosOtros($puntosOtros)
  381. {
  382. $this->puntosOtros = $puntosOtros;
  383.  
  384. return $this;
  385. }
  386.  
  387. /**
  388. * Get puntosOtros
  389. *
  390. * @return integer
  391. */
  392. public function getPuntosOtros()
  393. {
  394. return $this->puntosOtros;
  395. }
  396.  
  397. /**
  398. * Set flujoCanje
  399. *
  400. * @param string $flujoCanje
  401. * @return Exppromociones
  402. */
  403. public function setFlujoCanje($flujoCanje)
  404. {
  405. $this->flujoCanje = $flujoCanje;
  406.  
  407. return $this;
  408. }
  409.  
  410. /**
  411. * Get flujoCanje
  412. *
  413. * @return string
  414. */
  415. public function getFlujoCanje()
  416. {
  417. return $this->flujoCanje;
  418. }
  419.  
  420. /**
  421. * Set categoria
  422. *
  423. * @param ROSHKABBVASitioExperienceFrontendBundleEntityExpCategorias $categoria
  424. * @return Exppromociones
  425. */
  426. public function setCategoria(ROSHKABBVASitioExperienceFrontendBundleEntityExpCategorias $categoria = null)
  427. {
  428. $this->categoria = $categoria;
  429.  
  430. return $this;
  431. }
  432.  
  433. /**
  434. * Get categoria
  435. *
  436. * @return ROSHKABBVASitioExperienceFrontendBundleEntityExpCategorias
  437. */
  438. public function getCategoria()
  439. {
  440. return $this->categoria;
  441. }
  442.  
  443. /**
  444. * Set banner
  445. *
  446. * @param ROSHKABBVASitioUniversosImagenesBundleEntityImagenes $banner
  447. * @return Exppromociones
  448. */
  449. public function setBanner(ROSHKABBVASitioUniversosImagenesBundleEntityImagenes $banner = null)
  450. {
  451. $this->banner = $banner;
  452.  
  453. return $this;
  454. }
  455.  
  456. /**
  457. * Get banner
  458. *
  459. * @return ROSHKABBVASitioUniversosImagenesBundleEntityImagenes
  460. */
  461. public function getBanner()
  462. {
  463. return $this->banner;
  464. }
  465.  
  466. /**
  467. * Set imagen
  468. *
  469. * @param ROSHKABBVASitioUniversosImagenesBundleEntityImagenes $imagen
  470. * @return Exppromociones
  471. */
  472. public function setImagen(ROSHKABBVASitioUniversosImagenesBundleEntityImagenes $imagen = null)
  473. {
  474. $this->imagen = $imagen;
  475.  
  476. return $this;
  477. }
  478.  
  479. /**
  480. * Get imagen
  481. *
  482. * @return ROSHKABBVASitioUniversosImagenesBundleEntityImagenes
  483. */
  484. public function getImagen()
  485. {
  486. return $this->imagen;
  487. }
  488.  
  489. /**
  490. * Set comercio
  491. *
  492. * @param ROSHKABBVASitioExperienceFrontendBundleEntityexpcomercios $comercio
  493. * @return Exppromociones
  494. */
  495. public function setComercio(ROSHKABBVASitioExperienceFrontendBundleEntityexpcomercios $comercio = null)
  496. {
  497. $this->comercio = $comercio;
  498.  
  499. return $this;
  500. }
  501.  
  502. /**
  503. * Get comercio
  504. *
  505. * @return ROSHKABBVASitioExperienceFrontendBundleEntityexpcomercios
  506. */
  507. public function getComercio()
  508. {
  509. return $this->comercio;
  510. }
  511.  
  512. /**
  513. * Set nombreReal
  514. *
  515. * @param string $nombreReal
  516. * @return ExpPromociones
  517. */
  518. public function setNombreReal($nombreReal)
  519. {
  520. $this->nombreReal = $nombreReal;
  521.  
  522. return $this;
  523. }
  524.  
  525. /**
  526. * Get nombreReal
  527. *
  528. * @return string
  529. */
  530. public function getNombreReal()
  531. {
  532. return $this->nombreReal;
  533. }
  534.  
  535. /**
  536. * Set descripcionExperience
  537. *
  538. * @param string $descripcionExperience
  539. * @return ExpPromociones
  540. */
  541. public function setDescripcionExperience($descripcionExperience)
  542. {
  543. $this->descripcionExperience = $descripcionExperience;
  544.  
  545. return $this;
  546. }
  547.  
  548. /**
  549. * Get descripcionExperience
  550. *
  551. * @return string
  552. */
  553. public function getDescripcionExperience()
  554. {
  555. return $this->descripcionExperience;
  556. }
  557. /**
  558. * @var integer
  559. */
  560. private $orden = 0;
  561.  
  562.  
  563. /**
  564. * Set orden
  565. *
  566. * @param integer $orden
  567. * @return Exppromociones
  568. */
  569. public function setOrden($orden)
  570. {
  571. $this->orden = $orden;
  572.  
  573. return $this;
  574. }
  575.  
  576. /**
  577. * Get orden
  578. *
  579. * @return integer
  580. */
  581. public function getOrden()
  582. {
  583. return $this->orden;
  584. }
  585.  
  586. /**
  587. * Determina si la promoción es un viaje genérico,
  588. * según las condición:
  589. * - $flujoCanje de la instancia debe ser igual al string 'generico', y
  590. * - Id de la categoría asociada debe ser igual a 2 (Viajes)
  591. *
  592. * "Opción Genérico": Es una promoción canjeable de tipo Viaje,
  593. * en la que el usuario puede determinar cuántos puntos utilizar.
  594. *
  595. * @return boolean
  596. */
  597. public function esOpcionGenerica()
  598. {
  599. $categorias = $this->getCategorias();
  600. $flujoCanje = $this->getFlujoCanje();
  601. $esViaje=false;
  602. foreach($categorias as $categoria){
  603. if($categoria->getId() == 2){
  604. $esViaje = true;
  605. break;
  606. }
  607. }
  608. // Comparar cadenas.
  609. // "strcasecmp: Binary safe case-insensitive string comparison".
  610. // retorna 0 si las cadenas son iguales, ignorando mayusculas.
  611. $esGenerico = strcasecmp($flujoCanje, 'generico') == 0;
  612.  
  613. return $esViaje && $esGenerico;
  614.  
  615. }
  616.  
  617. /**
  618. * Determina si la promoción es un viaje
  619. * según las condición:
  620. * - Id de la categoría asociada debe ser igual a 2 (Viajes)
  621. *
  622. * @return boolean
  623. */
  624. public function esViaje()
  625. {
  626. $categorias = $this->getCategorias();
  627. $esViaje=false;
  628. foreach($categorias as $categoria){
  629. if($categoria->getId() == 2){
  630. $esViaje = true;
  631. break;
  632. }
  633. }
  634.  
  635. return $esViaje;
  636.  
  637. }
  638.  
  639. /**
  640. * Constructor
  641. */
  642. public function __construct()
  643. {
  644. $this->imagenes = new DoctrineCommonCollectionsArrayCollection();
  645. $this->categorias = new DoctrineCommonCollectionsArrayCollection();
  646. $this->etiquetas = new DoctrineCommonCollectionsArrayCollection();
  647. }
  648.  
  649. /**
  650. * Get imagenes
  651. *
  652. * @return DoctrineCommonCollectionsCollection
  653. */
  654. public function getImagenes()
  655. {
  656. return $this->imagenes;
  657. }
  658.  
  659. /**
  660. * Set destacado
  661. *
  662. * @param boolean $destacado
  663. * @return Exppromociones
  664. */
  665. public function setDestacado($destacado)
  666. {
  667. $this->destacado = $destacado;
  668.  
  669. return $this;
  670. }
  671.  
  672. /**
  673. * Get destacado
  674. *
  675. * @return boolean
  676. */
  677. public function getDestacado()
  678. {
  679. return $this->destacado;
  680. }
  681.  
  682. /**
  683. * Add categorias
  684. *
  685. * @param ROSHKABBVASitioExperienceFrontendBundleEntityExpcategorias $categorias
  686. * @return Exppromociones
  687. */
  688. public function addCategoria(ROSHKABBVASitioExperienceFrontendBundleEntityExpcategorias $categorias)
  689. {
  690. $this->categorias[] = $categorias;
  691.  
  692. return $this;
  693. }
  694.  
  695. /**
  696. * Remove categorias
  697. *
  698. * @param ROSHKABBVASitioExperienceFrontendBundleEntityExpcategorias $categorias
  699. */
  700. public function removeCategoria(ROSHKABBVASitioExperienceFrontendBundleEntityExpcategorias $categorias)
  701. {
  702. $this->categorias->removeElement($categorias);
  703. }
  704.  
  705. /**
  706. * Get categorias
  707. *
  708. * @return DoctrineCommonCollectionsCollection
  709. */
  710. public function getCategorias()
  711. {
  712. return $this->categorias;
  713. }
  714.  
  715.  
  716. /**
  717. * Add imagenes
  718. *
  719. * @param ROSHKABBVASitioUniversosImagenesBundleEntityImagenes $imagenes
  720. * @return Exppromociones
  721. */
  722. public function addImagene(ROSHKABBVASitioUniversosImagenesBundleEntityImagenes $imagenes)
  723. {
  724. $this->imagenes[] = $imagenes;
  725.  
  726. return $this;
  727. }
  728.  
  729. /**
  730. * Remove imagenes
  731. *
  732. * @param ROSHKABBVASitioUniversosImagenesBundleEntityImagenes $imagenes
  733. */
  734. public function removeImagene(ROSHKABBVASitioUniversosImagenesBundleEntityImagenes $imagenes)
  735. {
  736. $this->imagenes->removeElement($imagenes);
  737. }
  738.  
  739. /**
  740. * Add etiquetas
  741. *
  742. * @param ROSHKABBVASitioExperienceFrontendBundleEntityExpetiquetas $etiquetas
  743. * @return Exppromociones
  744. */
  745. public function addEtiqueta(ROSHKABBVASitioExperienceFrontendBundleEntityExpetiquetas $etiquetas)
  746. {
  747. $this->etiquetas[] = $etiquetas;
  748.  
  749. return $this;
  750. }
  751.  
  752. /**
  753. * Remove etiquetas
  754. *
  755. * @param ROSHKABBVASitioExperienceFrontendBundleEntityExpetiquetas $etiquetas
  756. */
  757. public function removeEtiqueta(ROSHKABBVASitioExperienceFrontendBundleEntityExpetiquetas $etiquetas)
  758. {
  759. $this->etiquetas->removeElement($etiquetas);
  760. }
  761.  
  762. /**
  763. * Get etiquetas
  764. *
  765. * @return DoctrineCommonCollectionsCollection
  766. */
  767. public function getEtiquetas()
  768. {
  769. return $this->etiquetas;
  770. }
  771.  
  772. /**
  773. * Set fechaFinNovedad
  774. *
  775. * @param DateTime $fechaFinNovedad
  776. * @return Exppromociones
  777. */
  778. public function setFechaFinNovedad($fechaFinNovedad)
  779. {
  780. $this->fechaFinNovedad = $fechaFinNovedad;
  781.  
  782. return $this;
  783. }
  784.  
  785. /**
  786. * Get fechaFinNovedad
  787. *
  788. * @return DateTime
  789. */
  790. public function getFechaFinNovedad()
  791. {
  792. return $this->fechaFinNovedad;
  793. }
  794.  
  795. /**
  796. * Set cantidadVista
  797. *
  798. * @param integer $cantidadVista
  799. * @return Exppromociones
  800. */
  801. public function setCantidadVista($cantidadVista)
  802. {
  803. $this->cantidadVista = $cantidadVista;
  804.  
  805. return $this;
  806. }
  807.  
  808. /**
  809. * Get cantidadVista
  810. *
  811. * @return integer
  812. */
  813. public function getCantidadVista()
  814. {
  815. return $this->cantidadVista;
  816. }
  817.  
  818. /**
  819. * Set cantidadCanjeada
  820. *
  821. * @param integer $cantidadCanjeada
  822. * @return Exppromociones
  823. */
  824. public function setCantidadCanjeada($cantidadCanjeada)
  825. {
  826. $this->cantidadCanjeada = $cantidadCanjeada;
  827.  
  828. return $this;
  829. }
  830.  
  831. /**
  832. * Get cantidadCanjeada
  833. *
  834. * @return integer
  835. */
  836. public function getCantidadCanjeada()
  837. {
  838. return $this->cantidadCanjeada;
  839. }
  840.  
  841. /**
  842. * Set valorGuaranies
  843. *
  844. * @param integer $valorGuaranies
  845. * @return Exppromociones
  846. */
  847. public function setValorGuaranies($valorGuaranies)
  848. {
  849. $this->valorGuaranies = $valorGuaranies;
  850.  
  851. return $this;
  852. }
  853.  
  854. /**
  855. * Get valorGuaranies
  856. *
  857. * @return integer
  858. */
  859. public function getValorGuaranies()
  860. {
  861. return $this->valorGuaranies;
  862. }
  863.  
  864. /**
  865. * Set puntosTelefonico
  866. *
  867. * @param integer $puntosTelefonico
  868. * @return Exppromociones
  869. */
  870. public function setPuntosTelefonico($puntosTelefonico)
  871. {
  872. $this->puntosTelefonico = $puntosTelefonico;
  873.  
  874. return $this;
  875. }
  876.  
  877. /**
  878. * Get puntosTelefonico
  879. *
  880. * @return integer
  881. */
  882. public function getPuntosTelefonico()
  883. {
  884. return $this->puntosTelefonico;
  885. }
  886.  
  887. /**
  888. * Set texto_circulo
  889. *
  890. * @param string $textoCirculo
  891. * @return Exppromociones
  892. */
  893. public function setTextoCirculo($textoCirculo)
  894. {
  895. $this->texto_circulo = $textoCirculo;
  896.  
  897. return $this;
  898. }
  899.  
  900. /**
  901. * Get texto_circulo
  902. *
  903. * @return string
  904. */
  905. public function getTextoCirculo()
  906. {
  907. return $this->texto_circulo;
  908. }
  909.  
  910. public function __toString()
  911. {
  912. return $this->getNombre();
  913. }
  914.  
  915. /**
  916. * Set mostrarValorGuaranies
  917. *
  918. * @param boolean $mostrarValorGuaranies
  919. * @return Exppromociones
  920. */
  921. public function setMostrarValorGuaranies($mostrarValorGuaranies)
  922. {
  923. $this->mostrarValorGuaranies = $mostrarValorGuaranies;
  924.  
  925. return $this;
  926. }
  927.  
  928. /**
  929. * Get mostrarValorGuaranies
  930. *
  931. * @return boolean
  932. */
  933. public function getMostrarValorGuaranies()
  934. {
  935. return $this->mostrarValorGuaranies;
  936. }
  937. }
  938.  
  939. <?php
  940.  
  941. namespace ROSHKABBVASitioUniversosImagenesBundleEntity;
  942.  
  943. use IphpFileStoreBundleMappingAnnotation as FileStore;
  944. use SymfonyComponentValidatorConstraints as Assert;
  945. use DoctrineORMMapping as ORM;
  946.  
  947. /**
  948. * Imagenes
  949. *
  950. * @ORMTable(name="imagenes")
  951. * @ORMEntity
  952. * @FileStoreUploadable
  953. */
  954. class Imagenes
  955. {
  956. /**
  957. * @var integer
  958. *
  959. * @ORMColumn(name="id", type="integer")
  960. * @ORMId
  961. * @ORMGeneratedValue(strategy="AUTO")
  962. */
  963. private $id;
  964.  
  965. /**
  966. * @var string
  967. *
  968. * @ORMColumn(name="Nombre", type="string", length=255)
  969. */
  970. private $nombre;
  971.  
  972.  
  973. /**
  974. * @var Datetime
  975. *
  976. * @ORMColumn(name="Fecha_Carga", type="date")
  977. */
  978. private $fechaCarga;
  979.  
  980. /**
  981. * @ORMColumn(name="Enlace", type="array")
  982. * @AssertFile( maxSize="20M")
  983. * @FileStoreUploadableField(mapping="imagenes")
  984. **/
  985. private $enlace;
  986.  
  987. /**
  988. * @var string
  989. *
  990. * @ORMColumn(name="Tipo", type="string", length=255)
  991. */
  992. private $tipo;
  993.  
  994. /**
  995. * @var string
  996. *
  997. * @ORMColumn(name="Link", type="string", length=255)
  998. */
  999. private $link;
  1000.  
  1001.  
  1002. /**
  1003. * Get id
  1004. *
  1005. * @return integer
  1006. */
  1007. public function getId()
  1008. {
  1009. return $this->id;
  1010. }
  1011.  
  1012. /**
  1013. * Set nombre
  1014. *
  1015. * @param string $nombre
  1016. * @return Imagenes
  1017. */
  1018. public function setNombre($nombre)
  1019. {
  1020. $this->nombre = $nombre;
  1021.  
  1022. return $this;
  1023. }
  1024.  
  1025. /**
  1026. * Get nombre
  1027. *
  1028. * @return string
  1029. */
  1030. public function getNombre()
  1031. {
  1032. return $this->nombre;
  1033. }
  1034.  
  1035. /**
  1036. * Set fechaCarga
  1037. *
  1038. * @param DateTime $fechaCarga
  1039. * @return Imagenes
  1040. */
  1041. public function setFechaCarga($fechaCarga)
  1042. {
  1043. $this->fechaCarga = $fechaCarga;
  1044.  
  1045. return $this;
  1046. }
  1047.  
  1048. /**
  1049. * Get fechaCarga
  1050. *
  1051. * @return DateTime
  1052. */
  1053. public function getFechaCarga()
  1054. {
  1055. return $this->fechaCarga;
  1056. }
  1057.  
  1058. /**
  1059. * Set enlace
  1060. *
  1061. * @param array $enlace
  1062. * @return Imagenes
  1063. */
  1064. public function setEnlace($enlace)
  1065. {
  1066. $this->enlace = $enlace;
  1067.  
  1068. return $this;
  1069. }
  1070.  
  1071. /**
  1072. * Get enlace
  1073. *
  1074. * @return array
  1075. */
  1076. public function getEnlace()
  1077. {
  1078. return $this->enlace;
  1079. }
  1080.  
  1081. public function __toString()
  1082. {
  1083. return $this->getNombre();
  1084. }
  1085.  
  1086. /**
  1087. * Set tipo
  1088. *
  1089. * @param string $tipo
  1090. * @return Imagenes
  1091. */
  1092. public function setTipo($tipo)
  1093. {
  1094. $this->tipo = $tipo;
  1095.  
  1096. return $this;
  1097. }
  1098.  
  1099. /**
  1100. * Get tipo
  1101. *
  1102. * @return string
  1103. */
  1104. public function getTipo()
  1105. {
  1106. return $this->tipo;
  1107. }
  1108.  
  1109. /**
  1110. * Set link
  1111. *
  1112. * @param string $link
  1113. * @return Imagenes
  1114. */
  1115. public function setLink($link)
  1116. {
  1117. $this->link = $link;
  1118.  
  1119. return $this;
  1120. }
  1121.  
  1122. /**
  1123. * Get link
  1124. *
  1125. * @return string
  1126. */
  1127. public function getLink()
  1128. {
  1129. return $this->link;
  1130. }
  1131.  
  1132. public function __construct(){
  1133. $this->fechaCarga = new DateTime();
  1134. }
  1135. }
Add Comment
Please, Sign In to add comment