Exemple #1
0
 def get_all_future_bookings(self):
     yesterday_at_midnight = datetime.combine(date.today(), time())
     all_future_bookings = Booking.query(
         Booking.provider == self.key,
         Booking.datetime >= yesterday_at_midnight).order(
             Booking.datetime).fetch()
     return all_future_bookings
Exemple #2
0
 def get_future_confirmed_bookings(self):
     yesterday_at_midnight = datetime.combine(date.today(), time())
     future_confirmed_bookings = Booking.query(
         Booking.provider == self.key,
         Booking.datetime >= yesterday_at_midnight,
         Booking.confirmed == True).order(Booking.datetime).fetch()
     return future_confirmed_bookings
Exemple #3
0
 def get_all_future_bookings(self):
     yesterday_at_midnight = datetime.combine(date.today(), time())
     all_future_bookings = Booking.query(Booking.provider == self.key, Booking.datetime >= yesterday_at_midnight).order(Booking.datetime).fetch()
     return all_future_bookings
Exemple #4
0
 def get_future_confirmed_bookings(self):
     yesterday_at_midnight = datetime.combine(date.today(), time())
     future_confirmed_bookings = Booking.query(Booking.provider == self.key, Booking.datetime >= yesterday_at_midnight, Booking.confirmed==True).order(Booking.datetime).fetch()
     return future_confirmed_bookings
Exemple #5
0
 def get_future_unconfirmed_bookings(self):
     return Booking.query(Booking.patient == self.key,
                          Booking.datetime >= datetime.now(),
                          Booking.confirmed == False).fetch()
Exemple #6
0
 def get_future_bookings(self):
     return Booking.query(Booking.patient == self.key,
                          Booking.datetime >= datetime.now()).fetch()
Exemple #7
0
 def get_bookings(self):
     return Booking.query(Booking.patient == self.key).fetch()