21 lines
476 B
Python
21 lines
476 B
Python
from pydantic import BaseModel, Field
|
|
from typing import Optional
|
|
from enum import IntEnum
|
|
|
|
|
|
class TiersList(BaseModel):
|
|
"""Requête de listage des tiers"""
|
|
|
|
type_tiers: Optional[str] = Field(
|
|
None, description="Type: client, fournisseur, prospect, all"
|
|
)
|
|
filtre: str = Field("", description="Filtre sur code ou intitulé")
|
|
|
|
|
|
class TypeTiers(IntEnum):
|
|
"""CT_Type - Type de tiers"""
|
|
|
|
CLIENT = 0
|
|
FOURNISSEUR = 1
|
|
SALARIE = 2
|
|
AUTRE = 3
|