Django allauth中Social Account/signup.html表单中的邮箱字段使用的模板变量是什么?
在allauth/templates/socialaccount/signup.html
中有这样一种形式:
<form class="signup" id="signup_form" method="post" action="{% url 'socialaccount_signup' %}">
{% csrf_token %}
{{ form.as_p }}
{% if redirect_field_value %}
<input type="hidden" name="{{ redirect_field_name }}" value="{{ redirect_field_value }}" />
{% endif %}
<button type="submit">{% trans "Sign Up" %} »</button>
</form>
为了设置字段的样式并删除标签,我想删除表单并使用我自己的输入域.我可以在浏览器中提取判断From的标记,但邮箱输入字段中的value=
已经填充了我的邮箱地址,并且我看不到它使用的变量.
你能帮我搬一下吗?
我试图在源代码中找到它,但我不能理解它.它似乎在表单中呈现了SocialAccount模型.从value="{{ email }}"
到value="{{ socialaccount.get_social_account().user.get_email() }}"
,我什么都试过了.