Commit 3741c60b authored by Arnaud Bey's avatar Arnaud Bey
Browse files

foundables and found forms are displayed in different tabs

parent 6cd7c195
......@@ -66,7 +66,7 @@ edit_password: Change password
edit_profile: Edit profile
edit_round: 'Edit round'
english: English
existing_forms: 'Present forms'
existing_forms: Present forms
feminine: feminine
find_words: FindWord
firstPerson: 1rst
......
......@@ -74,7 +74,7 @@ edit_profile: Editer le profil
edit_round: 'Editer la manche'
edit: Editer
english: Anglais
existing_forms: 'forme(s) présente(s)'
existing_forms: formes présentes
export_game: Exporter la partie
feminine: féminin
find_words: FindWord
......
{% import "MagicWordBundle:FoundableForm:macros.html.twig" as macros %}
<div class="panel panel-default">
<div class="panel-body">
<div class="row">
<div class="col-md-12">
<div class="panel-group" id="accordion" role="tablist" aria-multiselectable="true">
<div class="panel panel-default">
<div class="panel-heading">
{{ activity.foundForms|length}} {{ "forms_found" | trans }} / {{round.grid.foundableForms|length}} {{ "existing_forms" | trans }}
<span class="pull-right">
<button type="button" class="btn btn-default btn-xs" data-order="asc" onclick="sorter.sort('percent', this, '#founded', '#founded div.foundable')">
<i class="fa fa-sort" aria-hidden="true"></i> %
</button>
<button type="button" class="btn btn-default btn-xs" data-order="asc" onclick="sorter.sort('form', this, '#founded', '#founded div.foundable')">
<i class="fa fa-sort" aria-hidden="true"></i> A-Z
</button>
<button type="button" class="btn btn-default btn-xs" data-order="asc" onclick="sorter.sort('points', this, '#founded', '#founded div.foundable')">
<i class="fa fa-sort" aria-hidden="true"></i> Points
</button>
<button type="button" class="btn btn-default btn-xs" data-order="asc" onclick="sorter.sort('length', this, '#founded', '#founded div.foundable')">
<i class="fa fa-sort" aria-hidden="true"></i> Longueur
</button>
</span>
</div>
</div>
<div id="founded" class="row">
{% for foundable in activity.foundForms %}
{{ macros.foundableComplete(foundable, activity, activities, "found") }}
{% endfor %}
</div>
</div>
</div>
</div>
</div>
</div>
......@@ -3,34 +3,6 @@
<div class="panel panel-default">
<div class="panel-body">
<div class="row">
<div class="col-md-12">
<div class="panel-group" id="accordion" role="tablist" aria-multiselectable="true">
<div class="panel panel-default">
<div class="panel-heading">
{{ activity.foundForms|length}} {{ "forms_found" | trans }}
<span class="pull-right">
<button type="button" class="btn btn-default btn-xs" data-order="asc" onclick="sorter.sort('percent', this, '#founded', '#founded div.foundable')">
<i class="fa fa-sort" aria-hidden="true"></i> %
</button>
<button type="button" class="btn btn-default btn-xs" data-order="asc" onclick="sorter.sort('form', this, '#founded', '#founded div.foundable')">
<i class="fa fa-sort" aria-hidden="true"></i> A-Z
</button>
<button type="button" class="btn btn-default btn-xs" data-order="asc" onclick="sorter.sort('points', this, '#founded', '#founded div.foundable')">
<i class="fa fa-sort" aria-hidden="true"></i> Points
</button>
<button type="button" class="btn btn-default btn-xs" data-order="asc" onclick="sorter.sort('length', this, '#founded', '#founded div.foundable')">
<i class="fa fa-sort" aria-hidden="true"></i> Longueur
</button>
</span>
</div>
</div>
<div id="founded" class="row">
{% for foundable in activity.foundForms %}
{{ macros.foundableComplete(foundable, activity, activities, "found") }}
{% endfor %}
</div>
</div>
</div>
<div class="col-md-12">
<div class="panel-group" id="accordion" role="tablist" aria-multiselectable="true">
<div class="panel panel-default">
......
......@@ -32,8 +32,13 @@
<ul class="nav nav-tabs" role="tablist">
{% if roundType == "rush" %}
<li role="presentation" class="active">
<a href="#found" aria-controls="found" role="tab" data-toggle="tab">
{{ "found"|trans}}
</a>
</li>
<li role="presentation">
<a href="#foundables" aria-controls="foundables" role="tab" data-toggle="tab">
{{ "foundables"|trans}}
{{ "existing_forms"|trans|capitalize}}
</a>
</li>
<li role="presentation">
......@@ -63,7 +68,10 @@
</ul>
<div class="tab-content">
{% if roundType == "rush" %}
<div role="tabpanel" class="tab-pane fade in active" id="foundables" style="height:auto;">
<div role="tabpanel" class="tab-pane fade in active" id="found" style="height:auto;">
{% include "MagicWordBundle:Round/End:found-forms.html.twig" %}
</div>
<div role="tabpanel" class="tab-pane fade" id="foundables" style="height:auto;">
{% include "MagicWordBundle:Round/End:foundable.html.twig" %}
</div>
<div role="tabpanel" class="tab-pane fade" id="combos-done" style="height:auto;">
......
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