Commit db4a455d authored by Arnaud Bey's avatar Arnaud Bey
Browse files

fix massive list

parent d36cd4d2
...@@ -29,38 +29,36 @@ ...@@ -29,38 +29,36 @@
</button> </button>
</span> </span>
</div> </div>
<div class="panel-group games" id="accordion" role="tablist" aria-multiselectable="true"> <div class="games" id="accordion" role="tablist" aria-multiselectable="true">
{% for massive in massives if massive not in app.user.endedGames and massive not in app.user.startedGames and massive.author != app.user %} {% for massive in massives if massive not in app.user.endedGames and massive not in app.user.startedGames and massive.author != app.user %}
{% set popularity = getActivityCount(massive) %} {% set popularity = getActivityCount(massive) %}
{% set roundCount = massive.rounds|length %} {% set roundCount = massive.rounds|length %}
<div data-roundcount="roundCount" data-popularity="{{ popularity }}" data-author="{{ massive.author }}" data-date="{{ massive.publishDate|date('Y-m-d H:i:s') }}" class="card game"> <div data-roundcount="roundCount" data-popularity="{{ popularity }}" data-author="{{ massive.author }}" data-date="{{ massive.publishDate|date('Y-m-d H:i:s') }}" class="card game">
<div class="card-header" role="tab" id="headingOne"> <div class="card-header" role="tab" id="headingOne">
<h4 class="panel-title"> {{ massive.name }} {% if massive.description %}<span class="text-muted">({{ massive.description}})</span>{% endif %}
"{{ massive.name }}" {% if massive.description %}<span class="text-muted">({{ massive.description}})</span>{% endif %} par <a href="{{ path('profile', {"id": massive.author.id}) }}">{{ massive.author }}</a>
par <a href="{{ path('profile', {"id": massive.author.id}) }}">{{ massive.author }}</a> <span class="float-right">
<span class="float-right"> <span class="badge badge-info">
<span class="label label-info"> <i class="fa fa-users" aria-hidden="true"></i>
<i class="fa fa-users" aria-hidden="true"></i> <span class="d-none d-md-inline"> {{ "popularity" | trans }}:</span> {{ popularity }}
<span class="d-none d-md-inline"> {{ "popularity" | trans }}:</span> {{ popularity }} </span> &nbsp;
</span> &nbsp; <a class="btn btn-outline-secondary btn-sm" role="button" data-toggle="collapse" data-parent="#accordion" href="#massive-{{ massive.id }}" aria-expanded="true" aria-controls="{{ massive.id }}">
<a class="btn btn-outline-secondary btn-sm" role="button" data-toggle="collapse" data-parent="#accordion" href="#{{ massive.id }}" aria-expanded="true" aria-controls="{{ massive.id }}"> <i class="fa fa-info" aria-hidden="true"></i>
<i class="fa fa-info" aria-hidden="true"></i> <span class="d-none d-md-inline">Infos</span>
<span class="d-none d-md-inline">Infos</span> </a>
</a> <a class="btn btn-outline-secondary btn-sm" href="{{ path('massive_play', {"code": massive.code}) }}">
<a class="btn btn-outline-secondary btn-sm" href="{{ path('massive_play', {"code": massive.code}) }}"> <i class="fa fa-gamepad" aria-hidden="true"></i>
<i class="fa fa-gamepad" aria-hidden="true"></i> <span class="d-none d-md-inline">Jouer</span>
<span class="d-none d-md-inline">Jouer</span> </a>
</a> </span>
</span>
</h4>
</div> </div>
<div id="{{ massive.id }}" class="panel-collapse collapse" role="tabpanel" aria-labelledby="headingOne"> <div id="massive-{{ massive.id }}" class="panel-collapse collapse" role="tabpanel" aria-labelledby="headingOne">
<ul class="list-group" > <ul class="list-group" >
{% for i, round in massive.rounds %} {% for i, round in massive.rounds %}
<li class="list-group-item"> <li class="list-group-item">
<span class="label label-default">{{ round.discr | trans }}</span> <span class="badge badge-secondary">{{ round.discr | trans }}</span>
<span class="label label-default">{{ round.language.value | trans }}</span> <span class="badge badge-info">{{ round.language.value | trans }}</span>
{% set order = i + 1 %} {% set order = i + 1 %}
{{ round.title ? round.title : "round" | trans ~ " " ~ order }} {{ round.title ? round.title : "round" | trans ~ " " ~ order }}
<span class="text-muted">{{ round.description ? "(" ~ round.description ~ ")" }}</span> <span class="text-muted">{{ round.description ? "(" ~ round.description ~ ")" }}</span>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment