listo multa
This commit is contained in:
@@ -1,29 +1,29 @@
|
||||
import {
|
||||
Entity,
|
||||
Column,
|
||||
PrimaryGeneratedColumn,
|
||||
OneToOne,
|
||||
ManyToOne,
|
||||
Entity,
|
||||
JoinColumn,
|
||||
ManyToOne,
|
||||
OneToOne,
|
||||
PrimaryGeneratedColumn,
|
||||
} from 'typeorm';
|
||||
import { InstitucionInfraccion } from '../institucion-infraccion/entity/institucion-infraccion.entity';
|
||||
import { Prestamo } from '../prestamo/prestamo.entity';
|
||||
import { InstitucionInfraccion } from '../../institucion-infraccion/entity/institucion-infraccion.entity';
|
||||
import { Prestamo } from '../../prestamo/prestamo.entity';
|
||||
|
||||
@Entity()
|
||||
export class Multa {
|
||||
@PrimaryGeneratedColumn()
|
||||
id_multa: number;
|
||||
|
||||
@Column()
|
||||
@Column({ type: Boolean, nullable: false, default: true })
|
||||
activo: boolean;
|
||||
|
||||
@Column()
|
||||
fecha_inicio: Date;
|
||||
|
||||
@Column()
|
||||
@Column({ type: Date, nullable: false })
|
||||
fecha_fin: Date;
|
||||
|
||||
@Column()
|
||||
@Column({ type: Date, nullable: false })
|
||||
fecha_inicio: Date;
|
||||
|
||||
@Column({ type: Boolean, nullable: false })
|
||||
retraso: boolean;
|
||||
|
||||
@ManyToOne(
|
||||
@@ -1,7 +1,19 @@
|
||||
import { Controller } from '@nestjs/common';
|
||||
import { Controller, Get } from '@nestjs/common';
|
||||
import { MultaService } from './multa.service';
|
||||
|
||||
@Controller('multa')
|
||||
export class MultaController {
|
||||
constructor(private multaService: MultaService) {}
|
||||
|
||||
@Get()
|
||||
multas() {}
|
||||
|
||||
@Get('multas_usuario')
|
||||
multasUsuario() {}
|
||||
|
||||
@Get('multas_equipo')
|
||||
multasEquipo() {}
|
||||
|
||||
@Get('reporte')
|
||||
reporte() {}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import { Module } from '@nestjs/common';
|
||||
import { TypeOrmModule } from '@nestjs/typeorm';
|
||||
import { MultaController } from './multa.controller';
|
||||
import { Multa } from './multa.entity';
|
||||
import { MultaService } from './multa.service';
|
||||
import { Multa } from './entity/multa.entity';
|
||||
|
||||
@Module({
|
||||
imports: [TypeOrmModule.forFeature([Multa])],
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Injectable } from '@nestjs/common';
|
||||
import { Repository } from 'typeorm';
|
||||
import { InjectRepository } from '@nestjs/typeorm';
|
||||
import { Multa } from './multa.entity';
|
||||
import { Repository } from 'typeorm';
|
||||
import { Multa } from './entity/multa.entity';
|
||||
|
||||
@Injectable()
|
||||
export class MultaService {
|
||||
|
||||
Reference in New Issue
Block a user