2021-04-17 18:35:29 +00:00
|
|
|
|
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))
|
|
|
|
|
|
2021-10-28 07:26:17 +00:00
|
|
|
|
establishment = forms.ChoiceField(choices=get_choices)
|