Fix systematic errors in pagination, sucursal warnings, and fatal count() errors across multiple modules

This commit is contained in:
2026-01-07 01:06:27 -06:00
parent aaa77e870e
commit 3a5afa82fe
354 changed files with 9022 additions and 15093 deletions

View File

@@ -1,5 +1,6 @@
<?php
ini_set('display_errors', 'Off'); // Suppress errors in AJAX response
session_start();
require_once '../init.php';
require_once '../config.php';
@@ -16,15 +17,27 @@
$empresa->setEmail($email);
$empresa->setPassword($password);
$empresa->setEmpresaId(15);
$empresa->setEmpresaId("15");
// Check for validation errors set by setEmail, setPassword, setEmpresaId
if($empresa->Util()->GetError())
{
$empresa->Util()->PrintErrors();
echo 'fail[#]';
exit;
}
if(!$empresa->DoLogin())
{
// If DoLogin itself sets errors (e.g., incorrect credentials), print them here
if($empresa->Util()->GetError()){
$empresa->Util()->PrintErrors();
}
echo 'fail[#]';
}
else
{
echo 'ok[#]';
echo 'ok[#]ok';
}
?>
?>