Skip to content

Commit

Permalink
bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
WSL0809 committed Jun 20, 2024
1 parent 3073fc3 commit 53863e7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/get_all_clients.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def get_clients(db: Session, name: Optional[str], page: int, limit: int):
base_query = """
SELECT c.id, c.status, c.name, c.tel, c.age, c.scheduled_date, c.check_in_date, c.hospital_for_childbirth,
c.contact_name, c.contact_tel, c.meal_plan_id, c.recovery_plan_id, c.mode_of_delivery,
c.assigned_baby_nurse, c.room, c.due_date, c.transaction_price,
c.assigned_baby_nurse, c.room, c.due_date, c.transaction_price, c.id_number,
COALESCE(json_agg(b.*) FILTER (WHERE b.baby_id IS NOT NULL), '[]') AS babies
FROM client c
LEFT JOIN baby b ON c.id = b.client_id
Expand Down

0 comments on commit 53863e7

Please sign in to comment.