Automated Action becbb01753 Implement small business inventory system with FastAPI and SQLite
- Set up project structure for FastAPI application
- Create database models for items, categories, suppliers, and transactions
- Set up Alembic for database migrations
- Implement API endpoints for all entities
- Add authentication with JWT tokens
- Add health check endpoint
- Create comprehensive README with documentation
2025-06-12 11:24:38 +00:00

30 lines
521 B
Python

from pydantic import BaseModel
from typing import Optional
from datetime import datetime
class CategoryBase(BaseModel):
name: str
description: Optional[str] = None
class CategoryCreate(CategoryBase):
pass
class CategoryUpdate(BaseModel):
name: Optional[str] = None
description: Optional[str] = None
class CategoryInDBBase(CategoryBase):
id: int
created_at: datetime
updated_at: datetime
class Config:
from_attributes = True
class Category(CategoryInDBBase):
pass