add support for querying buying listings as well as by max price
This commit is contained in:
parent
ba4a95825b
commit
69d15e9a16
5 changed files with 95 additions and 31 deletions
|
|
@ -6,6 +6,7 @@ import enum
|
|||
import json
|
||||
from pathlib import Path
|
||||
from typing import Any, Dict, List
|
||||
from pydantic import BaseModel
|
||||
from rec import routing
|
||||
from sqlmodel import JSON, SQLModel, Field, String
|
||||
|
||||
|
|
@ -230,7 +231,7 @@ class ListingType(enum.StrEnum):
|
|||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class QueryParameters:
|
||||
class QueryParameters(BaseModel):
|
||||
listing_type: ListingType
|
||||
min_bedrooms: int = 1
|
||||
max_bedrooms: int = 999
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue