PonyConf/proposals/forms.py
Guilhem Saurel d9b3846cf1 Various Stuffs
- unified orga forms
- unified staff / orga | util / mixin / filter
- moved a signal into its signals.py
- profile edition now edits User / Profile / Participation
- topic can be edited
- orga can set topics reviewers
- removed view list-talks-by-speaker (his talks appears on his page)
- everybody can see topics (template show more stuff the more permissions you have)
2016-07-05 01:16:33 +02:00

15 lines
497 B
Python

from django.forms import CheckboxSelectMultiple
from django.forms.models import modelform_factory
from proposals.models import Talk, Topic
__all__ = ['TalkForm', 'TopicForm', 'TopicOrgaForm']
TalkForm = modelform_factory(Talk, fields=['title', 'description', 'topics', 'event', 'speakers'],
widgets={'topics': CheckboxSelectMultiple()})
TopicForm = modelform_factory(Topic, fields=['name'])
TopicOrgaForm = modelform_factory(Topic, fields=['name', 'reviewers'])