- templates/app now carries the vet server (parents/pets/treatments/vets/appointments) - added domain/jobs slice with /jobs OpenAPI paths and Job schema (x- extensions) - added pipelines/shared scaffold (loader, ports, registry) and the appointment_reminder family; worker.py dispatches jobs by kind - wired init.py, config.py worker knobs, .env.example, docker-compose worker - unit tests for jobs routes, the pipeline family and worker dispatch (12 passing)
38 lines
1.1 KiB
Python
38 lines
1.1 KiB
Python
"""# Summary
|
|
|
|
Pets domain — animals owned by parents and treated in appointments.
|
|
"""
|
|
from typing import Literal
|
|
|
|
from pydantic import BaseModel
|
|
|
|
from domain.parents.models import Metadata
|
|
|
|
|
|
class Pet(BaseModel):
|
|
"""A pet patient.
|
|
|
|
Attributes:
|
|
id (int | None): Server-assigned identifier. Defaults to None.
|
|
name (str): Name of the pet.
|
|
species (str): Type of animal (dog, cat, bird).
|
|
age (int | None): Age in years. Defaults to None.
|
|
weight (float | None): Weight in kilograms. Defaults to None.
|
|
birthDate (str | None): ISO date of birth. Defaults to None.
|
|
photo (str | None): Stored photo path after upload. Defaults to None.
|
|
parents (list[dict]): Embedded parent objects (or bare ids on input).
|
|
metadata (Metadata | None): Presentation metadata. Defaults to None.
|
|
"""
|
|
|
|
id: int | None = None
|
|
name: str
|
|
species: Literal["dog", "cat", "bird"]
|
|
age: int | None = None
|
|
weight: float | None = None
|
|
birthDate: str | None = None
|
|
photo: str | None = None
|
|
parents: list[dict] = []
|
|
metadata: Metadata | None = None
|
|
|
|
model_config = {"extra": "ignore"}
|