diff options
author | prathamesh | 2016-07-08 10:45:38 +0530 |
---|---|---|
committer | prathamesh | 2016-07-09 00:12:17 +0530 |
commit | 19f4c7b95bf32d0cf581274d947bdc9120c2e8f2 (patch) | |
tree | cc1efef7893be898e7e675a6073ba1e015b3b12c /yaksh/templates | |
parent | 41b4b7607d8ea6856a8b397d4c9e5bb9edea0b77 (diff) | |
download | online_test-19f4c7b95bf32d0cf581274d947bdc9120c2e8f2.tar.gz online_test-19f4c7b95bf32d0cf581274d947bdc9120c2e8f2.tar.bz2 online_test-19f4c7b95bf32d0cf581274d947bdc9120c2e8f2.zip |
oauth implemented
User can login via google and facebook.
If user logs in from google and then later the same user
logs in from facebook, then he will be considered as the same user if
the email registered on facebook is of gmail.
User profile will be created when user logs in via facebook or google.
In yaksh pipeline, user.py is used to create profile. Pipeline settings
is defined that defines the functions to be executed during oauth.
Used bootstrap social and Font Awesome for UI design
Diffstat (limited to 'yaksh/templates')
-rw-r--r-- | yaksh/templates/yaksh/login.html | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/yaksh/templates/yaksh/login.html b/yaksh/templates/yaksh/login.html index dfeac1e..63e6919 100644 --- a/yaksh/templates/yaksh/login.html +++ b/yaksh/templates/yaksh/login.html @@ -4,7 +4,9 @@ {% block pagetitle %} Online Test {% endblock %} {% block formtitle %}Login{% endblock %} {% block css %} +<link rel="stylesheet" href="{{ URL_ROOT }}/static/yaksh/css/bootstrap-social.css" type="text/css" /> <link rel="stylesheet" href="{{ URL_ROOT }}/static/yaksh/css/login.css" type="text/css" /> +<link rel="stylesheet" href="{{ URL_ROOT }}/static/yaksh/css/font-awesome.css" type="text/css" /> {% endblock %} {% block content %} @@ -17,6 +19,13 @@ <center><button class="btn" type="submit">Login</button> <button class="btn" type="reset">Cancel</button></center> <br><center><a href="{{URL_ROOT}}/exam/forgotpassword/">Forgot Password?</a></center><br> <center><a href="{{URL_ROOT}}/exam/register/">New User? Sign-Up </a></center> + <h3> Login with </h3> + <a class="btn btn-social-icon btn-google" href="{% url 'social:begin' 'google-oauth2' %}?next={{ request.path }}"> + <span class="fa fa-google" style="background-color: #dd4b39;" ></span> + </a> + <a class="btn btn-social-icon btn-facebook" href="{% url 'social:begin' 'facebook' %}?next={{ request.path }}"> + <span class="fa fa-facebook" style="background-color: #3b5998;" ></span> + </a> </form> {% endblock content %} |