diff --git a/backend/db/crud.py b/backend/db/crud.py index 62e470cb5091db82eefed71195ab7a5209a8de2c..be18e5a4ea90ec0456c4a79d0ec3891d40fde904 100644 --- a/backend/db/crud.py +++ b/backend/db/crud.py @@ -252,8 +252,11 @@ def get_restaurants(db: Session): restaurants = [] for place in places: - opening_hours = db.query(models.OpeningHours).filter( - models.OpeningHours.place == place.place, models.OpeningHours.day == weekday).all() + opening_hours = db.query( + models.OpeningHours).filter( + models.OpeningHours.place == place.place, + models.OpeningHours.day == weekday).order_by( + models.OpeningHours.open_time).all() opening_hours_formated = [ f"{row.open_time.strftime('%Hh%M')}-{row.close_time.strftime('%Hh%M')}" for row in opening_hours] timetable = "/".join(opening_hours_formated) diff --git a/frontend/src/styles/Comments.css b/frontend/src/styles/Comments.css index 1fdfc1e9098d2d040173f8b93c0f60601546ff3a..d52fe85b8f500b3991b1773e839b72127013b9d7 100644 --- a/frontend/src/styles/Comments.css +++ b/frontend/src/styles/Comments.css @@ -129,7 +129,7 @@ top: 0; height: 3rem; width: 3rem; - margin: 1rem; + margin: 0.5rem; padding: 0.5rem; border-radius: 5px; }