FIX: Officebanking mensual

This commit is contained in:
Juan Pablo Vial
2024-09-18 13:43:23 -03:00
parent b8d4b260b6
commit e2573f35d1

View File

@ -23,11 +23,15 @@ class OfficeBanking extends Banco
$xlsx = $reader->load($filename); $xlsx = $reader->load($filename);
$sheet = $xlsx->getActiveSheet(); $sheet = $xlsx->getActiveSheet();
$subtitle = $sheet->getCell('A1')->getCalculatedValue(); $subtitle = $sheet->getCell('A1')->getCalculatedValue();
if ($subtitle !== null and trim($subtitle) === 'Cartolas históricas de Cuentas Corrientes') { $valid = [
'Consulta de movimientos de Cuentas Corrientes',
'Cartolas históricas de Cuentas Corrientes'
];
if ($subtitle !== null and in_array(trim($subtitle), $valid)) {
return true; return true;
} }
$subtitle = $sheet->getCell('A2')->getCalculatedValue(); $subtitle = $sheet->getCell('A2')->getCalculatedValue();
return $subtitle !== null and trim($subtitle) === 'Cartolas históricas de Cuentas Corrientes'; return $subtitle !== null and in_array(trim($subtitle), $valid);
} }
protected function columnMap(): array protected function columnMap(): array