diff --git a/robot.js b/robot.js index 21aacac..29c65e4 100644 --- a/robot.js +++ b/robot.js @@ -113,7 +113,21 @@ async function main() { // ========================================== // šŸ„ MULTIASISTENCIA (PAGINACIƓN ANTIBALAS Y DOBLE RECARGA) // ========================================== -// --- BUCLE DE PAGINACIƓN INFALIBLE --- +async function runMultiasistencia(ownerId, user, pass, gremiosDB) { + try { + const browser = await chromium.launch({ headless: HEADLESS, args: ['--no-sandbox', '--disable-setuid-sandbox', '--disable-dev-shm-usage', '--disable-gpu'] }); + const context = await browser.newContext(); + const page = await context.newPage(); + + await gotoWithRetry(page, 'https://web.multiasistencia.com/w3multi/acceso.php'); + await page.fill('input[name="usuario"]', user); + await page.fill('input[type="password"]', pass); + await page.click('input[type="submit"]'); + await page.waitForTimeout(4000); + await gotoWithRetry(page, 'https://web.multiasistencia.com/w3multi/frepasos_new.php?refresh=1'); + await page.waitForTimeout(3000); + + // --- BUCLE DE PAGINACIƓN INFALIBLE --- let todosExpedientes = new Set(); let paginaActual = 1;