简体   繁体   English

Django注册Redux自定义注册表

[英]Django Registration Redux custom registration form

I'm really confused how I can change the registration_form to ask the users about their first and last name. 我真的很困惑如何更改registration_form以询问用户他们的名字和姓氏。
I think I need to manipulate subclass RegistrationView from registration.backends.simple.views but I don't know how to do this to show first and last name in registration form. 我想我需要从registration.backends.simple.views操作子类RegistrationView ,但我不知道如何在注册表单中显示名字和姓氏

You should be able to sub-class RegistrationForm and add the fields you want. 您应该能够对RegistrationForm进行子类化并添加所需的字段。

Look at the source for the default forms on how to do so: 请查看默认表单的来源,了解如何执行此操作:

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM