Open rbovard opened 2 years ago
I've just got this problem. One way to solve this, if you don't want to wait for its implementation, is to override the default template with the help of the "Overriding asset API" from pyramid: https://docs.pylonsproject.org/projects/pyramid/en/latest/narr/assets.html#overriding-assets-section
In the __init__.py
of your geoportal, ie: geoportal/sitn_geoportal/__init__.py
in the main
method, before adding the routes:
config.override_asset(
to_override='c2cgeoportal_geoportal:templates/login.html',
override_with='sitn_geoportal:templates/login.html')
Be sure to replace sitn_geoportal
by your package name.
Then you can copy-paste the original login.html and make it responsive, or take mine and put it in your templates directory (mine is: geoportal/sitn_geoportal/templates/login.html
):
This works great for /login.html
route but I've not tested the oauth2 route.
Thanks a lot @maltaesousa, I'll take a look!
For the OAuth2 route, you can simply test with https://sitn.ne.ch/oauth/login
@maltaesousa Do you know if there is a way to add the link "Reset password" in this login form?
Yes there's a way: first you'll need to create a second template with a custom pyramid route and handle the password reset stuff. We have something similar in different views in our geoportal, for instance:
Maybe it's better to wait for funding calls to see if this issue gets funded. I'm wondering if we will be able to reuse the webcomponent done for the front here because everything is already done in the gmf-auth-panel.
Thanks for your answer, we'll think about that webcomponent migration issue.
Who requested this new feature?
Is your feature request related to a problem?
Describe the solution you'd like
Additional information or points to watch out for
EDIT 27.10.2022: Requires technical functionality "pluggable authentication"