This commit is contained in:
naielv
2025-09-09 22:51:04 +02:00
parent 2f3efbcf66
commit 74dc7fe404

View File

@@ -783,8 +783,8 @@ function TS_IndexElement(
return a.Fecha < b.Fecha ? -1 : 1;
}
// 2. Region (ascending, from SC_Personas if Persona exists)
const regionA = a.Persona && SC_Personas[a.Persona] ? SC_Personas[a.Persona].Region || "" : "";
const regionB = b.Persona && SC_Personas[b.Persona] ? SC_Personas[b.Persona].Region || "" : "";
const regionA = a.Persona && SC_Personas[a.Persona] ? SC_Personas[a.Persona].Region || "" : a.Region || "";
const regionB = b.Persona && SC_Personas[b.Persona] ? SC_Personas[b.Persona].Region || "" : a.Region || "";
if (regionA !== regionB) {
return regionA < regionB ? -1 : 1;
}