Gitlab CSE Unil

forms.py 328 Bytes
Newer Older
Julien Furrer's avatar
Julien Furrer committed
1
2
3
4
5
6
7
8
9
10
# coding=utf-8
from __future__ import unicode_literals
from django import forms


class UploadImageFileForm(forms.Form):
    """
    This form is used to validate the image files submitted
    for upload
    """
Julien Furrer's avatar
Julien Furrer committed
11
    image_file = forms.ImageField(allow_empty_file=False)
12
    name = forms.CharField(max_length=125, required=False)