added enities
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
import { InscripcionArea } from "src/inscripcion-area/entity/inscripcion_area.entity";
|
||||
import { Column, Entity, OneToMany, PrimaryColumn, PrimaryGeneratedColumn } from "typeorm";
|
||||
|
||||
@Entity()
|
||||
export class Area {
|
||||
@PrimaryGeneratedColumn()
|
||||
id_area: number
|
||||
|
||||
@Column({length:60, nullable:false})
|
||||
area: string
|
||||
|
||||
@OneToMany(
|
||||
() => InscripcionArea, (inscripcionArea) => inscripcionArea.area
|
||||
)
|
||||
inscripcionArea: InscripcionArea[]
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
import { Miembro } from "src/miembro/entity/miembro.entity";
|
||||
import { Column, Entity, OneToMany, PrimaryGeneratedColumn } from "typeorm";
|
||||
|
||||
@Entity()
|
||||
export class Carrera {
|
||||
@PrimaryGeneratedColumn()
|
||||
id_carrera: number
|
||||
|
||||
@Column({ length:70, nullable: false})
|
||||
carrera: string
|
||||
|
||||
@OneToMany(
|
||||
() => Miembro, (miembro) => miembro.carrera
|
||||
)
|
||||
miembro: Miembro
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
import { Miembro } from "src/miembro/entity/miembro.entity";
|
||||
import { Column, Entity, OneToMany, PrimaryGeneratedColumn } from "typeorm";
|
||||
|
||||
@Entity()
|
||||
export class TipoMiembro {
|
||||
@PrimaryGeneratedColumn()
|
||||
id_tipo_miembro: number
|
||||
|
||||
@Column({length:60, nullable:false})
|
||||
tipo_miembro: string
|
||||
|
||||
@OneToMany(
|
||||
() => Miembro, (miembro) => miembro.tipoMiembro
|
||||
)
|
||||
miembro: Miembro
|
||||
}
|
||||
Reference in New Issue
Block a user