Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
137 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,23 @@ | ||
certifi==2019.6.16 | ||
chardet==3.0.4 | ||
defusedxml==0.6.0 | ||
Django==2.1 | ||
django-allauth==0.39.1 | ||
django-ckeditor==5.6.1 | ||
django-js-asset==1.2.2 | ||
django-model-utils==3.1.2 | ||
django-mptt==0.10.0 | ||
django-notifications-hq==1.5.0 | ||
django-password-reset==2.0 | ||
django-taggit==0.23.0 | ||
idna==2.8 | ||
jsonfield==2.0.2 | ||
Markdown==2.6.11 | ||
oauthlib==3.0.1 | ||
Pillow==5.3.0 | ||
Pygments==2.2.0 | ||
python3-openid==3.1.0 | ||
pytz==2018.5 | ||
requests==2.22.0 | ||
requests-oauthlib==1.2.0 | ||
urllib3==1.25.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
{% extends "base.html" %} | ||
|
||
{% load i18n %} | ||
{% load account socialaccount %} | ||
|
||
{% block title %}登录{% endblock %} | ||
|
||
{% block content %} | ||
<div class="container"> | ||
<div class="row"> | ||
<div class="col-12"> | ||
<br> | ||
|
||
{% get_providers as socialaccount_providers %} | ||
|
||
{% if socialaccount_providers %} | ||
<p> | ||
{% blocktrans with site.name as site_name %}请登录已有本地账号或<a href="{{ signup_url }}">注册</a>新账号。 | ||
也可以通过第三方登录:{% endblocktrans %} | ||
</p> | ||
|
||
<div class="socialaccount_ballot"> | ||
<h5 class="mb-2 mt-4">第三方登录:</h5> | ||
<ul class="socialaccount_providers"> | ||
{% include "socialaccount/snippets/provider_list.html" with process="login" %} | ||
</ul> | ||
<h5 class="mb-2 mt-4">本地登录:</h5> | ||
</div> | ||
|
||
{% include "socialaccount/snippets/login_extra.html" %} | ||
|
||
{% else %} | ||
<p>{% blocktrans %}If you have not created an account yet, then please | ||
<a href="{{ signup_url }}">sign up</a> first.{% endblocktrans %}</p> | ||
{% endif %} | ||
<div class="col-6"> | ||
<form class="login" id="login_form" method="POST" action="{% url 'account_login' %}"> | ||
{% csrf_token %} | ||
<div class="form-group"> | ||
<label for="id_login">账号: </label> | ||
<input type="text" name="login" placeholder="请输入用户名或Email" autofocus="autofocus" required | ||
id="id_login" class="form-control" /> | ||
<small class="form-text text-muted ml-1"> | ||
还没有账号? | ||
<a href="{% url 'account_signup' %}" style="color: cornflowerblue; "> | ||
注册新账号 | ||
</a> | ||
</small> | ||
</div> | ||
<div class="form-group mb-1"> | ||
<label for="id_password"> | ||
密码: | ||
</label> | ||
<input type="password" name="password" placeholder="请输入密码" required id="id_password" | ||
class="form-control" /> | ||
<small class="form-text text-muted ml-1"> | ||
<a class="secondaryAction layui-text" href="{% url 'account_reset_password' %}"> | ||
忘记密码? | ||
</a> | ||
</small> | ||
</div> | ||
<div class="custom-control custom-checkbox mb-2"> | ||
<input type="checkbox" name="remember" id="id_remember" checked class="custom-control-input" /> | ||
<label for="id_remember" class="custom-control-label"> | ||
保持登录 | ||
</label> | ||
</div> | ||
<button class="primaryAction btn btn-primary" type="submit" hidden id="submit_login">确认</button> | ||
<button class="primaryAction btn btn-primary" type="button" id="on_submit_login">确认</button> | ||
</form> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters