Informes anteriores y siguientes
This commit is contained in:
@ -345,7 +345,12 @@ class Excel extends Ideal\Service
|
||||
$rowIndex ++;
|
||||
}
|
||||
$end = $rowIndex;
|
||||
$sheet->getCell("V{$totalRow}")->setValue("=SUM(C{$start}:D{$end})");
|
||||
$sumFormula = match($tipo) {
|
||||
'ingresos' => "=SUM(C{$start}:C{$end})",
|
||||
'egresos' => "=SUM(D{$start}:D{$end})",
|
||||
default => ''
|
||||
};
|
||||
$sheet->getCell("V{$totalRow}")->setValue($sumFormula);
|
||||
$sheet->getStyle("C{$start}:D{$end}")->getNumberFormat()
|
||||
->setFormatCode(self::CURRENCY_CODE);
|
||||
}
|
||||
|
Reference in New Issue
Block a user