def mk_upload_to(field_fn):
    def upload_to(instance, filename):
        base, slug = instance.get_upload_meta()
        time_now = int(time())
        return '%(base)s/%(slug)s/%(time_now)s_%(field_fn)s' % dict(
            time_now=time_now, slug=slug, base=base, field_fn=field_fn)
    return upload_to
upload_to builder for file upload fields
dataset/ETHPy150Open lmorchard/badg.us/badgus/profiles/models.py/mk_upload_to