17 lines
623 B
Python
17 lines
623 B
Python
from sqlalchemy import Integer, String, Text
|
|
from sqlalchemy.orm import Mapped, mapped_column
|
|
|
|
from api.v1.common.base_models import TenantScopedMixin, TimestampMixin
|
|
from core.database import Base
|
|
|
|
|
|
class Item(Base, TenantScopedMixin, TimestampMixin):
|
|
"""Modelo de ejemplo — renombra y ajusta a tu entidad de negocio."""
|
|
|
|
__tablename__ = "example_items"
|
|
__table_args__ = {"schema": "public"}
|
|
|
|
id: Mapped[int] = mapped_column(Integer, primary_key=True, index=True)
|
|
name: Mapped[str] = mapped_column(String(255), nullable=False)
|
|
description: Mapped[str | None] = mapped_column(Text, nullable=True)
|