credits_verbessert

This commit is contained in:
ben8
2025-06-29 17:11:04 +02:00
parent 31e9618e1c
commit d907390652

View File

@@ -253,29 +253,38 @@
{% endif %} {% endif %}
</div> </div>
<div class="flex flex-col max-w-full"> <div class="flex flex-col max-w-full">
Credits: <p class="text-gray-600 mt-2 ">Credits: </p>
{% if quiz.credits %} {% if quiz.credits %}
<p class="text-gray-600 mb-2 w-full break-words"> <p class="text-blue-500 mb-2 w-full break-words">
<span class="font-bold break-words">{{ quiz.credits }}</span> <span class="font-bold break-words italic">{{ quiz.credits }}</span>
<span class="font-normal break-words text-gray-600">(Credits für das Quiz)</span>
</p> </p>
{% else %}
<p class="text-gray-500">Keine Credits für das Quizformular vorhanden!</p>
{% endif %} {% endif %}
</div> </div>
<div class="flex flex-col max-w-full"> <div class="flex flex-col max-w-full">
<ul class="space-y-2"> <ul class="space-y-2">
{% regroup questions by credits as grouped_credits %}
{% if grouped_credits|length == 1 and not grouped_credits.0.grouper %}
<li class="text-gray-500">Keine Credits für die Fragen vorhanden!</li>
{% else %}
{% for question in questions %} {% for question in questions %}
{% if question.credits %} {% if question.credits %}
<li class="text-gray-600 mb-2 w-full break-words font-bold break-words"> <li class="text-blue-500 mb-2 w-full break-words font-bold break-words ">
{{ question.credits }} <span class="italic">{{ question.credits }}</span>
<span class="font-medium text-gray-500 break-words">(Frage: {{ forloop.counter }})</span> <span class="font-normal break-words text-gray-600">(Frage: {{ forloop.counter }})</span>
</li> </li>
{% endif %} {% endif %}
{% endfor %} {% endfor %}
{% endif %}
</ul> </ul>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}