diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2024-10-10 08:01:08 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2024-10-16 13:51:43 +0200 |
commit | f94dc19857cec3cc9d8443228454b7e264fffa0e (patch) | |
tree | 8199a6bafd87318b94165bbb1570c8be83da0a4b /ishtar_common/templates | |
parent | 2283d0056155265bb2fbf9cc8c9f10e71355d1ee (diff) | |
download | Ishtar-f94dc19857cec3cc9d8443228454b7e264fffa0e.tar.bz2 Ishtar-f94dc19857cec3cc9d8443228454b7e264fffa0e.zip |
✨ display forum entries: activate/deactivate by user profile - profile form: edit news/forum display
Diffstat (limited to 'ishtar_common/templates')
-rw-r--r-- | ishtar_common/templates/index.html | 14 | ||||
-rw-r--r-- | ishtar_common/templates/ishtar/blocks/news_feed.html | 5 | ||||
-rw-r--r-- | ishtar_common/templates/ishtar/forms/profile.html | 8 |
3 files changed, 19 insertions, 8 deletions
diff --git a/ishtar_common/templates/index.html b/ishtar_common/templates/index.html index eaaf7dd54..47c51223e 100644 --- a/ishtar_common/templates/index.html +++ b/ishtar_common/templates/index.html @@ -2,12 +2,6 @@ {% load i18n %} {% block content %}<div id="welcome" class="container"> <h2>{{welcome_title}}</h2> - {% if news_feed %} - <div id="news-feed" class="card p-3 mb-4"> - <h3><i class="fa fa-newspaper-o" aria-hidden="true"></i> {% trans "Latest news" %}</h3> - {{ news_feed|safe }} - </div> - {% endif %} <div class="row"> {% if display_random_image %} {{random_image}} @@ -19,6 +13,9 @@ </div> </div> </div> + {% if news_feed %} + <div id="news-feed" class="col col-12 mt-4"></div> + {% endif %} {% if display_statistics %} <div class="col col-lg-12 lead mt-4"> {% for label, number in statistics %} @@ -28,3 +25,8 @@ {% endif %} </div> </div>{% endblock %} +{% block end_js %} +$(document).ready(function() { + dynamic_load("/news-feed/", "#news-feed"); +}); +{% endblock %} diff --git a/ishtar_common/templates/ishtar/blocks/news_feed.html b/ishtar_common/templates/ishtar/blocks/news_feed.html new file mode 100644 index 000000000..63524303a --- /dev/null +++ b/ishtar_common/templates/ishtar/blocks/news_feed.html @@ -0,0 +1,5 @@ +{% load i18n %} +{% if news_feed %}<div class="container card p-3"> + <h3><i class="fa fa-newspaper-o" aria-hidden="true"></i> {% trans "Latest forum entries" %}</h3> + {{ news_feed|safe }} +</div>{% endif %} diff --git a/ishtar_common/templates/ishtar/forms/profile.html b/ishtar_common/templates/ishtar/forms/profile.html index 795ab6ab1..f4e3f5b41 100644 --- a/ishtar_common/templates/ishtar/forms/profile.html +++ b/ishtar_common/templates/ishtar/forms/profile.html @@ -14,7 +14,6 @@ $(document).ready(function(){ {% block content %} <div class="container"> -<h2>{{page_name}}</h2> <div class='form'> {% if form.non_field_errors %} @@ -30,9 +29,14 @@ $(document).ready(function(){ </div>{% endif %} {% endfor %} + <h2>{% trans "Edit user preferences" %}</h2> + <h3>{% trans "Global preferences" %}</h3> <div class="form-row"> {% for field in form.visible_fields %} - {% if forloop.counter0 == 0 %} + {% if forloop.counter0 == 2 %} + </div> + <h3>{% trans "Current profile" %}</h3> + <div class="form-row"> <div class="form-group col-12"><div class="col-lg-6"> {{field|bs_field|safe}} </div></div> |