from enum import Enum from datetime import datetime from typing import List from app.schema.base import BaseModel class TransactionType(str, Enum): INCOME = "income" EXPENSE = "expense" class UserCreate(BaseModel): name: str email: str hashed_password: str class User(BaseModel): name: str email: str hashed_password: str is_deleted: bool = False transactions: "List[Transaction]" class Transaction(BaseModel): transaction_date: datetime category: str name_description: str amount: float type: TransactionType user: User