code: def quarter(d):
      
      from django_toolkit.datetime_util import quarter as datetime_quarter
      first_date, last_date = datetime_quarter(datetime(d.year, d.month, d.day))
      return first_date.date(), last_date.date()
docs: Return start/stop datetime for the quarter as defined by dt.