Merge branch 'main' of https://git.shiblysolution.id/BRITL/entity
This commit is contained in:
55
src/entity/remit_partner_allocations.ts
Normal file
55
src/entity/remit_partner_allocations.ts
Normal file
@ -0,0 +1,55 @@
|
|||||||
|
import { Entity, PrimaryGeneratedColumn, Column, CreateDateColumn, UpdateDateColumn, DeleteDateColumn, Index, JoinColumn, ManyToOne, JoinTable } from "typeorm";
|
||||||
|
import { Status } from "../types/status";
|
||||||
|
import { RemitPartner } from "./remit_partners";
|
||||||
|
|
||||||
|
@Entity("remit_partner_allocations", { schema: "remits" })
|
||||||
|
export class RemitPartnerAllocation {
|
||||||
|
@PrimaryGeneratedColumn("uuid")
|
||||||
|
id: string;
|
||||||
|
|
||||||
|
@ManyToOne(() => RemitPartner, { onDelete: "CASCADE" })
|
||||||
|
@JoinTable()
|
||||||
|
partner: RemitPartner;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 256,
|
||||||
|
})
|
||||||
|
bri_value: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 256,
|
||||||
|
})
|
||||||
|
partner_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;
|
||||||
|
}
|
||||||
67
src/entity/remit_partner_transactions.ts
Normal file
67
src/entity/remit_partner_transactions.ts
Normal file
@ -0,0 +1,67 @@
|
|||||||
|
import { Entity, PrimaryGeneratedColumn, Column, CreateDateColumn, UpdateDateColumn, DeleteDateColumn, Index, JoinColumn, ManyToOne, JoinTable } from "typeorm";
|
||||||
|
import { Status } from "../types/status";
|
||||||
|
import { RemitPartner } from "./remit_partners";
|
||||||
|
|
||||||
|
@Entity("remit_partner_transactions", { schema: "remits" })
|
||||||
|
export class RemitPartnerTransaction {
|
||||||
|
@PrimaryGeneratedColumn("uuid")
|
||||||
|
id: string;
|
||||||
|
|
||||||
|
@ManyToOne(() => RemitPartner, { onDelete: "CASCADE" })
|
||||||
|
@JoinTable()
|
||||||
|
partner: RemitPartner;
|
||||||
|
|
||||||
|
@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;
|
||||||
|
}
|
||||||
@ -26,6 +26,13 @@ export class RemitPartner {
|
|||||||
})
|
})
|
||||||
phone: string;
|
phone: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
unique: false,
|
||||||
|
length: 256,
|
||||||
|
})
|
||||||
|
email: string;
|
||||||
|
|
||||||
@Column({
|
@Column({
|
||||||
nullable: true,
|
nullable: true,
|
||||||
length: 4096,
|
length: 4096,
|
||||||
@ -183,4 +190,14 @@ export class RemitPartner {
|
|||||||
@Column({ nullable: true })
|
@Column({ nullable: true })
|
||||||
@DeleteDateColumn()
|
@DeleteDateColumn()
|
||||||
deleted_at: Date;
|
deleted_at: Date;
|
||||||
|
|
||||||
|
@Column({ type: "timestamp", nullable: true })
|
||||||
|
finalized_at: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 256,
|
||||||
|
unique: false,
|
||||||
|
})
|
||||||
|
finalized_by: string;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,6 +2,7 @@ import bcrypt from "bcryptjs";
|
|||||||
import { Status } from "../types/status";
|
import { Status } from "../types/status";
|
||||||
import { Entity, PrimaryGeneratedColumn, Column, CreateDateColumn, UpdateDateColumn, DeleteDateColumn, Index, OneToOne, JoinColumn, ManyToOne, OneToMany, ManyToMany, JoinTable } from "typeorm";
|
import { Entity, PrimaryGeneratedColumn, Column, CreateDateColumn, UpdateDateColumn, DeleteDateColumn, Index, OneToOne, JoinColumn, ManyToOne, OneToMany, ManyToMany, JoinTable } from "typeorm";
|
||||||
import { RemitPartner } from "./remit_partners";
|
import { RemitPartner } from "./remit_partners";
|
||||||
|
import { ApprovalStatus } from "../enum/approvalStatus";
|
||||||
|
|
||||||
@Entity("remit_transfer", { schema: "remits" })
|
@Entity("remit_transfer", { schema: "remits" })
|
||||||
export class RemitTransfer {
|
export class RemitTransfer {
|
||||||
@ -47,11 +48,65 @@ export class RemitTransfer {
|
|||||||
})
|
})
|
||||||
amount: string;
|
amount: string;
|
||||||
|
|
||||||
|
// new field
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 64,
|
||||||
|
unique: false,
|
||||||
|
})
|
||||||
|
sender_name: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 64,
|
||||||
|
unique: false,
|
||||||
|
})
|
||||||
|
sender_id_type: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 64,
|
||||||
|
unique: false,
|
||||||
|
})
|
||||||
|
sender_id_number: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "text",
|
||||||
|
unique: false,
|
||||||
|
})
|
||||||
|
sender_id_file: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 64,
|
||||||
|
unique: false,
|
||||||
|
})
|
||||||
|
sender_country: string;
|
||||||
|
|
||||||
@Column({
|
@Column({
|
||||||
nullable: false,
|
nullable: false,
|
||||||
length: 64,
|
length: 64,
|
||||||
})
|
})
|
||||||
status: string;
|
status: string;
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 64,
|
||||||
|
})
|
||||||
|
transaction_fee: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 64,
|
||||||
|
})
|
||||||
|
allocation_bri_value: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 64,
|
||||||
|
})
|
||||||
|
allocation_partner_value: string;
|
||||||
|
|
||||||
@Column({
|
@Column({
|
||||||
nullable: false,
|
nullable: false,
|
||||||
length: 64,
|
length: 64,
|
||||||
@ -63,6 +118,19 @@ export class RemitTransfer {
|
|||||||
@CreateDateColumn()
|
@CreateDateColumn()
|
||||||
created_at: Date;
|
created_at: Date;
|
||||||
|
|
||||||
|
@Column({ type: "timestamp", nullable: true })
|
||||||
|
finalized_at: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 256,
|
||||||
|
unique: false,
|
||||||
|
})
|
||||||
|
finalized_by: string;
|
||||||
|
|
||||||
|
@Column({ nullable: true })
|
||||||
|
approved_at: Date;
|
||||||
|
|
||||||
@Column({ nullable: true })
|
@Column({ nullable: true })
|
||||||
@UpdateDateColumn()
|
@UpdateDateColumn()
|
||||||
updated_at: Date;
|
updated_at: Date;
|
||||||
|
|||||||
@ -30,6 +30,16 @@ export class RemitTopup {
|
|||||||
})
|
})
|
||||||
status: string;
|
status: string;
|
||||||
|
|
||||||
|
@Column({ type: "timestamp", nullable: true })
|
||||||
|
finalized_at: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 256,
|
||||||
|
unique: false,
|
||||||
|
})
|
||||||
|
finalized_by: string;
|
||||||
|
|
||||||
@Column()
|
@Column()
|
||||||
@CreateDateColumn()
|
@CreateDateColumn()
|
||||||
created_at: Date;
|
created_at: Date;
|
||||||
|
|||||||
31
src/index.ts
31
src/index.ts
@ -87,13 +87,15 @@ import { AssetInventoryDepreciationLog } from "./entity/asset_inventory_deprecia
|
|||||||
import { RemitOtp } from "./entity/remit_otp";
|
import { RemitOtp } from "./entity/remit_otp";
|
||||||
import { RemitPartnerUser } from "./entity/remit_partner_users";
|
import { RemitPartnerUser } from "./entity/remit_partner_users";
|
||||||
import { RemitPartner } from "./entity/remit_partners";
|
import { RemitPartner } from "./entity/remit_partners";
|
||||||
|
import { RemitPartnerTransaction } from "./entity/remit_partner_transactions";
|
||||||
|
import { RemitPartnerAllocation } from "./entity/remit_partner_allocations";
|
||||||
import { RemitRegion } from "./entity/remit_region";
|
import { RemitRegion } from "./entity/remit_region";
|
||||||
import { RemitTransfer } from "./entity/remit_tansfer";
|
import { RemitTransfer } from "./entity/remit_tansfer";
|
||||||
import { RemitTopup } from "./entity/remit_topup";
|
import { RemitTopup } from "./entity/remit_topup";
|
||||||
import { RemitMutation } from "./entity/remit_mutation";
|
import { RemitMutation } from "./entity/remit_mutation";
|
||||||
import { RemitBank } from "./entity/remit_bank";
|
import { RemitBank } from "./entity/remit_bank";
|
||||||
import { RemitConfigTransaction } from "./entity/remit_config_transaction";
|
import { RemitConfigTransaction } from "./entity/remit_config_transactions";
|
||||||
import { RemitConfigAllocation } from "./entity/remit_config_allocation";
|
import { RemitConfigAllocation } from "./entity/remit_config_allocations";
|
||||||
import { RemitConfigKurs } from "./entity/remit_config_kurs";
|
import { RemitConfigKurs } from "./entity/remit_config_kurs";
|
||||||
|
|
||||||
import { BrizziBatchStatus, BrizziCardStatus, BrizziHistoryActvity, BrizziHistoryType, BrizziHistoryRemarks } from "./types/brizzi";
|
import { BrizziBatchStatus, BrizziCardStatus, BrizziHistoryActvity, BrizziHistoryType, BrizziHistoryRemarks } from "./types/brizzi";
|
||||||
@ -101,28 +103,7 @@ import { BrizziBatch } from "./entity/brizzi_batchs";
|
|||||||
import { BrizziCard } from "./entity/brizzi_cards";
|
import { BrizziCard } from "./entity/brizzi_cards";
|
||||||
import { BrizziHistory } from "./entity/brizzi_history";
|
import { BrizziHistory } from "./entity/brizzi_history";
|
||||||
|
|
||||||
import {
|
import { BrilinkMerchantStatus, BrilinkTerminalType, BrilinkTerminalCondition, BrilinkTerminalOnline, BrilinkBalanceType, BrilinkBalanceCode, BrilinkBalanceMutationType, BrilinkBalanceMutationActvity, BrilinkBalanceSourceType, BrilinkBalanceDestinationType, BrilinkBalanceMutationStatus, BrilinkTransactionType, BrilinkTransactionActivity, BrilinkTransactionStatus, BrilinkMerchantSettlementStatus, BrilinkTransactionCodePrefixType, BrilinkTransactionCodePrefixActivity, BrilinkBalanceMutationCodePrefixType, BrilinkBalanceMutationCodePrefixActvity, BrilinkBalanceTopupCodePrefix } from "./types/brilink";
|
||||||
BrilinkMerchantStatus,
|
|
||||||
BrilinkTerminalType,
|
|
||||||
BrilinkTerminalCondition,
|
|
||||||
BrilinkTerminalOnline,
|
|
||||||
BrilinkBalanceType,
|
|
||||||
BrilinkBalanceCode,
|
|
||||||
BrilinkBalanceMutationType,
|
|
||||||
BrilinkBalanceMutationActvity,
|
|
||||||
BrilinkBalanceSourceType,
|
|
||||||
BrilinkBalanceDestinationType,
|
|
||||||
BrilinkBalanceMutationStatus,
|
|
||||||
BrilinkTransactionType,
|
|
||||||
BrilinkTransactionActivity,
|
|
||||||
BrilinkTransactionStatus,
|
|
||||||
BrilinkMerchantSettlementStatus,
|
|
||||||
BrilinkTransactionCodePrefixType,
|
|
||||||
BrilinkTransactionCodePrefixActivity,
|
|
||||||
BrilinkBalanceMutationCodePrefixType,
|
|
||||||
BrilinkBalanceMutationCodePrefixActvity,
|
|
||||||
BrilinkBalanceTopupCodePrefix
|
|
||||||
} from "./types/brilink";
|
|
||||||
|
|
||||||
import { BrilinkMerchant } from "./entity/brilink_merchants";
|
import { BrilinkMerchant } from "./entity/brilink_merchants";
|
||||||
import { BrilinkMerchantUser } from "./entity/brilink_merchant_users";
|
import { BrilinkMerchantUser } from "./entity/brilink_merchant_users";
|
||||||
@ -244,6 +225,8 @@ export {
|
|||||||
RemitOtp,
|
RemitOtp,
|
||||||
RemitPartnerUser,
|
RemitPartnerUser,
|
||||||
RemitPartner,
|
RemitPartner,
|
||||||
|
RemitPartnerTransaction,
|
||||||
|
RemitPartnerAllocation,
|
||||||
RemitRegion,
|
RemitRegion,
|
||||||
RemitTransfer,
|
RemitTransfer,
|
||||||
RemitTopup,
|
RemitTopup,
|
||||||
|
|||||||
Reference in New Issue
Block a user