update
This commit is contained in:
@ -1,58 +0,0 @@
|
|||||||
import { Column, CreateDateColumn, DeleteDateColumn, Entity, JoinColumn, JoinTable, ManyToOne, OneToMany, PrimaryGeneratedColumn, UpdateDateColumn } from "typeorm";
|
|
||||||
import { TrxMaintenancePosition, TrxMaintenanceStatus } from "../types/trx";
|
|
||||||
import { TrxMaintenance } from "./trx_maintenances";
|
|
||||||
import { Status } from "../types/status";
|
|
||||||
import { TrxMaintenanceGroup } from "./trx_maintenance_groups";
|
|
||||||
import { TrxCustomer } from "./trx_customers";
|
|
||||||
|
|
||||||
@Entity("trx_maintenance_customers", { schema: "trx" })
|
|
||||||
export class TrxMaintenanceCustomer {
|
|
||||||
@PrimaryGeneratedColumn("uuid")
|
|
||||||
id: string;
|
|
||||||
|
|
||||||
@ManyToOne(() => TrxMaintenance, { onDelete: "NO ACTION" })
|
|
||||||
@JoinTable()
|
|
||||||
maintenance: TrxMaintenance;
|
|
||||||
|
|
||||||
@ManyToOne(() => TrxCustomer, { onDelete: "NO ACTION" })
|
|
||||||
@JoinTable()
|
|
||||||
customer: TrxCustomer;
|
|
||||||
|
|
||||||
@Column({
|
|
||||||
nullable: false,
|
|
||||||
length: 256,
|
|
||||||
})
|
|
||||||
cif_number: string;
|
|
||||||
|
|
||||||
@Column({
|
|
||||||
nullable: false,
|
|
||||||
length: 256,
|
|
||||||
})
|
|
||||||
name: string;
|
|
||||||
|
|
||||||
@Column({
|
|
||||||
length: 256,
|
|
||||||
})
|
|
||||||
status: Status;
|
|
||||||
|
|
||||||
@Column()
|
|
||||||
@CreateDateColumn()
|
|
||||||
created_at: Date;
|
|
||||||
|
|
||||||
@Column({ nullable: true, length: 256 })
|
|
||||||
created_by: string;
|
|
||||||
|
|
||||||
@Column({ nullable: true })
|
|
||||||
@UpdateDateColumn()
|
|
||||||
updated_at: Date;
|
|
||||||
|
|
||||||
@Column({ nullable: true, length: 256 })
|
|
||||||
updated_by: string;
|
|
||||||
|
|
||||||
@Column({ nullable: true })
|
|
||||||
@DeleteDateColumn()
|
|
||||||
deleted_at: Date;
|
|
||||||
|
|
||||||
@Column({ nullable: true, length: 256 })
|
|
||||||
deleted_by: string;
|
|
||||||
}
|
|
||||||
@ -26,5 +26,4 @@ export * from "../entity/trx_maintenances";
|
|||||||
export * from "../entity/trx_maintenance_details";
|
export * from "../entity/trx_maintenance_details";
|
||||||
export * from "../entity/trx_maintenance_slas";
|
export * from "../entity/trx_maintenance_slas";
|
||||||
export * from "../entity/trx_maintenance_groups";
|
export * from "../entity/trx_maintenance_groups";
|
||||||
export * from "../entity/trx_maintenance_customers";
|
|
||||||
export * from "../types/trx";
|
export * from "../types/trx";
|
||||||
|
|||||||
Reference in New Issue
Block a user