newmediamonitoring1/polls/forms.py

27 lines
519 B
Python

from django import forms
from dashboard.models import Weixin, Weibo, Toutiao, Qita
class WeixinImageForm(forms.ModelForm):
class Meta:
model = Weixin
fields = ['image', ]
class WeiboImageForm(forms.ModelForm):
class Meta:
model = Weibo
fields = ['image', ]
class ToutiaoImageForm(forms.ModelForm):
class Meta:
model = Toutiao
fields = ['image', ]
class QitaImageForm(forms.ModelForm):
class Meta:
model = Qita
fields = ['image', ]