def field_dict(self, model):
        if self.field_names is None:
            return dict([(f.name, f) for f in model._meta.fields if isinstance(f, models.DateField)])
        else:
            return dict([(f.name, f) for f in model._meta.fields if isinstance(f, models.DateField) and f.name in self.field_names])
Helper function that returns a dictionary of all DateFields or
dataset/ETHPy150Open AppScale/appscale/AppServer/lib/django-1.5/django/contrib/databrowse/plugins/calendars.py/CalendarPlugin.field_dict