This commit is contained in:
meusinfirmary
2025-04-21 00:45:17 +07:00
parent e801a2a5a6
commit a9a375ba69
4 changed files with 127 additions and 62 deletions

View File

@ -1,52 +1,52 @@
import { Entity, PrimaryGeneratedColumn, Column, CreateDateColumn, UpdateDateColumn, DeleteDateColumn, Index, JoinColumn, ManyToOne } from 'typeorm';
import { Entity, PrimaryGeneratedColumn, Column, CreateDateColumn, UpdateDateColumn, DeleteDateColumn, Index, JoinColumn, ManyToOne } from "typeorm";
import { Status } from '../types/status';
import { Status } from "../types/status";
@Entity('credit_configs')
@Entity("credit_configs")
export class CreditConfigs {
@PrimaryGeneratedColumn('uuid')
@PrimaryGeneratedColumn("uuid")
id: string;
@Column({
nullable: true,
length: 256
length: 256,
})
module: string;
@Column({
nullable: true,
length: 256
length: 256,
})
code: string;
@Column({
nullable: true,
length: 256
length: 256,
})
param: string;
@Column({
nullable: true,
length: 256
length: 256,
})
debtor_type: string;
@Column({
nullable: true,
type: 'int2'
type: "int2",
})
order_number: number;
@Column({
nullable: true,
length: 4096
length: 4096,
})
value: string;
@Column({
nullable: false,
default: Status['Not Active'],
length: 64
default: Status["Not Active"],
length: 64,
})
status: Status;
@ -56,7 +56,7 @@ export class CreditConfigs {
@Column({
nullable: true,
length: 256
length: 256,
})
created_by: string;
@ -66,7 +66,7 @@ export class CreditConfigs {
@Column({
nullable: true,
length: 256
length: 256,
})
updated_by: string;

View File

@ -0,0 +1,63 @@
import { Entity, PrimaryGeneratedColumn, Column, CreateDateColumn, UpdateDateColumn, DeleteDateColumn, Index, JoinColumn, ManyToOne } from "typeorm";
import { Status } from "../types/status";
@Entity("remit_configs", { schema: "remits" })
export class RemitConfig {
@PrimaryGeneratedColumn("uuid")
id: string;
@Column({
nullable: true,
length: 256,
})
min: string;
@Column({
nullable: true,
length: 256,
})
max: string;
@Column({
nullable: true,
length: 256,
})
type: string;
@Column({
nullable: true,
length: 256,
})
value: string;
@Column({
nullable: false,
length: 64,
})
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;
}

View File

@ -87,7 +87,8 @@ import { RemitRegion } from "./entity/remit_region";
import { RemitTransfer } from "./entity/remit_tansfer";
import { RemitTopup } from "./entity/remit_topup";
import { RemitMutation } from "./entity/remit_mutation";
import { RemitBank } from "./entity/remit_banks";
import { RemitBank } from "./entity/remit_bank";
import { RemitConfig } from "./entity/remit_config";
export {
User, //
@ -187,4 +188,5 @@ export {
RemitTopup,
RemitMutation,
RemitBank,
RemitConfig,
};