- change type data to bigint
This commit is contained in:
parent
5367541079
commit
1ea59d2254
|
@ -13,11 +13,7 @@ export class COA extends BaseModel {
|
|||
@Column('text')
|
||||
balanceType: balanceType;
|
||||
|
||||
@Column({
|
||||
type: 'numeric',
|
||||
precision: 20,
|
||||
scale: 2,
|
||||
})
|
||||
@Column()
|
||||
amount: number;
|
||||
|
||||
@Column({
|
||||
|
|
|
@ -10,11 +10,7 @@ export class Transactions extends BaseModel {
|
|||
@Column()
|
||||
amount: number;
|
||||
|
||||
@Column({
|
||||
type: 'numeric',
|
||||
precision: 20,
|
||||
scale: 2,
|
||||
})
|
||||
@Column()
|
||||
balance_remaining: number;
|
||||
|
||||
@Column()
|
||||
|
|
|
@ -1395,7 +1395,7 @@ export class TransactionService {
|
|||
dataTransaction.callback_json = callback;
|
||||
dataTransaction.failed_reason = `Trx ${product.code} ke ${dataTransaction.destination} gagal`;
|
||||
dataTransaction.balance_remaining =
|
||||
Math.floor(coaAccount.amount) + dataTransaction.amount;
|
||||
coaAccount.amount + dataTransaction.amount;
|
||||
|
||||
const coaInventory = await this.coaService.findByName(
|
||||
`${coaType[coaType.INVENTORY]}-${product.supplier.code}`,
|
||||
|
|
Loading…
Reference in New Issue
Block a user