Вписываю в консоль
py manage.py makemigrations
и выдает ошибку
Django: TypeError: 'DeclarativeFieldsMetaclass' object is not iterable.
forms.pyfrom django import forms
class Accounts(forms.Form):
email = forms.EmailField(max_length=100)
password = forms.CharField(max_length=100)
views.pyfrom django.shortcuts import render
from enter.forms import Accounts
def entering(request):
if request.method == 'POST':
email = request.POST['emails']
passw = request.POST['passwords']
form = Accounts(email=email, password=passw)
if form.is_valid():
form.save()
else:
form = Accounts()
return render(request, 'enter/enter.html', {'datas': datas})
Как можно решить данную проблему?
При запуске сервера тоже самое.