1
0

Merge remote-tracking branch 'origin/dev' into dev

# Conflicts:
#	templates/transacties.phtml
This commit is contained in:
JelmerHinssen 2017-03-31 17:27:03 +02:00
commit 7db872748e
5 changed files with 37 additions and 26 deletions

View File

@ -42,13 +42,17 @@ ul.nv {
color: white; color: white;
} }
/** Index **/
.clickable {
cursor: pointer;
}
.clickable:hover {
background: #0094ff;
}
/** Footer **/ /** Footer **/
.footer { .footer {
color: grey; color: grey;
margin-top: 50px; margin-top: 50px;
} }
/** Table Row **/
.clickable {
cursor: pointer;
}

View File

@ -31,10 +31,14 @@ class Rekeningen
$returnArray = array(); $returnArray = array();
foreach ($rekeningen as $rekening) { foreach ($rekeningen as $rekening) {
$type = $db->types->where('id', $rekening['typeid'])[$rekening['typeid']];
$returnArray[] = array( $returnArray[] = array(
"iban" => $ibanhelper->getIBAN($rekening['rekeningnr']), "iban" => $ibanhelper->getIBAN($rekening['rekeningnr']),
"nr" => $rekening['rekeningnr'], "nr" => $rekening['rekeningnr'],
"saldo" => (double) $rekening['saldo'] "saldo" => (double) $rekening['saldo'],
"naam" => $type['rekeningnaam'],
"rente" => $type['rente']
); );
} }

View File

@ -4,15 +4,17 @@
<tr> <tr>
<th>IBAN</th> <th>IBAN</th>
<th>Saldo</th> <th>Saldo</th>
<!-- <th>TIJDELIJK</th> --> <th>Rekeningtype</th>
<th>Rente</th>
</tr> </tr>
<?php <?php
foreach ($rekeningen as $rekening) { foreach ($rekeningen as $rekening) {
?> ?>
<tr onclick="document.location.href = 'rekeningen/<?php echo $rekening['nr'] ?>'"> <tr class="clickable" onclick="document.location.href = 'rekeningen/<?php echo $rekening['nr'] ?>'">
<td><?php echo $rekening['iban']; ?></td> <td><?php echo $rekening['iban']; ?></td>
<td><?php echo "&euro;" . $rekening['saldo']; ?></td> <td><?php echo "&euro;" . $rekening['saldo']; ?></td>
<!-- <td><?php echo $rekening['nr']; ?></td> --> <td><?php echo $rekening['naam']; ?></td>
<td><?php echo $rekening['rente']; ?></td>
</tr> </tr>
<?php <?php

View File

@ -21,23 +21,24 @@ Saldo: <?php echo $rekening['saldo']?><br/>
</tr> </tr>
<?php <?php
foreach ($transacties as $transactie) { foreach ($transacties as $transactie) {
if(!isset($transactie['omschrijving'])){ if(!isset($transactie['omschrijving'])){
$transactie['omschrijving'] = ""; $transactie['omschrijving'] = "";
} }
echo "<tr>"; echo "<tr>";
echo "<td></td>"; echo "<td></td>";
echo "<td>" . $transactie['type'] . "</td>\n"; echo "<td>" . $transactie['type'] . "</td>\n";
echo "<td>" . $transactie['omschrijving'] . "</td>\n"; echo "<td>" . $transactie['omschrijving'] . "</td>\n";
if($transactie['van'] === $rekening['iban']){ if($transactie['van'] === $rekening['iban']){
echo "<td>" . $transactie['naar'] . "</td>\n"; echo "<td>" . $transactie['naar'] . "</td>\n";
echo "<td>AF</td>\n"; echo "<td>AF</td>\n";
}else{ }else{
echo "<td>" . $transactie['van'] . "</td>\n"; echo "<td>" . $transactie['van'] . "</td>\n";
echo "<td>BIJ</td>\n"; echo "<td>BIJ</td>\n";
} }
echo "<td>€" . $transactie['bedrag'] . "</td>\n"; echo "<td>€" . $transactie['bedrag'] . "</td>\n";
echo "</tr>"; echo "</tr>";
} ?> }
?>
</table> </table>
<?php <?php