# generated by datamodel-codegen:
#   filename:  has_default_value.json
#   timestamp: 2019-07-26T00:00:00+00:00

from __future__ import annotations

from enum import Enum

from pydantic import BaseModel, Field, RootModel


class TeamType(Enum):
    Department = 'Department'
    Division = 'Division'
    BusinessUnit = 'BusinessUnit'
    Organization = 'Organization'


class ID(RootModel[str]):
    root: str = 'abc'


class Pet(BaseModel):
    name: str | None = None


class Family(RootModel[list[ID]]):
    root: list[ID] = Field(['abc', 'efg'], validate_default=True)


class FamilyPets(RootModel[list[Pet]]):
    root: list[Pet] = Field(
        [{'name': 'taro'}, {'name': 'shiro'}], validate_default=True
    )


class Person(BaseModel):
    id: ID | None = Field('abc', validate_default=True)
    user: Pet | None = None
    firstName: str | None = Field(None, description="The person's first name.")
    team: TeamType | None = 'Department'
    anotherTeam: TeamType | None = 'Department'
    Family_1: Family | None = Field(None, alias='Family')
    FamilyPets_1: FamilyPets | None = Field(None, alias='FamilyPets')
