@login_required
def overview(request):
    profile, created = Profile.objects.get_or_create(user=request.user)
    validated = False
    try:
        email = EmailValidation.objects.get(user=request.user).email
    except EmailValidation.DoesNotExist:
        email = request.user.email
        if email: validated = True

    fields = [{ 
        'name': f.name, 
        'verbose_name': f.verbose_name, 
        'value': getattr(profile, f.name)
    } for f in Profile._meta.fields if not (f in BaseProfile._meta.fields or f.name=='id')]

    template = "userprofile/profile/overview.html"
    data = { 'section': 'overview', 'GOOGLE_MAPS_API_KEY': GOOGLE_MAPS_API_KEY,
            'email': email, 'validated': validated, 'fields' : fields }
    signals.context_signal.send(sender=overview, request=request, context=data)
    return render_to_response(template, data, context_instance=RequestContext(request))
Main profile page
dataset/ETHPy150Open tualatrix/django-profile/userprofile/views.py/overview