mirror of
https://github.com/felipegcoutinho/openmonetis.git
synced 2026-05-09 11:01:45 +00:00
refactor: atualiza transacoes dashboard e relatorios
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
import type {
|
||||
AntecipacaoParcela,
|
||||
Categoria,
|
||||
Lancamento,
|
||||
Pagador,
|
||||
Category,
|
||||
InstallmentAnticipation,
|
||||
Payer,
|
||||
Transaction,
|
||||
} from "@/db/schema";
|
||||
|
||||
/**
|
||||
@@ -18,17 +18,17 @@ export type EligibleInstallment = {
|
||||
currentInstallment: number | null;
|
||||
installmentCount: number | null;
|
||||
paymentMethod: string;
|
||||
categoriaId: string | null;
|
||||
pagadorId: string | null;
|
||||
categoryId: string | null;
|
||||
payerId: string | null;
|
||||
};
|
||||
|
||||
/**
|
||||
* Antecipação com dados completos
|
||||
*/
|
||||
export type InstallmentAnticipationWithRelations = AntecipacaoParcela & {
|
||||
lancamento: Lancamento;
|
||||
pagador: Pagador | null;
|
||||
categoria: Categoria | null;
|
||||
export type InstallmentAnticipationWithRelations = InstallmentAnticipation & {
|
||||
transaction: Transaction;
|
||||
payer: Payer | null;
|
||||
category: Category | null;
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -39,8 +39,8 @@ export type CreateAnticipationInput = {
|
||||
installmentIds: string[];
|
||||
anticipationPeriod: string;
|
||||
discount?: number;
|
||||
pagadorId?: string;
|
||||
categoriaId?: string;
|
||||
payerId?: string;
|
||||
categoryId?: string;
|
||||
note?: string;
|
||||
};
|
||||
|
||||
|
||||
@@ -1,24 +1,24 @@
|
||||
import type {
|
||||
LancamentoItem,
|
||||
SelectOption,
|
||||
TransactionItem,
|
||||
} from "@/features/transactions/components/types";
|
||||
|
||||
export type CalendarEvent =
|
||||
| {
|
||||
id: string;
|
||||
type: "lancamento";
|
||||
type: "transaction";
|
||||
date: string;
|
||||
lancamento: LancamentoItem;
|
||||
transaction: TransactionItem;
|
||||
}
|
||||
| {
|
||||
id: string;
|
||||
type: "boleto";
|
||||
date: string;
|
||||
lancamento: LancamentoItem;
|
||||
transaction: TransactionItem;
|
||||
}
|
||||
| {
|
||||
id: string;
|
||||
type: "cartao";
|
||||
type: "card";
|
||||
date: string;
|
||||
card: {
|
||||
id: string;
|
||||
@@ -47,12 +47,12 @@ export type CalendarDay = {
|
||||
};
|
||||
|
||||
export type CalendarFormOptions = {
|
||||
pagadorOptions: SelectOption[];
|
||||
splitPagadorOptions: SelectOption[];
|
||||
defaultPagadorId: string | null;
|
||||
contaOptions: SelectOption[];
|
||||
cartaoOptions: SelectOption[];
|
||||
categoriaOptions: SelectOption[];
|
||||
payerOptions: SelectOption[];
|
||||
splitPayerOptions: SelectOption[];
|
||||
defaultPayerId: string | null;
|
||||
accountOptions: SelectOption[];
|
||||
cardOptions: SelectOption[];
|
||||
categoryOptions: SelectOption[];
|
||||
estabelecimentos: string[];
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user