Commit c6c02b91d4c192a9caaa6d6ffa0c2faea0222273
1 parent
eb3305bd00
Exists in
master
Corregido y enlazada la entidad de tipo uc con las emas entidades
Showing
5 changed files
with
183 additions
and
141 deletions
Show diff stats
src/AppBundle/Entity/MallaCurricularUc.php
| @@ -40,9 +40,9 @@ class MallaCurricularUc | @@ -40,9 +40,9 @@ class MallaCurricularUc | ||
| 40 | private $idUnidadCurricularVolumen; | 40 | private $idUnidadCurricularVolumen; |
| 41 | 41 | ||
| 42 | /** | 42 | /** |
| 43 | - * @var \AppBundle\Entity\TrayectoTramoModalidad | 43 | + * @var \AppBundle\Entity\TrayectoTramoModalidadTipo |
| 44 | * | 44 | * |
| 45 | - * @ORM\ManyToOne(targetEntity="AppBundle\Entity\TrayectoTramoModalidad") | 45 | + * @ORM\ManyToOne(targetEntity="AppBundle\Entity\TrayectoTramoModalidadTipo") |
| 46 | * @ORM\JoinColumns({ | 46 | * @ORM\JoinColumns({ |
| 47 | * @ORM\JoinColumn(name="id_trayecto_tramo_mod", referencedColumnName="id", nullable=false) | 47 | * @ORM\JoinColumn(name="id_trayecto_tramo_mod", referencedColumnName="id", nullable=false) |
| 48 | * }) | 48 | * }) |
| @@ -119,10 +119,10 @@ class MallaCurricularUc | @@ -119,10 +119,10 @@ class MallaCurricularUc | ||
| 119 | /** | 119 | /** |
| 120 | * Set idTrayectoTramoMod | 120 | * Set idTrayectoTramoMod |
| 121 | * | 121 | * |
| 122 | - * @param \AppBundle\Entity\TrayectoTramoModalidad $idTrayectoTramoMod | 122 | + * @param \AppBundle\Entity\TrayectoTramoModalidadTipo $idTrayectoTramoMod |
| 123 | * @return MallaCurricularUc | 123 | * @return MallaCurricularUc |
| 124 | */ | 124 | */ |
| 125 | - public function setIdTrayectoTramoMod(\AppBundle\Entity\TrayectoTramoModalidad $idTrayectoTramoMod) | 125 | + public function setIdTrayectoTramoMod(\AppBundle\Entity\TrayectoTramoModalidadTipo $idTrayectoTramoMod) |
| 126 | { | 126 | { |
| 127 | $this->idTrayectoTramoMod = $idTrayectoTramoMod; | 127 | $this->idTrayectoTramoMod = $idTrayectoTramoMod; |
| 128 | 128 | ||
| @@ -132,7 +132,7 @@ class MallaCurricularUc | @@ -132,7 +132,7 @@ class MallaCurricularUc | ||
| 132 | /** | 132 | /** |
| 133 | * Get idTrayectoTramoMod | 133 | * Get idTrayectoTramoMod |
| 134 | * | 134 | * |
| 135 | - * @return \AppBundle\Entity\TrayectoTramoModalidad | 135 | + * @return \AppBundle\Entity\TrayectoTramoModalidadTipo |
| 136 | */ | 136 | */ |
| 137 | public function getIdTrayectoTramoMod() | 137 | public function getIdTrayectoTramoMod() |
| 138 | { | 138 | { |
src/AppBundle/Entity/TipoUc.php
| @@ -15,7 +15,7 @@ class TipoUc | @@ -15,7 +15,7 @@ class TipoUc | ||
| 15 | /** | 15 | /** |
| 16 | * @var string | 16 | * @var string |
| 17 | * | 17 | * |
| 18 | - * @ORM\Column(name="nombre", type="string", length=10, nullable=false, options={"comment" = "nombre del tipo de unidad curricular (optativa, obligatoria, electiva)"}) | 18 | + * @ORM\Column(name="nombre", type="string", length=80, nullable=false, options={"comment" = "nombre del tipo de unidad curricular (optativa, obligatoria, electiva)"}) |
| 19 | */ | 19 | */ |
| 20 | private $nombre; | 20 | private $nombre; |
| 21 | 21 |
src/AppBundle/Entity/TrayectoTramoModalidad.php
| @@ -1,135 +0,0 @@ | @@ -1,135 +0,0 @@ | ||
| 1 | -<?php | ||
| 2 | - | ||
| 3 | -namespace AppBundle\Entity; | ||
| 4 | - | ||
| 5 | -use Doctrine\ORM\Mapping as ORM; | ||
| 6 | - | ||
| 7 | -/** | ||
| 8 | - * TrayectoTramoModalidad | ||
| 9 | - * | ||
| 10 | - * @ORM\Table(name="trayecto_tramo_modalidad", uniqueConstraints={@ORM\UniqueConstraint(name="i_trayecto_tramo_modalidad", columns={"id_trayecto", "id_tramo"})}, indexes={@ORM\Index(name="fki_modalidad_trayecto_tramo_modalidad", columns={"id_modalidad"}), @ORM\Index(name="fki_tramo_trayecto_tramo_modalidad", columns={"id_tramo"}), @ORM\Index(name="IDX_AE063967814981A6", columns={"id_trayecto"})}) | ||
| 11 | - * @ORM\Entity | ||
| 12 | - */ | ||
| 13 | -class TrayectoTramoModalidad | ||
| 14 | -{ | ||
| 15 | - /** | ||
| 16 | - * @var integer | ||
| 17 | - * | ||
| 18 | - * @ORM\Column(name="id", type="integer", nullable=false, options={"comment" = "identificador del trayecto_tramo_modalidad"}) | ||
| 19 | - * @ORM\Id | ||
| 20 | - * @ORM\GeneratedValue(strategy="IDENTITY") | ||
| 21 | - * @ORM\SequenceGenerator(sequenceName="trayecto_tramo_modalidad_id_seq", allocationSize=1, initialValue=1) | ||
| 22 | - */ | ||
| 23 | - private $id; | ||
| 24 | - | ||
| 25 | - /** | ||
| 26 | - * @var \AppBundle\Entity\Trayecto | ||
| 27 | - * | ||
| 28 | - * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Trayecto") | ||
| 29 | - * @ORM\JoinColumns({ | ||
| 30 | - * @ORM\JoinColumn(name="id_trayecto", referencedColumnName="id", nullable=false) | ||
| 31 | - * }) | ||
| 32 | - */ | ||
| 33 | - private $idTrayecto; | ||
| 34 | - | ||
| 35 | - /** | ||
| 36 | - * @var \AppBundle\Entity\Tramo | ||
| 37 | - * | ||
| 38 | - * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Tramo") | ||
| 39 | - * @ORM\JoinColumns({ | ||
| 40 | - * @ORM\JoinColumn(name="id_tramo", referencedColumnName="id", nullable=false) | ||
| 41 | - * }) | ||
| 42 | - */ | ||
| 43 | - private $idTramo; | ||
| 44 | - | ||
| 45 | - /** | ||
| 46 | - * @var \AppBundle\Entity\Modalidad | ||
| 47 | - * | ||
| 48 | - * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Modalidad") | ||
| 49 | - * @ORM\JoinColumns({ | ||
| 50 | - * @ORM\JoinColumn(name="id_modalidad", referencedColumnName="id", nullable=false) | ||
| 51 | - * }) | ||
| 52 | - */ | ||
| 53 | - private $idModalidad; | ||
| 54 | - | ||
| 55 | - | ||
| 56 | - | ||
| 57 | - /** | ||
| 58 | - * Get id | ||
| 59 | - * | ||
| 60 | - * @return integer | ||
| 61 | - */ | ||
| 62 | - public function getId() | ||
| 63 | - { | ||
| 64 | - return $this->id; | ||
| 65 | - } | ||
| 66 | - | ||
| 67 | - /** | ||
| 68 | - * Set idTrayecto | ||
| 69 | - * | ||
| 70 | - * @param \AppBundle\Entity\Trayecto $idTrayecto | ||
| 71 | - * @return TrayectoTramoModalidad | ||
| 72 | - */ | ||
| 73 | - public function setIdTrayecto(\AppBundle\Entity\Trayecto $idTrayecto) | ||
| 74 | - { | ||
| 75 | - $this->idTrayecto = $idTrayecto; | ||
| 76 | - | ||
| 77 | - return $this; | ||
| 78 | - } | ||
| 79 | - | ||
| 80 | - /** | ||
| 81 | - * Get idTrayecto | ||
| 82 | - * | ||
| 83 | - * @return \AppBundle\Entity\Trayecto | ||
| 84 | - */ | ||
| 85 | - public function getIdTrayecto() | ||
| 86 | - { | ||
| 87 | - return $this->idTrayecto; | ||
| 88 | - } | ||
| 89 | - | ||
| 90 | - /** | ||
| 91 | - * Set idTramo | ||
| 92 | - * | ||
| 93 | - * @param \AppBundle\Entity\Tramo $idTramo | ||
| 94 | - * @return TrayectoTramoModalidad | ||
| 95 | - */ | ||
| 96 | - public function setIdTramo(\AppBundle\Entity\Tramo $idTramo) | ||
| 97 | - { | ||
| 98 | - $this->idTramo = $idTramo; | ||
| 99 | - | ||
| 100 | - return $this; | ||
| 101 | - } | ||
| 102 | - | ||
| 103 | - /** | ||
| 104 | - * Get idTramo | ||
| 105 | - * | ||
| 106 | - * @return \AppBundle\Entity\Tramo | ||
| 107 | - */ | ||
| 108 | - public function getIdTramo() | ||
| 109 | - { | ||
| 110 | - return $this->idTramo; | ||
| 111 | - } | ||
| 112 | - | ||
| 113 | - /** | ||
| 114 | - * Set idModalidad | ||
| 115 | - * | ||
| 116 | - * @param \AppBundle\Entity\Modalidad $idModalidad | ||
| 117 | - * @return TrayectoTramoModalidad | ||
| 118 | - */ | ||
| 119 | - public function setIdModalidad(\AppBundle\Entity\Modalidad $idModalidad) | ||
| 120 | - { | ||
| 121 | - $this->idModalidad = $idModalidad; | ||
| 122 | - | ||
| 123 | - return $this; | ||
| 124 | - } | ||
| 125 | - | ||
| 126 | - /** | ||
| 127 | - * Get idModalidad | ||
| 128 | - * | ||
| 129 | - * @return \AppBundle\Entity\Modalidad | ||
| 130 | - */ | ||
| 131 | - public function getIdModalidad() | ||
| 132 | - { | ||
| 133 | - return $this->idModalidad; | ||
| 134 | - } | ||
| 135 | -} |
src/AppBundle/Entity/TrayectoTramoModalidadTipo.php
| @@ -0,0 +1,168 @@ | @@ -0,0 +1,168 @@ | ||
| 1 | +<?php | ||
| 2 | + | ||
| 3 | +namespace AppBundle\Entity; | ||
| 4 | + | ||
| 5 | +use Doctrine\ORM\Mapping as ORM; | ||
| 6 | + | ||
| 7 | +/** | ||
| 8 | + * TrayectoTramoModalidadTipo | ||
| 9 | + * | ||
| 10 | + * @ORM\Table(name="trayecto_tramo_modalidad_tipo_uc", uniqueConstraints={@ORM\UniqueConstraint(name="i_trayecto_tramo_modalidad_tipo_uc", columns={"id_trayecto", "id_tramo", "id_modalidad", "id_tipo_uc"})}, indexes={@ORM\Index(name="fki_modalidad", columns={"id_modalidad"}), @ORM\Index(name="fki_tramo_trayecto_tramo_modalidad", columns={"id_tramo"}), @ORM\Index(name="IDX_AE063967814981A6", columns={"id_trayecto"}), @ORM\Index(name="IDX_TIPO_UC", columns={"id_tipo_uc"})}) | ||
| 11 | + * @ORM\Entity | ||
| 12 | + */ | ||
| 13 | +class TrayectoTramoModalidadTipo | ||
| 14 | +{ | ||
| 15 | + /** | ||
| 16 | + * @var integer | ||
| 17 | + * | ||
| 18 | + * @ORM\Column(name="id", type="integer", nullable=false, options={"comment" = "identificador del trayecto_tramo_modalidad"}) | ||
| 19 | + * @ORM\Id | ||
| 20 | + * @ORM\GeneratedValue(strategy="IDENTITY") | ||
| 21 | + * @ORM\SequenceGenerator(sequenceName="trayecto_tramo_modalidad_id_seq", allocationSize=1, initialValue=1) | ||
| 22 | + */ | ||
| 23 | + private $id; | ||
| 24 | + | ||
| 25 | + /** | ||
| 26 | + * @var \AppBundle\Entity\Trayecto | ||
| 27 | + * | ||
| 28 | + * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Trayecto") | ||
| 29 | + * @ORM\JoinColumns({ | ||
| 30 | + * @ORM\JoinColumn(name="id_trayecto", referencedColumnName="id", nullable=false) | ||
| 31 | + * }) | ||
| 32 | + */ | ||
| 33 | + private $idTrayecto; | ||
| 34 | + | ||
| 35 | + /** | ||
| 36 | + * @var \AppBundle\Entity\Tramo | ||
| 37 | + * | ||
| 38 | + * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Tramo") | ||
| 39 | + * @ORM\JoinColumns({ | ||
| 40 | + * @ORM\JoinColumn(name="id_tramo", referencedColumnName="id", nullable=false) | ||
| 41 | + * }) | ||
| 42 | + */ | ||
| 43 | + private $idTramo; | ||
| 44 | + | ||
| 45 | + /** | ||
| 46 | + * @var \AppBundle\Entity\Modalidad | ||
| 47 | + * | ||
| 48 | + * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Modalidad") | ||
| 49 | + * @ORM\JoinColumns({ | ||
| 50 | + * @ORM\JoinColumn(name="id_modalidad", referencedColumnName="id", nullable=false) | ||
| 51 | + * }) | ||
| 52 | + */ | ||
| 53 | + private $idModalidad; | ||
| 54 | + | ||
| 55 | + /** | ||
| 56 | + * @var \AppBundle\Entity\TipoUc | ||
| 57 | + * | ||
| 58 | + * @ORM\ManyToOne(targetEntity="AppBundle\Entity\TipoUc") | ||
| 59 | + * @ORM\JoinColumns({ | ||
| 60 | + * @ORM\JoinColumn(name="id_tipo_uc", referencedColumnName="id", nullable=false) | ||
| 61 | + * }) | ||
| 62 | + */ | ||
| 63 | + private $idTipoUc; | ||
| 64 | + | ||
| 65 | + | ||
| 66 | + | ||
| 67 | + /** | ||
| 68 | + * Get id | ||
| 69 | + * | ||
| 70 | + * @return integer | ||
| 71 | + */ | ||
| 72 | + public function getId() | ||
| 73 | + { | ||
| 74 | + return $this->id; | ||
| 75 | + } | ||
| 76 | + | ||
| 77 | + /** | ||
| 78 | + * Set idTrayecto | ||
| 79 | + * | ||
| 80 | + * @param \AppBundle\Entity\Trayecto $idTrayecto | ||
| 81 | + * @return TrayectoTramoModalidadTipo | ||
| 82 | + */ | ||
| 83 | + public function setIdTrayecto(\AppBundle\Entity\Trayecto $idTrayecto) | ||
| 84 | + { | ||
| 85 | + $this->idTrayecto = $idTrayecto; | ||
| 86 | + | ||
| 87 | + return $this; | ||
| 88 | + } | ||
| 89 | + | ||
| 90 | + /** | ||
| 91 | + * Get idTrayecto | ||
| 92 | + * | ||
| 93 | + * @return \AppBundle\Entity\Trayecto | ||
| 94 | + */ | ||
| 95 | + public function getIdTrayecto() | ||
| 96 | + { | ||
| 97 | + return $this->idTrayecto; | ||
| 98 | + } | ||
| 99 | + | ||
| 100 | + /** | ||
| 101 | + * Set idTramo | ||
| 102 | + * | ||
| 103 | + * @param \AppBundle\Entity\Tramo $idTramo | ||
| 104 | + * @return TrayectoTramoModalidadTipo | ||
| 105 | + */ | ||
| 106 | + public function setIdTramo(\AppBundle\Entity\Tramo $idTramo) | ||
| 107 | + { | ||
| 108 | + $this->idTramo = $idTramo; | ||
| 109 | + | ||
| 110 | + return $this; | ||
| 111 | + } | ||
| 112 | + | ||
| 113 | + /** | ||
| 114 | + * Get idTramo | ||
| 115 | + * | ||
| 116 | + * @return \AppBundle\Entity\Tramo | ||
| 117 | + */ | ||
| 118 | + public function getIdTramo() | ||
| 119 | + { | ||
| 120 | + return $this->idTramo; | ||
| 121 | + } | ||
| 122 | + | ||
| 123 | + /** | ||
| 124 | + * Set idModalidad | ||
| 125 | + * | ||
| 126 | + * @param \AppBundle\Entity\Modalidad $idModalidad | ||
| 127 | + * @return TrayectoTramoModalidadTipo | ||
| 128 | + */ | ||
| 129 | + public function setIdModalidad(\AppBundle\Entity\Modalidad $idModalidad) | ||
| 130 | + { | ||
| 131 | + $this->idModalidad = $idModalidad; | ||
| 132 | + | ||
| 133 | + return $this; | ||
| 134 | + } | ||
| 135 | + | ||
| 136 | + /** | ||
| 137 | + * Get idModalidad | ||
| 138 | + * | ||
| 139 | + * @return \AppBundle\Entity\Modalidad | ||
| 140 | + */ | ||
| 141 | + public function getIdModalidad() | ||
| 142 | + { | ||
| 143 | + return $this->idModalidad; | ||
| 144 | + } | ||
| 145 | + | ||
| 146 | + /** | ||
| 147 | + * Set idTipoUc | ||
| 148 | + * | ||
| 149 | + * @param \AppBundle\Entity\TipoUc $idTipoUc | ||
| 150 | + * @return TrayectoTramoModalidadTipo | ||
| 151 | + */ | ||
| 152 | + public function setIdTipoUc(\AppBundle\Entity\TipoUc $idTipoUc) | ||
| 153 | + { | ||
| 154 | + $this->idTipoUc = $idTipoUc; | ||
| 155 | + | ||
| 156 | + return $this; | ||
| 157 | + } | ||
| 158 | + | ||
| 159 | + /** | ||
| 160 | + * Get idTipoUc | ||
| 161 | + * | ||
| 162 | + * @return \AppBundle\Entity\TipoUc | ||
| 163 | + */ | ||
| 164 | + public function getIdTipoUc() | ||
| 165 | + { | ||
| 166 | + return $this->idTipoUc; | ||
| 167 | + } | ||
| 168 | +} |
src/AppBundle/Entity/UnidadCurricular.php
| @@ -155,4 +155,13 @@ class UnidadCurricular | @@ -155,4 +155,13 @@ class UnidadCurricular | ||
| 155 | { | 155 | { |
| 156 | return $this->creditos; | 156 | return $this->creditos; |
| 157 | } | 157 | } |
| 158 | + | ||
| 159 | + /** | ||
| 160 | + * | ||
| 161 | + * @return string | ||
| 162 | + */ | ||
| 163 | + | ||
| 164 | + public function __toString() { | ||
| 165 | + return $this->getNombre(); | ||
| 166 | + } | ||
| 158 | } | 167 | } |