Update login layout
This commit is contained in:
parent
82c37a2eb2
commit
4ce88a36b0
2 changed files with 30 additions and 13 deletions
21
photo21/templates/socialaccount/snippets/provider_list.html
Normal file
21
photo21/templates/socialaccount/snippets/provider_list.html
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
{% comment %}
|
||||
This file is part of photo21
|
||||
Copyright (C) 2022 Amicale des élèves de l'ENS Paris-Saclay
|
||||
SPDX-License-Identifier: GPL-3.0-or-later
|
||||
{% endcomment %}
|
||||
{% load i18n socialaccount %}
|
||||
|
||||
{% get_providers as socialaccount_providers %}
|
||||
|
||||
{% for provider in socialaccount_providers %}
|
||||
{% if provider.id == "openid" %}
|
||||
{% for brand in provider.get_brands %}
|
||||
<a title="{{brand.name}}"
|
||||
class="btn btn-success"
|
||||
href="{% provider_login_url provider.id openid=brand.openid_url process=process %}"
|
||||
>{{brand.name}}</a>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
<a title="{{provider.name}}" class="btn btn-success"
|
||||
href="{% provider_login_url provider.id process=process scope=scope auth_params=auth_params %}">{% trans "Sign in with" %} {{provider.name}}</a>
|
||||
{% endfor %}
|
||||
Loading…
Add table
Add a link
Reference in a new issue