mirror of
https://github.com/aljazceru/CTFd.git
synced 2025-12-17 14:04:20 +01:00
Fixing scoping issues in awards rendering and not commiting .data (docker-compose)
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -61,4 +61,5 @@ target/
|
||||
CTFd/static/uploads
|
||||
CTFd/uploads
|
||||
CTFd/plugins
|
||||
.data/
|
||||
.ctfd_secret_key
|
||||
|
||||
@@ -35,20 +35,19 @@
|
||||
{% if awards %}
|
||||
<div class="row">
|
||||
<h3>Awards</h3>
|
||||
{% set count = awards|length %}
|
||||
{% set rem = awards|length % 4 %}
|
||||
{% for award in awards %}
|
||||
{% if count >= 4 %}
|
||||
<div class="col-xs-3 col-md-3">
|
||||
{% else %}
|
||||
{% set count= awards|length - loop.index %}
|
||||
{% set rem = awards|length % 4 %}
|
||||
{% if count < rem %}
|
||||
<div class="col-xs-{{ (12//rem)|string }} col-md-{{ (12//rem)|string }}">
|
||||
{% else %}
|
||||
<div class="col-xs-3 col-md-3">
|
||||
{% endif %}
|
||||
<p class="text-center"><strong>{{ award.name }}</strong></p>
|
||||
{% if award.category %}<p class="text-center">{{ award.category }}</p>{% endif %}
|
||||
<p class="text-center">{{ award.description }}</p>
|
||||
<p class="text-center">{{ award.value }}</p>
|
||||
</div>
|
||||
{% set count = count - 1 %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user