minor: >0 check on org ids in bodies
This commit is contained in:
parent
7d109f0f73
commit
e4559b8ee4
1 changed files with 2 additions and 2 deletions
|
|
@ -8,7 +8,7 @@ Models follow the nomenclature of:
|
||||||
"""
|
"""
|
||||||
from typing import Optional
|
from typing import Optional
|
||||||
|
|
||||||
from pydantic import EmailStr, ConfigDict
|
from pydantic import EmailStr, ConfigDict, Field
|
||||||
|
|
||||||
from src.schemas import CustomBaseModel
|
from src.schemas import CustomBaseModel
|
||||||
from src.contact.schemas import ContactModel
|
from src.contact.schemas import ContactModel
|
||||||
|
|
@ -23,7 +23,7 @@ class Questionnaire(CustomBaseModel):
|
||||||
question_three: Optional[str] = None
|
question_three: Optional[str] = None
|
||||||
|
|
||||||
class OrgIDMixin(CustomBaseModel):
|
class OrgIDMixin(CustomBaseModel):
|
||||||
organisation_id: int
|
organisation_id: int = Field(gt=0)
|
||||||
|
|
||||||
|
|
||||||
class OrgPostOrgRequest(CustomBaseModel):
|
class OrgPostOrgRequest(CustomBaseModel):
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue