Files
plantillas-proyectos/backend/api/v1/modules/a76/items/series/schemas.py
2026-03-11 09:52:15 -06:00

28 lines
955 B
Python

from typing import Optional
from pydantic import BaseModel, Field, ConfigDict
class SerieBase(BaseModel):
row: Optional[int] = Field(None, description="Serie row number (RENGLON)")
serial_numbers: Optional[str] = Field(None, max_length=50, description="Serial number (SERIEEXPO)")
model: Optional[str] = Field(None, max_length=50, description="Model (MODELOEXPO)")
sub_model: Optional[str] = Field(None, max_length=50, description="Sub model (SUBMODELOEXPO)")
brand: Optional[str] = Field(None, max_length=50, description="Brand (MARCA)")
expo_brad: Optional[str] = Field(None, max_length=50, description="Expo brand (MARCAEXPO)")
number_id: Optional[str] = Field(None, max_length=25, description="Number ID (NUMIDEXPO)")
class SerieCreate(SerieBase):
pass
class SerieUpdate(SerieBase):
pass
class SerieResponse(SerieBase):
id: int
line_item_id: int
model_config = ConfigDict(from_attributes=True)