django-web-galleries/django_web_galleries/web_galleries/forms.py

13 lines
326 B
Python

from django import forms
from django.utils.translation import gettext as _
from .models import Image
class ImageUploadForm(forms.ModelForm):
class Meta:
model = Image
fields = ['description', 'image_file', 'private', 'title']
labels = {
'private': 'Make this image private'
}