修改关于我们页面,优化中英文切换

This commit is contained in:
2026-08-05 08:56:28 +08:00
parent d06c955a3d
commit 2022664e7e
5 changed files with 47 additions and 1 deletions
+13
View File
@@ -6,6 +6,15 @@
{% block content %}
<section class="section bg-white py-5">
<div class="container">
<div class="section-title">
<h2>{% trans '关于我们' %}</h2>
</div>
{% with about_content=site_settings.about_content_zh|default:site_settings.about_content_en %}
{% if about_content %}
<div class="about-content">
{{ about_content|safe }}
</div>
{% else %}
<div class="row align-items-center g-5">
<div class="col-lg-6">
<h2 class="mb-4">{% trans '关于我们' %}</h2>
@@ -36,9 +45,12 @@
</div>
</div>
</div>
{% endif %}
{% endwith %}
</div>
</section>
{% if not site_settings.about_content_zh and not site_settings.about_content_en %}
<section class="section">
<div class="container">
<div class="section-title">
@@ -69,4 +81,5 @@
</div>
</div>
</section>
{% endif %}
{% endblock %}