diff --git a/.delete.txt b/.delete.txt deleted file mode 100644 index df7e0b5..0000000 --- a/.delete.txt +++ /dev/null @@ -1,87 +0,0 @@ -DROP TABLE IF EXISTS `recibo`; -/*!40101 SET @saved_cs_client = @@character_set_client */; -/*!50503 SET character_set_client = utf8mb4 */; -CREATE TABLE `recibo` ( - `id_recibo` int(11) NOT NULL AUTO_INCREMENT, - `folio_recibo` varchar(45) NOT NULL, - `monto` decimal(10,2) NOT NULL, - `fecha_recibo` date NOT NULL, - `fecha_registro` timestamp NOT NULL DEFAULT current_timestamp(), - `id_cuenta` int(9) unsigned zerofill NOT NULL, - `id_usuario` int(11) NOT NULL, - PRIMARY KEY (`id_recibo`), - KEY `fk_Credito_Alumno` (`id_cuenta`), - KEY `fk_Credito_Usuario1` (`id_usuario`), - CONSTRAINT `fk_Credito_Alumno` FOREIGN KEY (`id_cuenta`) REFERENCES `alumno` (`id_cuenta`) ON UPDATE CASCADE, - CONSTRAINT `fk_Credito_Usuario1` FOREIGN KEY (`id_usuario`) REFERENCES `usuario` (`id_usuario`) ON UPDATE CASCADE -) ENGINE=InnoDB AUTO_INCREMENT=120607 DEFAULT CHARSET=utf8mb3 COMMENT='Capturar todos los recibos que el alumno entregue'; -/*!40101 SET character_set_client = @saved_cs_client */; - -DROP TABLE IF EXISTS `carrera`; -/*!40101 SET @saved_cs_client = @@character_set_client */; -/*!50503 SET character_set_client = utf8mb4 */; -CREATE TABLE `carrera` ( - `id_carrera` int(11) NOT NULL, - `carrera` varchar(100) NOT NULL, - PRIMARY KEY (`id_carrera`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3; -/*!40101 SET character_set_client = @saved_cs_client */; - - -DROP TABLE IF EXISTS `perfil`; -/*!40101 SET @saved_cs_client = @@character_set_client */; -/*!50503 SET character_set_client = utf8mb4 */; -CREATE TABLE `perfil` ( - `id_perfil` int(11) NOT NULL AUTO_INCREMENT, - `perfil` varchar(45) NOT NULL, - PRIMARY KEY (`id_perfil`) -) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb3; -/*!40101 SET character_set_client = @saved_cs_client */; - -DROP TABLE IF EXISTS `detalle_servicio`; -/*!40101 SET @saved_cs_client = @@character_set_client */; -/*!50503 SET character_set_client = utf8mb4 */; -CREATE TABLE `detalle_servicio` ( - `id_detalle_servicio` int(11) NOT NULL AUTO_INCREMENT, - `monto` decimal(10,2) NOT NULL, - `numero_hojas` int(11) NOT NULL DEFAULT 0, - `fecha_operacion` timestamp NOT NULL DEFAULT current_timestamp(), - `id_cuenta` int(9) unsigned zerofill NOT NULL, - `id_servicio` int(11) NOT NULL, - `id_usuario` int(11) NOT NULL, - `id_periodo` int(11) DEFAULT NULL, - PRIMARY KEY (`id_detalle_servicio`), - KEY `index_DetalleIngresoEgreso_Servicio1` (`id_servicio`), - KEY `index_DetalleIngresoEgreso_Alumno1` (`id_cuenta`), - KEY `fk_DetalleServicio_usuario1` (`id_usuario`), - KEY `fk_detalle_servicio_periodo1` (`id_periodo`), - CONSTRAINT `fk_DetalleIngresoEgreso_Alumno1` FOREIGN KEY (`id_cuenta`) REFERENCES `alumno` (`id_cuenta`) ON UPDATE CASCADE, - CONSTRAINT `fk_DetalleIngresoEgreso_Servicio1` FOREIGN KEY (`id_servicio`) REFERENCES `servicio` (`id_servicio`) ON UPDATE CASCADE, - CONSTRAINT `fk_DetalleServicio_usuario1` FOREIGN KEY (`id_usuario`) REFERENCES `usuario` (`id_usuario`) ON UPDATE CASCADE, - CONSTRAINT `fk_detalle_servicio_periodo1` FOREIGN KEY (`id_periodo`) REFERENCES `periodo` (`id_periodo`) ON UPDATE CASCADE -) ENGINE=InnoDB AUTO_INCREMENT=167097 DEFAULT CHARSET=utf8mb3; -/*!40101 SET character_set_client = @saved_cs_client */; - - -DROP TABLE IF EXISTS `periodo`; -/*!40101 SET @saved_cs_client = @@character_set_client */; -/*!50503 SET character_set_client = utf8mb4 */; -CREATE TABLE `periodo` ( - `id_periodo` int(11) NOT NULL AUTO_INCREMENT, - `semestre` char(6) NOT NULL, - `fecha_inicio_servicio` date NOT NULL, - `fecha_fin_servicio` date NOT NULL, - `activo` bit(1) NOT NULL DEFAULT b'1' COMMENT 'cuando se cree un periodo nuevo todos los anteriores deben de quedar en 0, y el ultimo en 1.', - PRIMARY KEY (`id_periodo`) -) ENGINE=InnoDB AUTO_INCREMENT=28 DEFAULT CHARSET=utf8mb3; -/*!40101 SET character_set_client = @saved_cs_client */; - -DROP TABLE IF EXISTS `servicio`; -/*!40101 SET @saved_cs_client = @@character_set_client */; -/*!50503 SET character_set_client = utf8mb4 */; -CREATE TABLE `servicio` ( - `id_servicio` int(11) NOT NULL AUTO_INCREMENT, - `servicio` varchar(45) NOT NULL, - PRIMARY KEY (`id_servicio`) -) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=utf8mb3; -/*!40101 SET character_set_client = @saved_cs_client */; diff --git a/src/app.module.ts b/src/app.module.ts index 7c3223c..daed7f2 100644 --- a/src/app.module.ts +++ b/src/app.module.ts @@ -36,6 +36,7 @@ import { ProgramaModule } from './programa/programa.module'; import { AreaUbicacion } from './area_ubicacion/entities/area_ubicacion.entity'; import { Programa } from './programa/entities/programa.entity'; import { ProgramaEquipoModule } from './programa_equipo/programa_equipo.module'; +import { ProgramaEquipo } from './programa_equipo/entities/programa_equipo.entity'; @Module({ imports: [ @@ -69,6 +70,7 @@ import { ProgramaEquipoModule } from './programa_equipo/programa_equipo.module'; Equipo, AreaUbicacion, Programa, + ProgramaEquipo, ], synchronize: false, //Never change to true in production! }),