Commit ff0d2cdb authored by okhin's avatar okhin 🚴

Merge branch '60-historique-des-dons-et-contreparties' into 'preprod'

Resolve "Historique des dons et contreparties"

Closes #60

See merge request !49
parents 32d37caa eea113a9
Pipeline #2213 passed with stages
in 11 seconds
......@@ -93,7 +93,7 @@ class Perso extends Controller
{
// Chargement des dons de l'utilisateur
$db = $f3->get('DB');
$result = $db->query("SELECT datec, somme, id, pdf, status FROM dons WHERE user_id='".$f3->get('infos.id')."' AND status IN (1,4,102) ORDER BY datec ASC");
$result = $db->query("SELECT datec, somme, id, pdf, status FROM dons WHERE user_id='".$f3->get('infos.id')."' AND status IN (1,4,102) ORDER BY datec DESC");
$data = array();
foreach ($result->fetchAll(\PDO::FETCH_ASSOC) as $row) {
$data[] = $row;
......
......@@ -139,14 +139,12 @@
<th>{{ _("Date") }}</th>
<th>{{ _("Dons") }}</th>
<th>{{ _("Récurent") }}</th>
<th>{{ _("Contreparties") }}</th>
</tr>
<repeat group="{{ @dons_recurrents }}" value="{{ @don }}">
<tr>
<td>{{ @don.datec }}</td>
<td>{{ @don.somme }}</td>
<td>{{ _("Oui")}}</td>
<td></td>
</tr>
</repeat>
<repeat group="{{ @dons }}" value="{{ @don }}">
......@@ -154,14 +152,17 @@
<td>{{ @don.datec }}</td>
<td>{{ @don.somme }}</td>
<td>{{ _("Non")}}</td>
<td></td>
</tr>
</repeat>
</table>
<table class="table text-left">
<tr>
<th>{{ _("Date") }}</th>
<th>{{ _("Contreparties") }}</th>
</tr>
<repeat group="{{ @contreparties }}" value="{{ @contrepartie }}">
<tr>
<td>{{ @contrepartie.datec }}</td>
<td></td>
<td></td>
<td>{{ @contrepartie.quoi }}</td>
</tr>
</repeat>
......
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