fix empty category
This commit is contained in:
@@ -145,6 +145,7 @@ const buildUpdate = (): UpdateTransactionDTO => {
|
|||||||
categoryId: transactionCategory.value.id,
|
categoryId: transactionCategory.value.id,
|
||||||
comment: transactionComment.value,
|
comment: transactionComment.value,
|
||||||
amount: transactionAmount.value,
|
amount: transactionAmount.value,
|
||||||
|
fees: 0,
|
||||||
isDone: isDone.value,
|
isDone: isDone.value,
|
||||||
date: transactionDate.value
|
date: transactionDate.value
|
||||||
} as UpdateTransactionDTO
|
} as UpdateTransactionDTO
|
||||||
@@ -161,6 +162,7 @@ const buildCreate = (): CreateTransactionDTO => {
|
|||||||
categoryId: transactionCategory.value.id,
|
categoryId: transactionCategory.value.id,
|
||||||
comment: transactionComment.value,
|
comment: transactionComment.value,
|
||||||
amount: transactionAmount.value,
|
amount: transactionAmount.value,
|
||||||
|
fees: 0,
|
||||||
date: transactionDate.value
|
date: transactionDate.value
|
||||||
} as CreateTransactionDTO
|
} as CreateTransactionDTO
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ export interface CreateTransactionDTO {
|
|||||||
comment: string
|
comment: string
|
||||||
amount: number
|
amount: number
|
||||||
fees: number | null
|
fees: number | null
|
||||||
date: string
|
date: string | Date
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface UpdateTransactionDTO {
|
export interface UpdateTransactionDTO {
|
||||||
@@ -37,5 +37,5 @@ export interface UpdateTransactionDTO {
|
|||||||
amount: number
|
amount: number
|
||||||
fees: number | null
|
fees: number | null
|
||||||
isDone: boolean
|
isDone: boolean
|
||||||
date: string
|
date: string | Date
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user