sqlite에서 MongoDB로 전환하고 Django MongoDB Engine에 대한 모든 설정/구성 설정을 따랐습니다. 지금은 views.py에서 adduser 명령의 방법에서 HTTP 응답을 반환하여 사용자를 추가 갈 때 : DatabaseError at /adduser relation "auth_user" does not exist
내장 된 Django 인증/사용자 모델을 Mongodb와 함께 사용
자연스럽게 관계가 존재하지 않습니다
def adduser(request):
username = request.POST['username']
password = request.POST['password']
u = User.objects.create_user(username, request.POST['email'], password)
u.save()
a = Accounts(user=u)
p = Passwords(user=u)
a.save()
p.save()
user = authenticate(username=username, password=password)
if user is not None and user.is_active:
auth.login(request, user)
return HttpResponseRedirect("/%s/" %u.id)
else:
return HttpResponseRedirect("/account/invalid/")
이 오류가 내가 얻을 수있다 MongoDB NoSQL 이후. 인증 시스템이 지원되지 않습니까? 아니면 Mongo-engine이 더 나은 솔루션을 가지고 있습니까? Postgre로 이동해야할까요? (sqlite는 동시 사용자를 처리 할 수 없으므로 실행 가능한 옵션이 아닙니다.)
나는 this 질문을 보았습니다.하지만 1 년 전의 일 이었기 때문에 MongoDB는 올해 많은 인기를 얻었습니다.
http://django-mongodb.org/ – diegueus9