add more endpoints

This commit is contained in:
Michi 2025-04-22 10:38:38 +02:00
parent 55862ba54d
commit 4af8161a11
3 changed files with 70 additions and 7 deletions

View file

@ -71,4 +71,7 @@ def get_recent_sensor_data(db: Session, client_id: int, start_date: datetime, en
SensorData.timestamp >= start_date,
SensorData.timestamp < end_date, # Das end_date sollte exklusiv sein
SensorData.clientid == client_id
).all()
).all()
def get_all_clients(db: Session) -> List[Client]:
return db.query(Client).all()