diff --git a/packages/server/src/models/CashflowTransaction.ts b/packages/server/src/models/CashflowTransaction.ts index 2184d1434..d4743d4ce 100644 --- a/packages/server/src/models/CashflowTransaction.ts +++ b/packages/server/src/models/CashflowTransaction.ts @@ -7,8 +7,12 @@ import { } from '@/services/Cashflow/utils'; import AccountTransaction from './AccountTransaction'; import { CASHFLOW_DIRECTION } from '@/services/Cashflow/constants'; - +import { getTransactionTypeLabel } from '@/utils/transactions-types'; export default class CashflowTransaction extends TenantModel { + transactionType: string; + amount: number; + exchangeRate: number; + /** * Table name. */ @@ -55,9 +59,10 @@ export default class CashflowTransaction extends TenantModel { /** * Transaction type formatted. + * @returns {string} */ get transactionTypeFormatted() { - return AccountTransaction.getReferenceTypeFormatted(this.transactionType); + return getTransactionTypeLabel(this.transactionType); } get typeMeta() {