Skip to content

Commit

Permalink
Add a LEGAL_LINK setting. Fixes #761
Browse files Browse the repository at this point in the history
  • Loading branch information
almet committed Oct 20, 2021
1 parent 63c129c commit 134c793
Show file tree
Hide file tree
Showing 5 changed files with 62 additions and 1 deletion.
10 changes: 9 additions & 1 deletion docs/configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,15 @@ Note: this setting is actually interpreted by Flask-Babel, see the
It is possible to add a simple captcha in order to filter out spammer bots on the form creation.
In order to do so, you just have to set `ENABLE_CAPTCHA = True`.

`LEGAL_LINK`
------------

You may want to point to a special legal page, for instance to give information
about GDPR, or how you handle the data of your users.

If you want to do this, you can use the `LEGAL_LINK` setting. Set it to the URL
you want.

Configuring emails sending
--------------------------

Expand All @@ -176,4 +185,3 @@ possible to configure it to act differently, thanks to the great
* **MAIL_USERNAME** : default **None**
* **MAIL_PASSWORD** : default **None**
* **DEFAULT_MAIL_SENDER** : default **None**

1 change: 1 addition & 0 deletions ihatemoney/default_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,4 @@
"zh_Hans",
]
ENABLE_CAPTCHA = False
LEGAL_LINK = "https://test"
3 changes: 3 additions & 0 deletions ihatemoney/messages.pot
Original file line number Diff line number Diff line change
Expand Up @@ -739,6 +739,9 @@ msgstr ""
msgid "Administation Dashboard"
msgstr ""

msgid "Legal information"
msgstr ""

msgid "\"I hate money\" is free software"
msgstr ""

Expand Down
44 changes: 44 additions & 0 deletions ihatemoney/static/images/legal.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions ihatemoney/templates/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,11 @@ <h6 class="dropdown-header">{{ _('Languages') }}</h6>
<i class="icon admin">{{ static_include("images/cog.svg") | safe }}</i>
</a>
{% endif %}
{% if config.LEGAL_LINK %}
<a target="_blank" rel="noopener" data-toggle="tooltip" data-placement="top" title="{{ _('Legal information') }}" href="{{ config.LEGAL_LINK }}">
<i class="icon legal">{{ static_include("images/legal.svg") | safe }}</i>
</a>
{% endif %}
</div>

<div class="footer-left">
Expand Down

0 comments on commit 134c793

Please sign in to comment.