예제 #1
0
def _expecting_soon(case):
    return is_pregnant_mother(case) and get_edd(case) and _in_timeframe(case.edd, -30)
예제 #2
0
def _mother_due_in_window(case, days):
    get_visitduedate = lambda case: case.edd - dt.timedelta(days=days) + GRACE_PERIOD
    return is_pregnant_mother(case) and get_edd(case) and _in_last_month(get_visitduedate(case))
예제 #3
0
 def sortkey(self):
     return lambda case: get_edd(case) or dt.datetime.max.date()