JourneyJoker/partners/forms.py
2021-10-28 09:26:17 +02:00

11 lines
408 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

from django.contrib.auth.forms import UserCreationForm
from django import forms
from .models import Establishment
class VerificationForm(forms.Form):
def get_choices():
for establishment in Establishment.objects.filter(verified=False):
yield ("%i" % establishment.id, "%i %s" % (establishment.id, establishment.name))
establishment = forms.ChoiceField(choices=get_choices)