Automated Action be0ae5f3b3 Implement small business inventory management system
- Create project structure with FastAPI and SQLAlchemy
- Implement database models for items, categories, suppliers, and stock movements
- Add CRUD operations for all models
- Configure Alembic for database migrations
- Create RESTful API endpoints for inventory management
- Add health endpoint for system monitoring
- Update README with setup and usage instructions

generated with BackendIM... (backend.im)
2025-05-12 16:23:23 +00:00

24 lines
533 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
is_active: Optional[bool] = None
class CategoryResponse(CategoryBase):
id: int
is_active: bool
created_at: datetime
updated_at: datetime
class Config:
from_attributes = True