PHP - SubTotales por categoria
Publicado por Erick (4 intervenciones) el 13/03/2019 18:44:51
Hola a Todos, me podrían ayudar con esta consulta, tengo una lista de pagos, y quisiera mostrar el sub-total al finalizar cada forma de pago respectivamente.... es urgente por favor
DETRACC FE 001-018380 96.00
DETRACC FE 001-025077 272.00
----------------------SUBTOTAL 368.00 --
DEPOSITO FE 001-015254 33.50
DEPOSITO FE 001-016524 48.00
DEPOSITO FE 001-019319 60.00
DEPOSITO FE 001-019952 280.00
DEPOSITO FE 001-021978 340.00
DEPOSITO FE 001-023839 780.00
DEPOSITO RP 001-024693 34.80
DEPOSITO FE 001-024216 650.00
DEPOSITO FE 001-024711 1188.00
DEPOSITO RP 001-025133 4194.40
DEPOSITO FE 001-025081 304.00
DEPOSITO FE 001-025864 2189.00
DEPOSITO FE 001-028051 2684.00
DEPOSITO FE 001-028052 4796.00
DEPOSITO FE 001-028053 2728.00
DEPOSITO RP 001-027321 18.00
DEPOSITO RP 001-021212 30.40
----------------------SUBTOTAL 20358.10 --
1
2
3
4
5
6
7
8
9
10
11
<?php
while ($rows_depo = mysqli_fetch_array($sql_dep)) {
?>
<tr>
<td><?=$rows_depo["DC_FORM_PAGO"]?></td>
<td><?=$rows_depo["NU_FACT"]?></td>
<td><?=number_format($neto, '2', '.', ',')?></td>
</tr>
<?php
}
?>
DETRACC FE 001-025077 272.00
----------------------SUBTOTAL 368.00 --
DEPOSITO FE 001-015254 33.50
DEPOSITO FE 001-016524 48.00
DEPOSITO FE 001-019319 60.00
DEPOSITO FE 001-019952 280.00
DEPOSITO FE 001-021978 340.00
DEPOSITO FE 001-023839 780.00
DEPOSITO RP 001-024693 34.80
DEPOSITO FE 001-024216 650.00
DEPOSITO FE 001-024711 1188.00
DEPOSITO RP 001-025133 4194.40
DEPOSITO FE 001-025081 304.00
DEPOSITO FE 001-025864 2189.00
DEPOSITO FE 001-028051 2684.00
DEPOSITO FE 001-028052 4796.00
DEPOSITO FE 001-028053 2728.00
DEPOSITO RP 001-027321 18.00
DEPOSITO RP 001-021212 30.40
----------------------SUBTOTAL 20358.10 --
Valora esta pregunta


0