Exemplo n.º 1
0
def get_label_thumbnail_upload_path(instance, filename):
    """
    Generate a destination path (on the server filesystem) for
    an upload of a label's representative thumbnail image.
    """
    return generate_random_filename(settings.LABEL_THUMBNAIL_DIR, filename, numOfChars=10)
Exemplo n.º 2
0
def get_original_image_upload_path(instance, filename):
    """
    Generate a destination path (on the server filesystem) for
    a data-image upload.
    """
    return generate_random_filename(settings.ORIGINAL_IMAGE_DIR, filename, numOfChars=10)