Exemple #1
0
 def _process(self, room_ids, start_dt, last_reservation_id, my_bookings, limit):
     start_dt = start_dt or datetime.combine(date.today(), time(0, 0))
     booked_for_user = session.user if my_bookings else None
     bookings, rows_left = get_active_bookings(limit=limit,
                                               start_dt=start_dt,
                                               last_reservation_id=last_reservation_id,
                                               room_ids=room_ids,
                                               booked_for_user=booked_for_user)
     return jsonify(bookings=serialize_occurrences(bookings), rows_left=rows_left)
Exemple #2
0
 def _process(self, room_ids, start_dt, last_reservation_id, my_bookings, limit):
     start_dt = start_dt or datetime.combine(date.today(), time(0, 0))
     booked_for_user = session.user if my_bookings else None
     bookings, rows_left = get_active_bookings(limit=limit,
                                               start_dt=start_dt,
                                               last_reservation_id=last_reservation_id,
                                               room_ids=room_ids,
                                               booked_for_user=booked_for_user)
     return jsonify(bookings=serialize_occurrences(bookings), rows_left=rows_left)