diff --git a/api/get_all_rooms.py b/api/get_all_rooms.py index 9e9c349..c863afd 100644 --- a/api/get_all_rooms.py +++ b/api/get_all_rooms.py @@ -30,6 +30,8 @@ class GetAllRoomsResp(BaseModel): meal_plan_seller: Union[Dict, str, None] recovery_plan_seller: Union[Dict, str, None] maintenance_list: Union[dict, None] + scheduled_date: Union[str, None] + check_in_date: Union[str, None] @router.get("/get_all_rooms") def get_all_room_info(current_user: User = Depends(get_current_active_user), db: Session = Depends(get_db)): @@ -40,6 +42,8 @@ def get_all_room_info(current_user: User = Depends(get_current_active_user), db: client.name AS name, client.meal_plan_seller AS meal_plan_seller, client.recovery_plan_seller AS recovery_plan_seller, + client.scheduled_date AS scheduled_date, + client.check_in_date AS check_in_date, baby_nurse.name AS baby_nurse_name, meal_plan.details AS meal_plan_details, meal_plan.duration AS meal_plan_duration, diff --git a/api/reserve.py b/api/reserve.py index 25afb81..b1a82fe 100644 --- a/api/reserve.py +++ b/api/reserve.py @@ -1,4 +1,6 @@ import json + +from datetime import datetime from typing import Optional, Union, Any, Dict from fastapi import APIRouter, Depends, HTTPException @@ -25,7 +27,7 @@ class ReserveRecv(BaseModel): tel: str age: int scheduled_date: str - check_in_date: str + check_in_date: Union[str, None] = None hospital_for_childbirth: str contact_name: str contact_tel: str