Skip to content

Commit

Permalink
Merge pull request #208 from crf-devs/fix-week-button
Browse files Browse the repository at this point in the history
Fix planning week dates
  • Loading branch information
mRoca authored Apr 3, 2020
2 parents cbe2d88 + 791d9e1 commit 2da2f95
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions templates/organization/home.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,18 @@
<h1>{{ app.user }}</h1>

<p>Semaine actuelle : du {{ 'this week' | date('d/m/Y') }} au {{ 'sunday this week' | date('d/m/Y') }}</p>
<p><a class="btn btn-outline-primary" role="button" href="{{ path('planning', {'organizations[]': app.user.id}) }}">Afficher les disponibilités de mes bénévoles pour la semaine actuelle</a></p>
<p>
<a class="btn btn-outline-primary" role="button" href="{{ path('planning', {'organizations[]': app.user.id, 'from': 'monday this week' | date('Y-m-d\\T00:00:00'), 'to': 'sunday this week' | date('Y-m-d\\T00:00:00')}) }}">
Afficher les disponibilités de mes bénévoles pour la semaine actuelle
</a>
</p>

<p>Semaine prochaine : du {{ 'next week' | date('d/m/Y') }} au {{ 'sunday next week' | date('d/m/Y') }}</p>
<p><a class="btn btn-outline-primary" role="button" href="{{ path('planning', {'organizations[]': app.user.id, 'from': 'monday next week' | date('Y-m-d\\T00:00:00')}) }}">Afficher les disponibilités de mes bénévoles pour la semaine prochaine</a></p>
<p>
<a class="btn btn-outline-primary" role="button" href="{{ path('planning', {'organizations[]': app.user.id, 'from': 'monday next week' | date('Y-m-d\\T00:00:00'), 'to': 'sunday next week' | date('Y-m-d\\T00:00:00')}) }}">
Afficher les disponibilités de mes bénévoles pour la semaine prochaine
</a>
</p>

<hr>

Expand Down

0 comments on commit 2da2f95

Please sign in to comment.