- Added schemas, services, and routers for PROSEC, RCG2, Regulaciones, REIT, RequisitoPrevio, TLCS, and Vehiculos modules. - Each module includes search and get by ID functionalities. - Integrated FastAPI routers for each module into the main SITAR router. - Ensured proper response models using Pydantic for data validation.
29 lines
973 B
Python
29 lines
973 B
Python
"""Requisito Previo Schemas"""
|
|
|
|
from typing import Optional
|
|
from pydantic import BaseModel, Field
|
|
|
|
|
|
class RequisitoPrevioResponse(BaseModel):
|
|
"""Requisitos previos"""
|
|
|
|
FRACCION: Optional[str] = Field(None, max_length=8)
|
|
DESCRIPCION: Optional[str] = Field(None, max_length=1999)
|
|
OBSERVACION: Optional[str] = Field(None, max_length=1999)
|
|
DOF: Optional[str] = Field(None, max_length=8)
|
|
VIGENCIA: Optional[str] = Field(None, max_length=8)
|
|
NUMEROACUERDO: Optional[int] = None
|
|
NUMEROCRITERIO: Optional[int] = None
|
|
NUMEROFORMATO: Optional[int] = None
|
|
NUMEROINSTRUCCIONES: Optional[int] = None
|
|
HISTORICO: Optional[str] = Field(None, max_length=2000)
|
|
NOTA: Optional[str] = Field(None, max_length=5000)
|
|
PERMISO: Optional[str] = Field(None, max_length=2)
|
|
IMPO: Optional[int] = None
|
|
EXPO: Optional[int] = None
|
|
NICO: Optional[str] = Field("", max_length=2)
|
|
SYSID: int
|
|
|
|
class Config:
|
|
from_attributes = True
|